+ -
当前位置:首页 → 问答吧 → 新来的女生linux新手,请大家帮助关照一下。

新来的女生linux新手,请大家帮助关照一下。

时间:2010-05-06

来源:互联网

本帖最后由 以琳清泉 于 2010-05-06 17:47 编辑

现在即将毕业,在一个做服务器相关服务的公司实习。
刚进这个领域不懂的太多,刚进公司也遇到很多的问题,这几天部门负责人让我学习web网站服务的相关内容,这几天看了一些视频和网上的资料,操作起来发现很多问题。
知道这个论坛,所以想以后多来请教请教吧,请大家多多关注和帮助。谢谢 ^_^

另附今天的问题:

在虚拟机上编译安装好apache之后
用chkconfig --list |grep httpd 并没有任何内容;
service httpd start    提示 httpd: 未被识别的服务,只能通过  安装目录/httpctl   start 来操作;
而且如果设置是listen 80 的话 服务是无法启动的, 改成8080后可以;
安装完php之后,在  apahce安装目录/htdoc  下面 写一个 test.php  --test.php 内容 为<?php  echo phpinfo(); ?>,在浏览器中输入  http://localhost:8080/test.php
结果他是把test.php里面的代码原封不动的显示出来,而不是预期的效果。

这是今天遇到的一些问题。
虽然可能比较小,但是是影响我下一步学习的坎,还请有经验的前辈们有时间帮助知道一下。

我的QQ:464977961
Msn       :[email protected]

作者: 以琳清泉   发布时间: 2010-05-06

compile and install apache server.don't configure automatically your chkconfig environment.consequently you have to start you apche with apachectl this comand.

while listening on 80.you don't start your apache which indicates 80 port in your computer is in use.first you have to stop your existing  web server.

directly appear all codes of your php file in your web browsers which tell you your apache don't work with your php.recommand you to carefully read installation materials about php and apache.

作者: todayhero   发布时间: 2010-05-07

回复 todayhero


    Thank you very much!!

作者: 以琳清泉   发布时间: 2010-05-07

回复 todayhero

你说的第二点我昨天就已经查看了,下面是结果。当时就不知道怎么处理,所以改成8080端口了。但是今天感觉这样很不方便或者以后会有什么问题。还望继续赐教^_^
[root@bogon extra]# cat /etc/services |grep 80
http            80/tcp          www www-http    # WorldWideWeb HTTP
http            80/udp          www www-http    # HyperText Transfer Protocol

作者: 以琳清泉   发布时间: 2010-05-07

回复 以琳清泉


    /etc/services this files only introduces some informations  about port and service name to you.can not tell you what service is in use on your computer.

"netstat -lnp" can tell you what service is in use?for example.

[root@blog root]# netstat -lnp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name   
tcp        0      0 0.0.0.0:5666            0.0.0.0:*               LISTEN      728/xinetd         
tcp        0      0 0.0.0.0:873             0.0.0.0:*               LISTEN      777/rsync           
tcp        0      0 0.0.0.0:3306            0.0.0.0:*               LISTEN      16489/mysqld                 #mysql server is using 3306 port.
tcp        0      0 60.156.40.98:80         0.0.0.0:*               LISTEN      27095/httpd                #web server is using 80 port.
tcp        0      0 0.0.0.0:4949            0.0.0.0:*               LISTEN      833/munin-node      
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      714/sshd            
udp        0      0 60.156.40.98:123        0.0.0.0:*                           741/ntpd            
udp        0      0 127.0.0.1:123           0.0.0.0:*                           741/ntpd            
udp        0      0 0.0.0.0:123             0.0.0.0:*                           741/ntpd            
Active UNIX domain sockets (only servers)

作者: todayhero   发布时间: 2010-05-07

回复 以琳清泉


    Are you in Beijing?

作者: todayhero   发布时间: 2010-05-07

yeah

作者: 以琳清泉   发布时间: 2010-05-07

回复 todayhero


  Oh,  I see .I will try again . Thank you again ^_^

作者: 以琳清泉   发布时间: 2010-05-07

回复 todayhero


    yeah,I am in beijing.

作者: 以琳清泉   发布时间: 2010-05-07

热门下载

更多