LoginSignup
4
4

More than 5 years have passed since last update.

Linux初回設定メモ

Posted at

いつも忘れるのでメモ。
初回起動後の設定。

ユーザ追加

useradd -g users issei
passwd issei

参考:http://qiita.com/Tooooomin/items/c063cee80227a5f1d95b

sudoersへの追加

usermod -G wheel issei
grep wheel /etc/group

sudoersを編集する

visudo

ここのコメントアウトを解除すれば良い
※Conohaのcentos7で試した際は、最初から解除済みだった

## Allows people in group wheel to run all commands
%wheel  ALL=(ALL)       ALL

rootユーザのSSHログイン禁止

/etc/ssh/sshd_config
#PermitRootLogin yes
PermitRootLogin no

sshd再起動

systemctl restart sshd.service
systemctl status sshd.service

参考:http://kazmax.zpp.jp/linux/lin_ssh.html
http://qiita.com/haisaihiroki/items/c38cb3c0a331db9b6f69

4
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
4