# phpman > man > systemd-id128(1)

> **TLDR:** Generate and print sd-128 identifiers.
>
- Generate a new random identifier:
  `systemd-id128 new`
- Print the identifier of the current machine:
  `systemd-id128 machine-id`
- Print the identifier of the current boot:
  `systemd-id128 boot-id`
- Print the identifier of the current service invocation (this is available in systemd services):
  `systemd-id128 invocation-id`
- Generate a new random identifier and print it as a UUID (five groups of digits separated by hyphens):
  `systemd-id128 new {{-u|--uuid}}`

*Source: tldr-pages*

---

[SYSTEMD-ID128(1)](https://www.chedong.com/phpMan.php/man/SYSTEMD-ID128/1/markdown)                            systemd-id128                           [SYSTEMD-ID128(1)](https://www.chedong.com/phpMan.php/man/SYSTEMD-ID128/1/markdown)



## NAME
       systemd-id128 - Generate and print sd-128 identifiers

## SYNOPSIS
       **systemd-id128** [OPTIONS...] new

       **systemd-id128** [OPTIONS...] machine-id

       **systemd-id128** [OPTIONS...] boot-id

       **systemd-id128** [OPTIONS...] invocation-id

## DESCRIPTION
       **id128** may be used to conveniently print [**sd-id128**(3)](https://www.chedong.com/phpMan.php/man/sd-id128/3/markdown) UUIDs. What identifier is printed depends
       on the specific verb.

       With **new**, a new random identifier will be generated.

       With **machine-id**, the identifier of the current machine will be printed. See [**machine-id**(5)](https://www.chedong.com/phpMan.php/man/machine-id/5/markdown).

       With **boot-id**, the identifier of the current boot will be printed.

       Both **machine-id** and **boot-id** may be combined with the **--app-specific=**_app-id_ switch to generate
       application-specific IDs. See **sd**___**id128**___**get**___**[machine**(3)](https://www.chedong.com/phpMan.php/man/machine/3/markdown) for the discussion when this is useful.

       With **invocation-id**, the identifier of the current service invocation will be printed. This is
       available in systemd services. See [**systemd.exec**(5)](https://www.chedong.com/phpMan.php/man/systemd.exec/5/markdown).

       With **show**, well-known UUIDs are printed. When no arguments are specified, all known UUIDs are
       shown. When arguments are specified, they must be the names or values of one or more known
       UUIDs, which are then printed.

## OPTIONS
       The following options are understood:

### -p --pretty
           Generate output as programming language snippets.

### -a --app-specific=
           With this option, an identifier that is the result of hashing the application identifier
           _app-id_ and the machine identifier will be printed. The _app-id_ argument must be a valid
           sd-id128 string identifying the application.

### -u --uuid
           Generate output as an UUID formatted in the "canonical representation", with five groups
           of digits separated by hyphens. See the **wikipedia**[1] for more discussion.

### -h --help
           Print a short help text and exit.

### --version
           Print a short version string and exit.

## EXIT STATUS
       On success, 0 is returned, a non-zero failure code otherwise.

## SEE ALSO
       [**systemd**(1)](https://www.chedong.com/phpMan.php/man/systemd/1/markdown), [**sd-id128**(3)](https://www.chedong.com/phpMan.php/man/sd-id128/3/markdown), **sd**___**id128**___**get**___**[machine**(3)](https://www.chedong.com/phpMan.php/man/machine/3/markdown)

## NOTES
        1. wikipedia
           <https://en.wikipedia.org/wiki/Universally_unique_identifier#Format>



systemd 249                                                                         [SYSTEMD-ID128(1)](https://www.chedong.com/phpMan.php/man/SYSTEMD-ID128/1/markdown)
