My website is showing apache2 page

Discussion in 'General' started by wachira, Nov 19, 2010.

  1. wachira

    wachira New Member

    I am running ispconfig 3 on CentOS i host a couple of websites I recently added one mor site on my server but when i pullit up it has the apache 2 site on it. I noticed all my other sites are doing the same pulling up apache 2 page except my server web page any idea why this is happening
     
    Last edited: Nov 19, 2010
  2. falko

    falko Super Moderator Howtoforge Staff

    Did you select * as the IP address for your web sites, or did you select a specific IP address?
     
  3. wachira

    wachira New Member

    I selected my server IP address
     
  4. falko

    falko Super Moderator Howtoforge Staff

    Can you post one of your Apache vhost configuration files?
    Any errors in Apache's error log?
     
  5. wachira

    wachira New Member

    This is what i get when i run ls -ld /var/www/html
    drwxr-xr-x 2 root root 4096 Nov 20 10:13 /var/www/html
    And whe I run ls -l /var/www/html it give me this
    total 0

    This is what is in httpd.conf
    # Defaults for virtual hosts

    # Logs

    #
    # Virtual hosts
    #

    # Virtual host Default Virtual Host
    <VirtualHost *:80>


    ServerAdmin [email protected]





    DirectoryIndex index.php index.html index.htm index.shtml












    LogLevel debug
    HostNameLookups off




    </VirtualHost>



    #
    # Each directory to which Apache has access can be configured with respect
    # to which services and features are allowed and/or disabled in that
    # directory (and its subdirectories).
    #
    # Note that from this point forward you must specifically allow
    # particular features to be enabled - so if something's not working as
    # you might expect, make sure that you have specifically enabled it
    # below.
    #

    <Directory "/">
    Options FollowSymLinks

    AllowOverride None



    </Directory>

    <Directory "/var/www/html">
    Options Indexes Includes FollowSymLinks

    AllowOverride None
    Allow from all


    Order allow,deny
    </Directory>

    <Directory "/var/www/icons">
    Options Indexes MultiViews

    AllowOverride None
    Allow from all


    Order allow,deny
    </Directory>

    <Directory "/var/www/cgi-bin">
    Options ExecCGI

    AllowOverride None
    Allow from all


    Order allow,deny
    </Directory>


    NameVirtualHost *:80
    NameVirtualHost *:443
    Include /etc/httpd/conf/sites-enabled/
    linuxcentos wachira is online now Click to check your reputation for this post Report This Post
     
  6. falko

    falko Super Moderator Howtoforge Staff

    Please post one of your Apache vhost configuration files from the /etc/httpd/conf/sites-enabled/ directory.

    Any errors in Apache's error log?
     
  7. wachira

    wachira New Member

    my error log has this out put
    [Sun Nov 21 04:07:33 2010] [notice] Digest: generating secret for digest authentication ...
    [Sun Nov 21 04:07:33 2010] [notice] Digest: done
    PHP Warning: Module 'mysql' already loaded in Unknown on line 0
    [Sun Nov 21 04:07:34 2010] [notice] mod_python: Creating 4 session mutexes based on 150 max processes and 0 max threads.
    [Sun Nov 21 04:07:35 2010] [notice] Apache/2.2.3 (CentOS) configured -- resuming normal operations


    And my Apache Vhost config files
    total 12
    drwxr-xr-x 2 root root 4096 Nov 19 11:14 ./
    drwxr-xr-x 4 root root 4096 Nov 13 22:26 ../
    lrwxrwxrwx 1 root root 42 Nov 14 22:37 000-apps.vhost -> /etc/httpd/conf/sites-available/apps.vhost
    lrwxrwxrwx 1 root root 46 Apr 15 2010 000-ispconfig.conf -> /etc/httpd/conf/sites-available/ispconfig.conf
    lrwxrwxrwx 1 root root 47 Apr 15 2010 000-ispconfig.vhost -> /etc/httpd/conf/sites-available/ispconfig.vhost
    lrwxrwxrwx 1 root root 53 May 26 16:51 bethesdaemp.org.vhost -> /etc/httpd/conf/sites-available/bethesdaemp.org.vhost
    lrwxrwxrwx 1 root root 50 Nov 19 10:56 kenindus.com.vhost -> /etc/httpd/conf/sites-available/kenindus.com.vhost
    lrwxrwxrwx 1 root root 50 Apr 24 2010 wachkama.com.vhost -> /etc/httpd/conf/sites-available/wachkama.com.vhost
    (END)
     
  8. falko

    falko Super Moderator Howtoforge Staff

    Can you post the contents of /etc/httpd/conf/sites-available/kenindus.com.vhost or /etc/httpd/conf/sites-available/bethesdaemp.org.vhost or /etc/httpd/conf/sites-available/wachkama.com.vhost?
     
  9. wachira

    wachira New Member

    This is the output for /etc/httpd/conf/sites-available/kenindus.com.vhost
    <VirtualHost 192.168.1.7:80>
    DocumentRoot /var/www/clients/client0/web6/web

    ServerName kenindus.com
    ServerAlias www.kenindus.com
    ServerAdmin [email protected]

    ErrorLog /var/log/ispconfig/httpd/kenindus.com/error.log

    ErrorDocument 400 /error/400.html
    ErrorDocument 401 /error/401.html
    ErrorDocument 403 /error/403.html
    ErrorDocument 404 /error/404.html
    ErrorDocument 405 /error/405.html
    ErrorDocument 500 /error/500.html
    ErrorDocument 503 /error/503.html

    <Directory /var/www/kenindus.com/web>
    Options FollowSymLinks
    AllowOverride All
    Order allow,deny
    Allow from all

    # ssi enabled
    AddType text/html .shtml
    AddOutputFilter INCLUDES .shtml
    Options +Includes
    </Directory>
    <Directory /var/www/clients/client0/web6/web>
    Options FollowSymLinks
    AllowOverride All
    Order allow,deny
    Allow from all

    # ssi enabled
    AddType text/html .shtml
    AddOutputFilter INCLUDES .shtml
     
  10. falko

    falko Super Moderator Howtoforge Staff

    That's not the whole file...

    What's the output of
    Code:
    ls -la /var/www/clients/client0/web6/web/
    ?
    Does the DNS record for www.kenindus.com point to the correct server?
     
  11. wachira

    wachira New Member

    So I decided to get a new box and upgrade my hardware. I reinstalled my Centos and ispconfig 3.
    All went well as per the instalation but i cant get the GUi for ispconfig 3. All I get is cant connect to server any Idea why this is happening.
     
    Last edited: Nov 29, 2010
  12. falko

    falko Super Moderator Howtoforge Staff

    Please restart Apache. If this doesn't work, please post the outputs of
    Code:
    netstat -tap
    and
    Code:
    iptables -L
    . Also make sure that SELinux is disabled.
     
  13. wachira

    wachira New Member

    netstat -tap out put

    e PID/Program name
    tcp 0 0 localhost.localdomain:2208 *:* LISTEN 2258/hpiod
    tcp 0 0 *:imaps *:* LISTEN 2411/dovecot
    tcp 0 0 *:pop3s *:* LISTEN 2411/dovecot
    tcp 0 0 localhost.localdomain:10024 *:* LISTEN 2448/amavisd (maste
    tcp 0 0 localhost.localdomain:10025 *:* LISTEN 2503/master
    tcp 0 0 *:mysql *:* LISTEN 2382/mysqld
    tcp 0 0 *:pop3 *:* LISTEN 2411/dovecot
    tcp 0 0 localhost.local:dyna-access *:* LISTEN 2298/clamd
    tcp 0 0 *:imap *:* LISTEN 2411/dovecot
    tcp 0 0 *:sunrpc *:* LISTEN 1941/portmap
    tcp 0 0 *:883 *:* LISTEN 1973/rpc.statd
    tcp 0 0 *:ftp *:* LISTEN 2534/pure-ftpd (SER
    tcp 0 0 localhost.localdomai:domain *:* LISTEN 1923/named
    tcp 0 0 localhost.localdomain:ipp *:* LISTEN 2285/cupsd
    tcp 0 0 *:smtp *:* LISTEN 2503/master
    tcp 0 0 localhost.localdomain:rndc *:* LISTEN 1923/named
    tcp 0 0 localhost.localdomain:2207 *:* LISTEN 2263/python
    tcp 1 1 192.168.1.12:35211 mandril.creatis.insa-l:http LAST_ACK -
    tcp 0 0 192.168.1.12:39703 a184-84-220-64.deploy.:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:41099 nyc-v289.nyc.youtube.c:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:38154 a184-51-240-74.deploy.:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:58908 iad04s01-in-f154.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:58916 iad04s01-in-f154.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:33421 iad04s01-in-f147.1e10:https ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:51783 iad04s01-in-f147.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:40783 iad04s01-in-f166.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:40003 iad04s01-in-f100.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:40118 iad04s01-in-f132.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:48676 iad04s01-in-f189.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:38764 216.66.8.17:http TIME_WAIT -
    tcp 0 0 192.168.1.12:39876 static.205.16.40.188.c:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:39875 static.205.16.40.188.c:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:39874 static.205.16.40.188.c:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:39873 static.205.16.40.188.c:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:39872 static.205.16.40.188.c:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:48999 iad04s01-in-f83.1e100.:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:49003 iad04s01-in-f83.1e100.:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:49002 iad04s01-in-f83.1e100.:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:49001 iad04s01-in-f83.1e100.:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:49004 iad04s01-in-f83.1e100.:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:39871 static.205.16.40.188.c:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:39945 iad04s01-in-f149.1e100:http ESTABLISHED 10951/firefox
    tcp 0 0 192.168.1.12:43515 74.122.140.21:http ESTABLISHED 10951/firefox
    tcp 0 0 *:imaps *:* LISTEN 2411/dovecot
    tcp 0 0 *:pop3s *:* LISTEN 2411/dovecot
    tcp 0 0 *:pop3 *:* LISTEN 2411/dovecot
    tcp 0 0 *:imap *:* LISTEN 2411/dovecot
    tcp 0 0 *:http *:* LISTEN 2524/httpd
    tcp 0 0 *:ftp *:* LISTEN 2534/pure-ftpd (SER
    tcp 0 0 localhost6.localdoma:domain *:* LISTEN 1923/named
    tcp 0 0 *:ssh *:* LISTEN 2276/sshd
    tcp 0 0 localhost6.localdomain:rndc *:* LISTEN 1923/named
    tcp 0 0 *:https *:* LISTEN 2524/httpd
    [root@server1 wachkama]# iptables -L
    Chain INPUT (policy ACCEPT)
    target prot opt source destination

    Chain FORWARD (policy ACCEPT)
    target prot opt source destination

    Chain OUTPUT (policy ACCEPT)
    target prot opt source destination
     
  14. falko

    falko Super Moderator Howtoforge Staff

    Apache isn't listening on port 8080. Please try to restart it:
    Code:
    /etc/init.d/httpd restart
     
  15. wachira

    wachira New Member

    I have tried that but no success at all any idea on the next step
     
  16. falko

    falko Super Moderator Howtoforge Staff

    Is there something like
    Code:
    Listen 8080
    somewhere in your Apache configuration?
     
  17. wachira

    wachira New Member

    Listen 8080
    NameVirtualHost *:8080

    <VirtualHost _default_:8080>
    ServerAdmin webmaster@localhost

    <IfModule mod_fcgid.c>
    DocumentRoot /var/www/ispconfig/
    SuexecUserGroup ispconfig ispconfig
    <Directory /var/www/ispconfig/>
    Options Indexes FollowSymLinks MultiViews +ExecCGI
    AllowOverride AuthConfig Indexes Limit Options FileInfo
    AddHandler fcgid-script .php
    FCGIWrapper /var/www/php-fcgi-scripts/ispconfig/.php-fcgi-starter .php
    Order allow,deny
    Allow from all
    </Directory>
    </IfModule>
     
    Last edited: Dec 2, 2010
  18. wachira

    wachira New Member

    [root@server1 httpd]# tail -f error_log ssl_error_log
    ==> error_log <==
    [Thu Dec 02 10:03:08 2010] [notice] Digest: done
    [Thu Dec 02 10:03:09 2010] [notice] mod_python: Creating 4 session mutexes based on 150 max processes and 0 max threads.
    [Thu Dec 02 10:03:09 2010] [notice] Apache/2.2.3 (CentOS) configured -- resuming normal operations
    [Thu Dec 02 10:14:52 2010] [notice] caught SIGTERM, shutting down
    [Thu Dec 02 10:15:03 2010] [notice] core dump file size limit raised to 4294967295 bytes
    [Thu Dec 02 10:15:03 2010] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
    [Thu Dec 02 10:15:04 2010] [notice] Digest: generating secret for digest authentication ...
    [Thu Dec 02 10:15:04 2010] [notice] Digest: done
    [Thu Dec 02 10:15:04 2010] [notice] mod_python: Creating 4 session mutexes based on 150 max processes and 0 max threads.
    [Thu Dec 02 10:15:05 2010] [notice] Apache/2.2.3 (CentOS) configured -- resuming normal operations

    ==> ssl_error_log <==
    [Mon Nov 29 17:47:06 2010] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
    [Mon Nov 29 17:47:06 2010] [warn] RSA server certificate CommonName (CN) `localhost.localdomain' does NOT match server name!?
    [Thu Dec 02 10:03:08 2010] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
    [Thu Dec 02 10:03:08 2010] [warn] RSA server certificate CommonName (CN) `localhost.localdomain' does NOT match server name!?
    [Thu Dec 02 10:03:09 2010] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
    [Thu Dec 02 10:03:09 2010] [warn] RSA server certificate CommonName (CN) `localhost.localdomain' does NOT match server name!?
    [Thu Dec 02 10:15:03 2010] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
    [Thu Dec 02 10:15:03 2010] [warn] RSA server certificate CommonName (CN) `localhost.localdomain' does NOT match server name!?
    [Thu Dec 02 10:15:05 2010] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)
    [Thu Dec 02 10:15:05 2010] [warn] RSA server certificate CommonName (CN) `localhost.localdomain' does NOT match server name!?
     
  19. falko

    falko Super Moderator Howtoforge Staff

    What's the output of
    Code:
    httpd -t
    ?
     
  20. wachira

    wachira New Member

    [root@server1 httpd]# httpd -t
    Syntax OK
     

Share This Page