查看系统版本
cat /etc/redhat-release
//输出:CentOS Linux release 7.5.1804 (Core)
查看psswd
less /etc/passwd
临时设置IP
ifconfig ens33 192.168.1.1
4-6日
递归创建目录加上-r
复制目录也要加-r
1.将/mnt/public/linux.txt文件复制到/root目录下,同时 改名为 study.txt
cp /mnt/public/linux.txt /root/study
2.将/etc/passwd 、/etc/resolv.conf、/etc/hostname 同时拷贝到/mnt/public/目录下
[root@Z ~]# cp /etc/passwd /etc/resolv.conf /etc/hostname /mnt/public/
[root@Z ~]# ls /mnt/public/
3.将文件 /mnt/public/hostname 重改名为 stu.txt
[root@Z ~]# mv /mnt/public/hostname /mnt/public/stu.txt
[root@Z ~]# ls /mnt/public/
linux.txt passwd resolv.conf stu.txt
4.创建目录结构/mnt/public/test/vm
[root@Z ~]# mkdir /mnt/public/test
[root@Z ~]# mkdir /mnt/public/test/