最終更新:2022-09-14 (水) 04:57:30 (590d)
tokkyo/設定/さくらのVPS/CentOS 7
更新
- yum update
ユーザ追加
ネットワーク周り
tokkyo/設定/SSH
- systemctl status sshd.service
- sshd -T
- Linux/etc/ssh/sshd_config
chmod 700 .ssh chmod 600 .ssh/authorized_keys
ホスト名
Apache
- yum install httpd
- systemctl enable httpd.service
Created symlink from /etc/systemd/system/multi-user.target.wants/httpd.service to /usr/lib/systemd/system/httpd.service.
- systemctl start httpd.service
ファイアウォール
- firewall-cmd --permanent --zone=public --add-service=http
- firewall-cmd --reload
コンテンツの同期
- rsync
rsync src dst nohup rsync -avz -e ssh /var/www/dest example.com:/var/www &
Munin
- Linux/etc/httpd/conf.d/munin.conf?を作成
#In version 2.3.6, loading mod_status will toggle ExtendedStatus On by default. #ExtendedStatus On <Location /server-status> SetHandler server-status Order deny,allow # Allow from all Deny from all Allow from 127.0.0.1 </Location>
Apacheを監視対象に追加
ln -s /usr/share/munin/plugins/apache_accesses /etc/munin/plugins/apache_accesses ln -s /usr/share/munin/plugins/apache_processes /etc/munin/plugins/apache_processes ln -s /usr/share/munin/plugins/apache_volume /etc/munin/plugins/apache_volume
munin-nodeを自動起動
- systemctl start munin-node
- systemctl enable munin-node
Subversion
PHP
- yum install php
MySQL (MariaDB)
- yum install mysql mariadb-server
- MariaDBが入る
- systemctl enable mariadb
- systemctl start mariadb
- Linux/etc/my.cnf.d?に下記を追加
カーネル
起動 | パッケージ有無 | initramfs | ||
kernel-3.10.0-957.21.3.el7.x86_64.rpm? | CentOS 7.6? | ☓ | ○ | ☓ |
kernel-3.10.0-957.12.2.el7.x86_64.rpm? | CentOS 7.6? | ○ | ○ | ○ |
kernel-3.10.0-957.10.1.el7.x86_64.rpm? | CentOS 7.6? | ○ | ○ | ○ |
kernel-3.10.0-957.5.1.el7.x86_64.rpm? | CentOS 7.6? | 未 | ○ | ○ |