centos6 だとエラーが出るので
epel.repo を https to http
https://stackoverflow.com/a/27901957/9116095
http://www.wegirls.tech/entry/2016/09/29/075200
/usr/sbin/apachectl start
で起動
IPで表示できるようにしてみる。
https://hombre-nuevo.com/vps/vps0010/
/sbin/chkconfig --list httpd
/sbin/chkconfig --level 2345 {サービス名} on / off
https://qiita.com/shotaTsuge/items/9f337bad9f73c3953af1
$ /sbin/chkconfig --list httpd
httpd 0:off 1:off 2:off 3:off 4:off 5:off 6:off
Run Level | 状態 |
---|---|
0 | システムの停止 |
1 | シングルユーザモード |
2 | マルチユーザモード |
3 | マルチユーザモード(コンソールログイン) |
4 | 未使用 |
5 | マルチユーザモード(ディスプレイマネージャ使用) |
6 | システム再起動 |
https://qiita.com/shell/items/30031862d91cedf9ceef
###起動確認
/sbin/service httpd status
一覧表示
iptables -L
開ける
$ sudo iptables -I INPUT -p tcp -m tcp --dport 80 -j ACCEPT
$ sudo service iptables save