服务器操作

2016-11-08  本文已影响0人  依哥

marager

生成秘钥

G33G7PAM)YYD$LIYEQVIL}W.png

![]AE1RMQC)LR9UC1A5F%_U}S.png](https://img.haomeiwen.com/i2916990/5d49a7d36d671452.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)

![F]AVPOCAQBG]_C~OI`7HQE7.png](https://img.haomeiwen.com/i2916990/f20352e9107d1c10.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)

SCP命令

cat id_rsa.pub >> .ssh/authorized_keys

chmod 600 authorized_keys

为了保证服务器安全,我们将密码登录关闭

找到 etc/ssh/sshd_config 修改 PasswordAuthentication yes (如果有注释将#去掉,将yes改为no )

修改端口 : Port 1678(重启reboot 或 然后需要更新下sshd的配置:sudo systemctl reload sshd)
要使用 -p 选项,后面在加上 SSH 端口号。
ssh 192.168.0.103 -p 1234

IPtables

123

alias 别名

  1. vim .bash_profile
上一篇 下一篇

猜你喜欢

热点阅读