diff --git "a/02 \346\236\227\346\231\237\350\276\211/.keep" "b/02 \346\236\227\346\231\237\350\276\211/.keep" new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git "a/02 \346\236\227\346\231\237\350\276\211/20240515 \345\210\235\350\257\206Liunx.md" "b/02 \346\236\227\346\231\237\350\276\211/20240515 \345\210\235\350\257\206Liunx.md" new file mode 100644 index 0000000000000000000000000000000000000000..4ae51f9a02ad5f185dbdd4e4e705903d4a1386ba --- /dev/null +++ "b/02 \346\236\227\346\231\237\350\276\211/20240515 \345\210\235\350\257\206Liunx.md" @@ -0,0 +1,48 @@ +## Liunx + +``` +一种操作系统内核,有centos,debian,redhat等。 +``` + +## 命令 + +### 查看ip地址 + +```js +ip addr show +``` + +### ssh + +```js +apt-get install ssh + +apt-get install vim + +vim /etc/ssh/sshd_config + +port 21 打开端口 + +permitrootlogin yes 启用root登录 + +passwordauthentication yes 验证密码 + +permitemptypasswords no 禁止使用空密码登录 + +/etc/init.d/ssh restart +``` + +### sudo + +``` +su root 更换给root模式 + +apt-get install sudo + +sudo vim /etc/sudoers + +root all=(all:all) all + +用户名 all=(all:all) all 添加用户名 +``` +