【160126】服务器管理记录
-
whereis sudoers
chmod u+w /etc/sudoers
sudo nano /etc/sudoers
chmod u-w /etc/sudoers -
Download
sudo apt-get install nginx
sudo apt-get install php5-cli php5-cgi mysql-server php5-mysql
sudo apt-get install php5-fpmEdit profile
sudo nano /etc/nginx/sites-available/default
root /var/www/html; index index.php index.html index.htm;
location ~ \.php$ { include /etc/nginx/fastcgi_params; #需放在第一行,否则会出错 fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME /var/www/nginx-default$fastcgi_script_name; }
Run
sudo spawn-fcgi -a 127.0.0.1 -p 9000 -C 10 -u www-data -f /usr/bin/php-cgi
/etc/init.d/nginx start
【160126】服务器管理记录