Configure Linux Server
- root@host:~ vi /etc/selinux/conf ; SELINUX=disable
- root@host:~ vi /etc/sysconf/network-script/ifc-eth0 ; ONBOOT = "yes"
- root@host:~ yum update
- root@host:~ mkdir setup ; root@host:~ cd setup ; root@host:~ wget http://layer1.cpanel.net/latest ; root@host:~ sh ./latest
- root@host:~ yum install httpd ; root@host:~ chkconfig --levels 235 httpd on ; root@host:~ /etc/init.d/httpd start ; Note: This is typically installed with CentOS by default
- root@host:~ yum install php ;
- root@host:~ /etc/init.d/httpd restart
- ; you have to add a firewall exception: ...first turn it off: # service iptables stop # nano /etc/sysconfig/iptables ...need to add rule: -A INPUT -m state --state NEW -m tcp -p tcp --dport 80 -j ACCEPT ...then start firewall again #service iptables start ...if you want to remotely access MySQL as well (I do) you also add: -A INPUT -m state --state NEW -m tcp -p tcp --dport 3306 -j ACCEPT
- SELINUX=permissive
- root@host:~ yum install mysql mysql-server ;
- root@host:~ chkconfig --levels 235 mysqld on ; root@host:~ /etc/init.d/mysqld start
- root@host:~ mysql_secure_installation
- 1 views today
- 1 uses today
Tips
Basic server configuration