This commit is contained in:
nick 2018-12-24 22:05:54 +08:00
parent e69f8ab0ad
commit 165805ca28
3 changed files with 21 additions and 1 deletions

View File

@ -10,6 +10,13 @@
无论是源码编译安装还是通过包管理器 `yum``apt-get` 安装的软件,默认都是需要设置开机自启动,单纯的启动服务,如果服务器有重启的话,程序无法运行,还要登录服务器排查原因,费事费力。
## `Linux``Windows` 最大的区别
1. 名称区分大小写
2. 系统路径
3. 文件权限
4. 一切皆文件
## 关于 Linux 命令的几个分类
- 内置命令

View File

@ -20,3 +20,5 @@
- __`namp` 网络嗅探工具__
- __`sqlmap` 数据库扫描工具__
- __`ssh-copy-id`__ 公私钥快捷上传工具

View File

@ -5,6 +5,15 @@
ssh-keygen -t rsa #生成的公钥匙在 ~/.ssh/ 目录下
```
第二步,把公钥上传到服务器端,登录服务器追加公钥到 authorized_keys 文件
__简单版__
```
ssh-copy-id -i ~/.ssh/id_rsa.pub username@ip
```
__复杂版__
```
scp id_rsa.pub root@ip地址:文件保存路径
ssh root@ip #登录服务器
@ -14,6 +23,8 @@ cat id_rsa.pub >> /root/.ssh/authorized_keys 追加到文件中
```
> 如果 .shh 目录或 authorized_keys 文件不存在需要自己新建
第三步,修改服务器端 ssh 配置文件 /etc/ssh/sshd_config
```