Find the answer to your Linux question:
Results 1 to 5 of 5
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Issue with Apache

    I just installed a centos server and am having issues understanding where to modify my apache config files so that I can access the web pages I have created.

    I'm still operating on my LAN.
    I can access the server via ssh on another computer on LAN

    I can access the page located at 192.168.X.X/test.php from the server itself (should be obvious). However, when I try to access the 192.168.x.x/test.php page from a web browser on my other computer on the LAN it says 'Cannot connect to server'. I can also ping from this other computer to the server fine.

    Would there be some setting in the httpd.conf file that I need to set that's by default set to deny from all from a fresh install? I do not see anything in the apache logs suggesting that the computer attempted to connect to the server
    Last edited by saxophonemaster; 05-19-2012 at 12:09 AM.

  2. #2
    your apache config files should be in /etc/httpd/conf/ and /etc/httpd/conf.d/, but that is probably not your problem.

    it is probably the firewall. try turning it off on the webserver pc:

    service iptables stop
    if that is it, you can add a rule to allow it.

  3. #3
    Linux Engineer
    Join Date
    Apr 2012
    Virginia, USA
    On CentOS / Red Hat/ Scientific, iptables is on and enforcing a bunch of rules from the start.
    This article has some basic settings for CentOS web servers: Configuring CentOS 6 Web Server
    See Step 4 for iptables information. That whole article is actually quite useful for CentOS 6 (most things should apply to CentOS 5 as well)

  4. $spacer_open
  5. #4
    Just Joined!
    Join Date
    May 2011
    Try to telnet to the destination server's port and you can be 100% sure that you're blocked by the iptables

  6. #5
    Linux Newbie
    Join Date
    Jan 2012
    yum install system-config-firewall-tui
    Then as root
    system-config-firewall-tui and open up HTTP
    Then make sure that your document root is set up properly.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts