Linux|Linux -- 用户管理

【Linux|Linux -- 用户管理】一、Linux用户登录
1、打开Xshll 7 -> 点击文件 -> 点击新建
Linux|Linux -- 用户管理
文章图片

2、创建会话名称--主机位置填服务器的公网ip
Linux|Linux -- 用户管理
文章图片

Linux|Linux -- 用户管理
文章图片

3、连接
Linux|Linux -- 用户管理
文章图片

4、连接成功
Linux|Linux -- 用户管理
文章图片

5、 增添一个名为 xxp 的新用户,必须以root身份来添加

[root@VM-24-3-centos lesson1]# adduser xxp [root@VM-24-3-centos lesson1]# ls /home/// 查看腾讯云建有多少用户 lighthousenicexxp

6、为新添加的用户设置密码
[root@VM-24-3-centos lesson1]# ls /home/ lighthousenicexxp [root@VM-24-3-centos lesson1]# passwd xxp Changing password for user xxp. New password: BAD PASSWORD: The password contains the user name in some form Retype new password: passwd: all authentication tokens updated successfully. [root@VM-24-3-centos lesson1]#

7、查看当前用户
[root@VM-24-3-centos lesson1]# whoami root

8、删除用户
[root@VM-24-3-centos ~]# ls /home/ lighthousenicexxp [root@VM-24-3-centos ~]# userdel -r xxp [root@VM-24-3-centos ~]# ls /home/ lighthousenice

9、命令行登录用户
[xxp@VM-24-3-centos ~]$ ssh xxp@101.43.223.6 The authenticity of host '101.43.223.6 (101.43.223.6)' can't be established. ECDSA key fingerprint is SHA256:0yx7XnH3pPmsr2JUyNt2HYNXnh9NAXYI099j2lzD2os. ECDSA key fingerprint is MD5:f2:57:d1:de:63:48:b1:93:38:3e:1b:08:44:a8:8c:c8. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added '101.43.223.6' (ECDSA) to the list of known hosts. xxp@101.43.223.6's password: Last login: Sun Mar6 16:49:07 2022 from 101.43.223.6 [xxp@VM-24-3-centos ~]$ whoami xxp

★★★★★ 感谢阅读!

    推荐阅读