当前位置: > Linux服务器 > apache >

apache添加rewrite模块问题与解决方法

时间:2014-12-26 01:29来源:linux.it.net.cn 作者:IT

在apache中添加rewrite功能,操作方法:
 

 
cd /usr/local/src/httpd-2.2.9/modules/mappers 
/usr/local/apache2/bin/apxs -c mod_rewrite.c 
/usr/local/apache2/bin/apxs -i -a -n rewrite mod_rewrite.la

安装过程中,报错。 
Warning! dlname not found in /usr/local/apache2/modules/mod_rewrite.la.  
Assuming installing a .so rather than a libtool archive.  
chmod 755 /usr/local/apache2/modules/mod_rewrite.so  
chmod: cannot access `/usr/local/apache2/modules/mod_rewrite.so': No such file or directory  
apxs:Error: Command failed with rc=65536  

解决方法:
vi /usr/local/apache2/build/libtool
 

build_libtool_libs=no  
↓  
build_libtool_libs=yes  
  
fast_install=neel***  
↓  
fast_install=yes  
  
dlopen_support=unknown  
↓  
dlopen_support=yes  
  
dlopen_self=unknown  
↓  
dlopen_self=yes  
  
dlopen_self_static=unknown  
↓  
dlopen_self_static=yes  
  
host_alias=  
↓  
host_alias=i686-pc-linux-gnu

如上修改后,重新安装rewrite模块即可成功。





(责任编辑:IT)
------分隔线----------------------------