linux apache+tomcat环境配置

配置前需要下载 tar xvfz httpd-2.0.54.tar.gz

cd /usr/local/

  
  # cd /usr/local/
  
  # tar xvfz httpd-2.0.54.tar.gz
  
  # cd httpd-2.0.54
  
  # ./configure –prefix=/usr/local/apache –enable-module=so
  
  # make
  
  # make install
  
  # cd /usr/local/apache/conf
  
  # vi ./httpd.conf
  
  将Listen 80 修改为Listen 127.0.0.1:80 (219行)
  
  将ServerName 修改为ServerName LocalHost:80 (291行)
  
  在DirectoryIndex中添加 index.jsp (394行)
  
  # cd /usr/local/apache/bin/
  
  # ./apachectl configtest
  
  显示Syntax ok则表明安装成功
  
  #./apachectl start
  
  启动apache服务,浏览器中访问本机80端口,查看端口是否正常,输入127.0.0.1:80
  
  # ./apachectl stop
  
  关闭服务

你可能感兴趣的:(apache,tomcat,linux)