fateame 发表于 2015-8-20 09:16:58

lamp server快速搭建

  一、安装
  sudo apt-get install tasksel
  sudo tasksel
  选择LAMP server ,开始安装,发布的程序会保存在 /var/www 下
  mysql web 管理工具
  sudo apt-get install phpmyadmin
  配置文件:
  apache比较多,但我看了下,大多都在 /etc/apache2 下,可以自己摸索以下
  /etc/apache2/apache2.conf
  /etc/apache2/sites-enabled/000-default    DocumentRoot 这个比较有用!
  /etc/php5/apache2/php.ini
  启动
  sudo /etc/init.d/apache2 start
  sudo mysql -uroot -p***
  
  二、安全加固:
  隐藏apache版本信息
  /etc/apache2/apache2.conf
  ServerSignature Off
  ServerTokens Prod
  隐藏php版本信息
  /etc/php5/apache2/php.ini
  expose_php = Off
  禁止php危险函数
  disable_functions
  加固ssh 修改默认端口22
  /etc/ssh/sshd_config
  PermitRootLogin = no
页: [1]
查看完整版本: lamp server快速搭建