`

linux命令

 
阅读更多
1.增加用户 用户名 test01
useradd test01

2.无须交互为用户设置密码 用户名test01 密码 pass01
echo test01 : pass01 | chpasswd
echo ‘pass01’ | passwd --stdin test01

3.删除文件夹中除“test*.txt”的文件
find -type f \-! -name "test*.txt" -exec rm {} \;
rm -rf `ls | grep -v 'test*.txt'`
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics