[vbird1@study ~]$
grep vbird1 /etc/passwd
vbird1:x:1003:1004:
VBird Tsai test,DIC in KSU,06
-
2727175#356,06
-
1234567
:/home/vbird1:/bin/bash
#
就是改到第五
字段,
字段里面用多
,
』分隔就是了!
[vbird1@study ~]$
finger vbird1
Login: vbird1
Name: VBird Tsai test
Directory: /home/vbird1
Shell: /bin/bash
Office: DIC in KSU, 06
-
2727175#356 Home Phone: 06
-
1234567
Last login Mon Jul 20 23:12 (CST) on pts/0
No mail.
Plan:
I will study Linux during this year.
#
就是上面特殊字体呈
的那些地方是由
chfn
所修改出
的!
这个指令说实在的,除非是你的主机有很多的用户,否则倒真是用不着这个程序!这就有点像是
bbs
里头更改你『个人属性』的那一个资料啦!不过还是可以自己玩一玩!尤其是用来提醒自己相关资料
啦!
^_^
.
chsh
这就是
change shell
的简写!使用方法就更简单了!
[vbird1@study ~]$
chsh [
-
ls]
选项
参数
-
l
:列出目前系
上面可用的
shell
,其
就是
/etc/shells
容!
-
s
定修改自己的
Shell
范例一:用
vbird1
的身份列出系
上所有合法的
shell
,并且指定
csh
自己的
shell
[vbird1@study ~]$
chsh
-
l
/bin/sh
/bin/bash
/sbin/nologin
<==
:合法不可登入的
Shell
就是
玩意!
/usr/bin/sh
/usr/bin/bash
/usr/sbin/nologin
/bin/tcsh
/bin/csh
<==
就是
C shell
啦!
#
上面的信息就是我
bash
到的
/etc/shells
啦!
[vbird1@study ~]$
chsh
-
s /bin/csh; grep vbird1 /etc/passwd
Changing shell for vbird1.
Password:
<==
身份,
请输
vbird1
的密
Shell changed.