리눅스 계정 목록 보기

Jmnote (토론 | 기여)님의 2012년 8월 16일 (목) 12:31 판 (→‎전체 목록)
리눅스 계정 목록 보기
리눅스 계정 목록 확인
리눅스 계정 확인

1 전체 목록

명령어
cut -f1 -d: /etc/passwd
cat /etc/passwd
예시
[root@jmnote ~]# cut -f1 -d: /etc/passwd
root
bin
daemon
adm
sync
shutdown
halt
mail
news
operator
games
gopher
ftp
nobody
dbus
nscd
avahi
mailnull
smmsp
apache
vcsa
rpc
ntp
sshd
pcap
haldaemon
rpm
hsqldb
xfs
gdm
mysql
oprofile
named
[root@jmnote ~]# cat /etc/passwd
root:x:0:0:root:/root:/bin/bash
bin:x:1:1:bin:/bin:/sbin/nologin
daemon:x:2:2:daemon:/sbin:/sbin/nologin
.. (생략)
mysql:x:27:27:MySQL Server:/var/lib/mysql:/bin/bash
oprofile:x:16:16:Special user account to be used by OProfile:/home/oprofile:/sbin/nologin
named:x:25:25:Named:/var/named:/sbin/nologin

2 셸 사용 계정 목록

명령어
cat /etc/passwd | grep /bin/bash
cat /etc/passwd | grep /bin/bash | cut -f1 -d:
예시
[root@jmnote ~]# cat /etc/passwd | grep /bin/bash
root:x:0:0:root:/root:/bin/bash
mysql:x:27:27:MySQL Server:/var/lib/mysql:/bin/bash
[root@jmnote ~]# cat /etc/passwd | grep /bin/bash | cut -f1 -d:
root
mysql

3 같이 보기

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}