转自http://blog.163.com/lin_jianying/blog/static/13093558620121395921609/
红帽中出现This system is not registered with RHN这个的原因是因为红帽中没有注册RHN。解决办法:(假定你已安装yum,且网络畅通)更改yum的源,即更换/etc/yum.repos.d /rhel-debuginfo.repo 这个文件。进入/etc/yum.repos.d/目录,终端中输入wget http://docs.linuxtone.org/soft/lemp/CentOS-Base.repo即可在此目录下得到CentOS- Base.repo文件,这是centos的源文件,只需将其重命名为rhel-debuginfo.repo即可,以前的文件做个备份。
httpd(httpserver):http://httpd.apache.org/download.cgi#apache24
下载httpd,注意最好别用最新版本,否则安装过程中提示apr版本过低
# tar xvzf httpd-2.2.6.tar.gz
# cd httpd-2.2.6
# ./configure --enable-dav --enable-so --enable-mods-shared=all --prefix=/usr/local/apache2
# make
# make install
(或者合并为一步#make && make install)
编辑配置文件httpd.conf
# vi /usr/local/apache2/conf/httpd.conf
修改内容:
ServerName www.example.com:80 为
ServerName localhost:80或者Apache服务器的IP
安装完成并修改后,启动apache进程:/usr/local/apache2/bin/apachectl start(或者在/usr/local/apache2/bin/下,用./httpd –k start),然后打开浏览器
http://localhost/,如果有测试页"It works!"出现,则证明已经安装成功。