posix_uname
Description
The posix_uname of POSIX for PHP gets the system name.
Syntax
posix_uname(): array|false
Return
Returns a hash of strings with information about the system, false on failure.
Index | Description | Example |
---|---|---|
sysname | operating system name | Linux |
nodename | system name | valiant |
release | operating system release | 2.2.10 |
version | operating system version | #4 Tue Jul 20 17:01:36 MEST 1999 |
machine | system architecture | i586 |
domainname | DNS domainname A GNU extension and not part of POSIX.1, so this field is only available on GNU systems or when using the GNU libc. | example.com |
Examples
1 · void
<? $return = posix_uname(); print_r($return); ?>
Array ( [sysname] => Linux [nodename] => valiant [release] => 2.2.10 [version] => #4 Tue Jul 20 17:01:36 MEST 1999 [machine] => i586 [domainname] => example.com )
Links
POSIX
- posix_access
- posix_ctermid
- posix_eaccess
- posix_errno
- posix_fpathconf
- posix_get_last_error
- posix_getcwd
- posix_getegid
- posix_geteuid
- posix_getgid
- posix_getgrgid
- posix_getgrnam
- posix_getgroups
- posix_getlogin
- posix_getpgid
- posix_getpgrp
- posix_getpid
- posix_getppid
- posix_getpwnam
- posix_getpwuid
- posix_getrlimit
- posix_getsid
- posix_getuid
- posix_initgroups
- posix_isatty
- posix_kill
- posix_mkfifo
- posix_mknod
- posix_pathconf
- posix_setegid
- posix_seteuid
- posix_setgid
- posix_setpgid
- posix_setrlimit
- posix_setsid
- posix_setuid
- posix_strerror
- posix_sysconf
- posix_times
- posix_ttyname