AIX新建用户修登录改密码问题

10124阅读 0评论2011-12-29 feiaix
分类:系统运维

root:!:0:0::/:/usr/bin/ksh
daemon:!:1:1::/etc:
bin:!:2:2::/bin:
sys:!:3:3::/usr/sys:
adm:!:4:4::/var/adm:
uucp:!:5:5::/usr/lib/uucp:
guest:!:100:100::/home/guest:
nobody:!:4294967294:4294967294::/:
lpd:!:9:4294967294::/:
lp:*:11:11::/var/spool/lp:/bin/false
invscout:*:6:12::/var/adm/invscout:/usr/bin/ksh
snapp:*:200:13:snapp login user:/usr/sbin/snapp:/usr/sbin/snappd
ipsec:*:201:1::/etc/ipsec:/usr/bin/ksh
nuucp:*:7:5:uucp login user:/var/spool/uucppublic:/usr/sbin/uucp/uucico
pconsole:*:8:0::/var/adm/pconsole:/usr/bin/ksh
esaadmin:*:10:0::/var/esa:/usr/bin/ksh
sshd:*:206:201::/var/empty:/usr/bin/ksh
atc:!:8000:400:Adam Cormany,Sr UNIX Admin:/home/atc:/bin/ksh
amdc:!:8001:401:AMDC:/home/amdc:/bin/ksh
pac:!:8002:400:PAC,Jr UNIX Admin:/home/pac:/bin/ksh
atc2:!:8003:402:ATCv2:/home/atc2:/bin/ksh

Username : Password Flag : UID : GID : GECOS : Home : Shell/Command


Here's the line-by-line breakdown:

新建立用户之后执行命令:

#pwdadm username      */ 修改密码

#pwdadm -c username   */在/etc/security/passwd中, -f flags有3个选项,此命令可以去掉ADMCHG选项

NOCHECK
Signifies that new passwords need not follow the guidelines established in the /etc/security/user file for password composition.
ADMIN
Specifies that password information may be changed only by the root user. Only the root user can enable or disable this attribute.
ADMCHG

 Resets the ADMCHG attribute without changing the user's password. This forces the user to change passwords the next time a login command or an su command is given for the user. The attribute is cleared when the user specified by the User parameter resets the password.

#pwdadm -q username  */查询状态

如果没有ADMCHG,则登录后不需要修改密码.

也可以通过查看/etc/security/passwd查看用户信息.

修改GECOS字段的一些信息:

-f wzf
 wzf's current gecos:
                "wangfei"
 Change (yes) or (no)? > y
 To?>Tom
wzf /etc/passwd
wzf:!:206:1:Tom:/home/wzf:/usr/bin/ksh
wzf
 wzf's current gecos:
                "Tom"
 Change (yes) or (no)? > y
 To?>James

-l wzf
Login name: wzf                       In real life: James
Directory: /home/wzf                    Shell: /usr/bin/ksh
No Plan.

 

 

上一篇:RedHat Linux AS4远程控制管理配置(VNC config)
下一篇:检查点与实例恢复