id(8) on Solnix vs Linux and the BSDs
On Solnix, id is the illumos id at /usr/bin/id. Its -p adds a project ID (projid=) to the default line, whereas on the BSDs -p makes the output human-readable on separate lines. Its -a is a real option that adds all groups, whereas Linux and FreeBSD ignore it.
The manual pages
- Solnix: id(8) from
pkgs.solnix.illumos-world-man· illumos.org - Linux: id(1) coreutils-full-9.11
- FreeBSD: id(1) 15.1-RELEASE
- OpenBSD: id(1) 8.0
- NetBSD: id(1) 11.0
- Standard: POSIX.1-2024 (IEEE Std 1003.1-2024),
id
What Solnix runs
A default Solnix system runs the illumos /usr/bin/id. /usr/xpg4/bin/id has the same synopsis. The page says that only /usr/xpg4/bin/id also writes supplementary group affiliations in the default output; the bundle does not describe /usr/bin/id doing so. The ATTRIBUTES table lists /usr/bin/id as Stable and /usr/xpg4/bin/id as Standard.
Differences
| Compared with | Topic | What differs |
|---|---|---|
| FreeBSD, OpenBSD, NetBSD | -p meaning | On Solnix, id -p appends projid=%u(%s) to the normal one-line output. On FreeBSD, OpenBSD and NetBSD, -p switches to a human-readable multi-line output with the keywords login, uid, euid, rgid and groups.Source: Solnix id(8) -p; FreeBSD id(1) -p; OpenBSD id(1) -p; NetBSD id(1) -p |
| Linux | -p missing on Linux | Solnix has -p for project membership. The Linux id page documents no -p option, so a script using id -p fails or behaves differently there.Source: Solnix id(8) -p; Linux id(1) options list |
| Linux, FreeBSD | -a meaning | On Solnix, -a reports the user name, user ID and all groups, and is invalid with -G, -g or -u. Linux and FreeBSD ignore -a for compatibility. OpenBSD and NetBSD do not document -a.Source: Solnix id(8) -a, OPTIONS; Linux id(1) -a; FreeBSD id(1) -a; OpenBSD id(1) SYNOPSIS; NetBSD id(1) SYNOPSIS |
| all four | -G output format | Solnix -G prints each ID with the format %u, separated by a space, and ends with a newline. FreeBSD, OpenBSD and NetBSD say the IDs come as whitespace-separated numbers in no particular order. The Linux text does not describe the separator.Source: Solnix id(8) -G; FreeBSD id(1) -G; OpenBSD id(1) -G; NetBSD id(1) -G; Linux id(1) -G |
| Linux | multiple users and -z | Linux id accepts several USER operands and has -z to separate entries with NUL. The Solnix synopsis takes a single optional user and has no -z.Source: Linux id(1) SYNOPSIS, -z; Solnix id(8) SYNOPSIS, OPERANDS |
| all four | long options | Linux documents long options such as --user, --group, --groups, --name and --real. The Solnix page documents only single-letter options.Source: Linux id(1) -u, -g, -G, -n, -r; Solnix id(8) OPTIONS |
| Linux, FreeBSD, OpenBSD | extra options not on Solnix | Solnix has none of these: Linux -Z (security context), FreeBSD -A, -M, -P, -c, -d and -s, OpenBSD -c and -R. Scripts using them must not assume they exist on Solnix.Source: Linux id(1) -Z; FreeBSD id(1) SYNOPSIS; OpenBSD id(1) -c, -R; Solnix id(8) SYNOPSIS |
| FreeBSD, OpenBSD, NetBSD | default output when a name cannot be mapped | Solnix omits the (%s) name part when an ID cannot be mapped to a name. With -n, the BSDs display the number instead if an ID cannot be mapped. The Solnix page does not say what -n does in that case.Source: Solnix id(8) Formats, -n; FreeBSD id(1) -n; OpenBSD id(1) -n; NetBSD id(1) -n |
| FreeBSD, OpenBSD, NetBSD | user operand | The BSD pages say user may be a login name or a user ID. The Solnix page describes the operand only as a user (login) name. Source: Solnix id(8) OPERANDS; FreeBSD id(1) DESCRIPTION; OpenBSD id(1) DESCRIPTION; NetBSD id(1) DESCRIPTION |
| all four | exit status | Solnix, FreeBSD, OpenBSD and NetBSD document exit 0 on success and >0 on error. The Linux page excerpt documents no exit status. Source: Solnix id(8) EXIT STATUS; FreeBSD/OpenBSD/NetBSD id(1) EXIT STATUS; Linux id(1) |
Standards
- POSIX: id is a POSIX.1-2024 utility.
- Solnix: Interface Stability:
/usr/bin/idis Stable;/usr/xpg4/bin/idis Standard. - OpenBSD: The id utility is compliant with the IEEE Std 1003.1-2008 (“POSIX.1”) specification. The flags [
-cpR] are extensions to that specification. - NetBSD: The id function is expected to conform to IEEE Std 1003.2 (“POSIX.2”).
- FreeBSD: The
-A,-M,-P,-c,-d,-p, and-soptions are FreeBSD extensions.
Writing portable scripts
- Stick to
-u,-g,-G,-nand-r, which every page documents. Avoid-pand-a, which differ between systems. - Do not rely on the order of IDs from id
-G; the BSD pages say it is in no particular order.
Every difference here is taken from the manual pages linked above: Solnix's published page, Linux (man-pages and the GNU and util-linux manuals), FreeBSD, OpenBSD and NetBSD. Each row names its source. Where a manual is silent, this page is too. Compiled 2026-10-26. Found a mistake? Mail hackers@lists.solnix.io.