W(1)
๐ W(1) โ the "who's online & what are they even doing" page ๐
okay bestie, this is w from the procps-ng manual set (section 1, general commands, iykyk). It's the little command that tells you who's on the machine rn and what they're up to. Let's get into it โจ
๐ธ NAME ๐ธ
w โ Show who is logged on and what they are doing.
๐ SYNOPSIS ๐
w [option ...] [user]
๐ฆ DESCRIPTION ๐ฆ
Okay so w spills the tea about the users currently on the machine, plus their processes. The header is giving main character energy and shows, in this exact order: the current time, how long the system has been running, how many users are currently logged on, and the system load averages for the past 1, 5, and 15 minutes. Periodt.
Then for each user you get these entries: login name, the tty name, the remote host, login time, idle time, JCPU, PCPU, and the command line of their current process. It's giving full profile, no crumbs ๐
The JCPU time is the time used by all processes attached to the tty. It does not include past background jobs, but it does include currently running background jobs. The way that's such a specific little rule, obsessed.
The PCPU time is the time used by the current process, the one named in the "what" field.
โจ OPTIONS โจ
-c,--containerโ show the container uptime instead of system uptime in the header. cute little container moment ๐ซถ-h,--no-headerโ Don't print the header. bye header ๐-u,--no-currentโ Ignores the username while figuring out the current process and cpu times. To demonstrate this, do asuand do awand aw -u. go ahead, do the experiment, it's lowkey satisfying.-s,--shortโ Use the short format. Don't print the login time, JCPU or PCPU times. less is more fr fr.-t,--terminalโ Usuallywwill use either the systemd sessions table or theutmpfile to locate users. In terminal modewwill scan the terminal devices and locate user sessions this way. This is not a true count of users, for example a user with two xterms will show up twice, so the user count in the header will be different. Currently terminal devices scanned are/dev/tty*and/dev/pts/*.-f,--fromโ Toggle printing the from (remote hostname) field. The default as released is for the from field to not be printed, although your system administrator or distribution maintainer may have compiled a version in which the from field is shown by default. so like. it depends on your build, bestie ๐--helpโ Display help text and exit.-i,--ip-addrโ Display IP address instead of hostname for from field. This option only works on non-systemd platforms aslibsystemdonly provides the remote host. so on systemd it's just. not doing that. ๐-p,--pidsโ Display pid of the login process/the "what" process in the "what" field. The login process is also called the session leader. slay, session leader is such a title.-V,--versionโ Display version information.-o,--old-styleโ Old style output. Prints blank space for idle times less than one minute. vintage aesthetic โจuserโ Show information about the specified user only. just the one, pls and thank u.
๐ ENVIRONMENT ๐
PROCPS_CONTAINERโ If$PROCPS_CONTAINERis set, thenwbehaves as if the--containeroption has been given.PROCPS_USERLENโ Override the default width of the username column. Defaults to8.PROCPS_FROMLENโ Override the default width of the from column. Defaults to16.
๐ธ FILES ๐ธ
/var/run/utmpโ information about who is currently logged on, only for non-systemd hosts./procโ process information/dev/tty*,/dev/pts/*โ Terminal device files scanned with--terminalmode.
๐ BUGS ๐
not me exposing the flaws but okay, transparency is iconic:
- When using
--terminaloption,wassumes processes with a parent PID of0or1areagetty(8)processes and will not display them. This is prone to both false positive and negative errors. ๐ญ - Idle time for users on certain sessions, such as X/Wayland sessions, will be incorrect. The
--terminaloption will show the correct idle times for terminal sessions on X/Wayland. - On platforms using
systemd(1)the--ip-addroption will be ignored and the from column will report the remote host as either a hostname or IP address. yeah. it just does that.
๐ฎ REPORTING BUGS ๐ฎ
Please send bug reports to procps@freelists.org. they're literally waiting for your email bestie, don't be shy ๐
๐ SEE ALSO ๐
free(1), loginctl(1), ps(1), systemd(1), top(1), uptime(1), who(1), utmp(5), agetty(8)
and that's the whole vibe!! this page is from procps-ng, dated 2025-11-29 โ so you know it's fresh, no cap. go forth and w responsibly, bestie ๐โจ๐๐ฆ๐ธ๐
๐ซถ๐
๐ฆ where this page comes from
- arch rolling: procps-ng 4.0.7-1 ยท GPL AND LGPL
- nixpkgs unstable: procps 4.0.7
- Copyright (c) 2009-2025 Craig Small <csmall@dropbear.xyz>
- Copyright (c) 2015-2024 Jim Warner <james.warner@comcast.net>
- Copyright (c) 2012-2013 Jaromir Capik <jcapik@redhat.com>
- Copyright (c) 2011-2012 Sami Kerola <kerolasa@iki.fi>
- Copyright (c) 2002-2004 Albert Cahalan
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms