loginctl 查看用户信息

最后更新于:2022-04-02 03:49:20

[TOC] ## loginctl 查看当前登录的用户 ### 列出当前session ``` $ loginctl list-sessions ``` ### 列出当前登录用户 ``` $ loginctl list-users ``` ### 列出显示指定用户的信息 ``` > loginctl show-user im_user UID=1001 GID=1001 Name=im_user Timestamp=Fri 2019-12-13 16:57:24 CST TimestampMonotonic=9824518 RuntimePath=/run/user/1001 Slice=user-1001.slice State=closing Sessions=c1 IdleHint=no IdleSinceHint=0 IdleSinceHintMonotonic=0 Linger=no ```
';