Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I try to install apache,php and mysql server by these commands.

yum install httpd
yum install php
install mysql-server mysql
service httpd start
service mysqld start to start your mysql server

after that,they were install completely,because I can make php file and run it by

php test.php
command. now I want to see this page with out ssh and in my browser,I type my VPS ip address in browser but it doesn't response to me.

test.php file is in var/www folder with 777 permission.

share|improve this question
    
It shoud be under /var/www/html directory –  ghm1014 Aug 11 '11 at 15:37
    
Does it just time out? Or are you getting an error such as file not found / forbidden? This could be a problem in many places. Start by checking your document root is in fact /var/www/ in /etc/httpd/conf/httpd.conf –  Richard Holloway Aug 11 '11 at 15:38

1 Answer 1

up vote 1 down vote accepted

Check apache (httpd) configuration in /etc/httpd/conf/httpd.conf. For example, it maybe like this (my apache configuration on Debian):

<VirtualHost *:80>
    ServerName your-server-hostname
    ServerAdmin webmaster@localhost

    DocumentRoot /var/www
    <Directory />
            Options FollowSymLinks
            AllowOverride None
    </Directory>
    <Directory /var/www/>
            Options Indexes FollowSymLinks MultiViews
            AllowOverride None
            Order allow,deny
            allow from all
    </Directory>
</VirtualHost>
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.