Forums

dmb
dmb
Offline
Resolved
0 votes
Hi all,

My websites are down and I can't figure out why. Everything was working with my old Internet connection last time I checked. The (new) Internet connection works fine; I can browse the web and even access the websites from the LAN but not externally. Externally it just appears like the web page is taking a long time to load but after a while it fails.Bandwidth is not the issue. I have tried yum upgrade and I have tried restarting the server and I have tried deleting the firewall rule allowing HTTP connections and setting it up again. I am using dyn,com for dynamic DNS so I thought that might be the problem but when I check the logs on dyn.com it says all is fine.

Any ideas on how to solve this?

Thanks.
Monday, May 28 2018, 11:12 PM
Share this post:
Responses (9)
  • Accepted Answer

    Friday, August 03 2018, 07:50 AM - #Permalink
    Resolved
    0 votes
    You can only select the folder layout on website creation. To change it you have to delete the website in the webconfig and recreate it. This is because your website will completely break if you change from one layout to another when the original site was working.

    Anyway, for the sandboxed layout (which is the recommended one), your website should go into /var/www/virtual/<website>/html - see the DocumentRoot parameter in flex-80.conf (and also the documentation). With the Standard layout, /var/www/virtual/<website> is used.

    I tried playing round with file ownership and it does not seem to matter. I thought the normal file ownership was apache:allusers and that there was a nightly cron job to change it, but I could be wrong.
    The reply is currently minimized Show
  • Accepted Answer

    dmb
    dmb
    Offline
    Friday, August 03 2018, 01:22 AM - #Permalink
    Resolved
    0 votes
    Thanks for the reply. I am using the ClearOS Web Site set up from the webconfig. The default site works fine but not the other (dynamic DNS) ones. I am using Sanboxed Folder Layout. It won't let me change the folder layout. My index files are in the root directories of the website directories (/var/www/virtual/<website>/). Permissions for index.html files are -rwxrwxr--x <username> admin for one and -rw-rw-r-- <username> admin for the other two. I don't think I have a .htaccess file. I am certain I did not try to create one.

    #----------------------------------------------------------------
    # WARNING: This file is automatically created by webconfig.
    #----------------------------------------------------------------


    # Authentication mechanism
    DefineExternalAuth pwauth pipe /usr/bin/pwauth
    DefineExternalGroup pwauth pipe /usr/bin/unixgroup

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:80>
    ServerName <URLnameofdefaultsite>
    ServerAlias *.<URLnameofdefaultsite>
    DocumentRoot /var/www/html
    ErrorLog /var/log/httpd/error_log
    CustomLog /var/log/httpd/access_log combined
    </VirtualHost>

    <Directory /var/www/html>
    Options +Indexes +FollowSymLinks -IncludesNOExec
    AllowOverride All
    Require all granted
    <FilesMatch \.php$>
    SetHandler None
    ForceType text/plain
    SetHandler application/x-httpd-php-source
    </FilesMatch>
    </Directory>

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:80>
    ServerName <URLnameofvirtualsite1>
    ServerAlias*. <URLnameofvirtualsite1>
    DocumentRoot /var/www/virtual/<URLnameofvirtualsite1>/html
    ErrorLog /var/www/virtual/<URLnameofvirtualsite1>/logs/<URLnameofvirtualsite1>_error_log
    CustomLog /var/www/virtual/<URLnameofvirtualsite1>/logs/<URLnameofvirtualsite1>_access_log combined
    </VirtualHost>

    <Directory /var/www/virtual/<URLnameofvirtualsite1>>
    Options -Indexes +FollowSymLinks -IncludesNOExec
    AllowOverride All
    Require all granted
    <FilesMatch \.php$>
    SetHandler None
    ForceType text/plain
    SetHandler application/x-httpd-php-source
    </FilesMatch>
    </Directory>

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:80>
    ServerName <URLnameofvirtualsite2>
    ServerAlias *.<URLnameofvirtualsite2>
    DocumentRoot /var/www/virtual/<URLnameofvirtualsite2>/html
    ErrorLog /var/www/virtual/<URLnameofvirtualsite2>/logs/<URLnameofvirtualsite2>_error_log
    CustomLog /var/www/virtual/<URLnameofvirtualsite2>/logs/<URLnameofvirtualsite2>_access_log combined
    </VirtualHost>

    <Directory /var/www/virtual/<URLnameofvirtualsite2>>
    Options +Indexes +FollowSymLinks -IncludesNOExec
    AllowOverride All
    Require all granted
    <FilesMatch \.php$>
    SetHandler None
    ForceType text/plain
    SetHandler application/x-httpd-php-source
    </FilesMatch>
    </Directory>

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:80>
    ServerName <URLnameofvirtualsite3>
    ServerAlias *.<URLnameofvirtualsite3>
    DocumentRoot /var/www/virtual/<URLnameofvirtualsite3>/html
    ErrorLog /var/www/virtual/<URLnameofvirtualsite3>/logs/9-11.dnsalias.net_error_log
    CustomLog /var/www/virtual/<URLnameofvirtualsite3>/logs/9-11.dnsalias.net_access_log combined
    </VirtualHost>

    <Directory /var/www/virtual/<URLnameofvirtualsite3>>
    Options -Indexes -FollowSymLinks -IncludesNOExec
    AllowOverride All
    Require all granted
    <FilesMatch \.php$>
    SetHandler None
    ForceType text/plain
    SetHandler application/x-httpd-php-source
    </FilesMatch>
    </Directory>



    #----------------------------------------------------------------
    # WARNING: This file is automatically created by webconfig.
    #----------------------------------------------------------------


    # Authentication mechanism
    DefineExternalAuth pwauth pipe /usr/bin/pwauth
    DefineExternalGroup pwauth pipe /usr/bin/unixgroup

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:443>
    ServerName <URLnameofdefaultsite>
    ServerAlias *.<URLnameofdefaultsite>
    DocumentRoot /var/www/html
    ErrorLog /var/log/httpd/error_log
    CustomLog /var/log/httpd/access_log combined
    SSLEngine on
    SSLCertificateFile /etc/pki/CA/sys-0-cert.pem
    SSLCertificateKeyFile /etc/pki/CA/private/sys-0-key.pem
    SSLCACertificateFile /etc/pki/CA/ca-cert.pem
    # No weak export crypto allowed
    SSLHonorCipherOrder on
    SSLProtocol all -SSLv2 -SSLv3 -TLSv1
    SSLCipherSuite ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!3DES:!aNULL:!MD5
    SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0
    </VirtualHost>

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:443>
    ServerName <URLnameofvirtualsite1>
    ServerAlias *.<URLnameofvirtualsite1>
    DocumentRoot /var/www/virtual/<URLnameofvirtualsite1>/html
    ErrorLog /var/www/virtual/<URLnameofvirtualsite1>/logs/<URLnameofvirtualsite1>_error_log
    CustomLog /var/www/virtual/<URLnameofvirtualsite1>/logs/<URLnameofvirtualsite1>_access_log combined
    SSLEngine on
    SSLCertificateFile /etc/pki/CA/sys-0-cert.pem
    SSLCertificateKeyFile /etc/pki/CA/private/sys-0-key.pem
    SSLCACertificateFile /etc/pki/CA/ca-cert.pem
    # No weak export crypto allowed
    SSLHonorCipherOrder on
    SSLProtocol all -SSLv2 -SSLv3 -TLSv1
    SSLCipherSuite ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!3DES:!aNULL:!MD5
    SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0
    </VirtualHost>

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:443>
    ServerName <URLnameofvirtualsite2>
    ServerAlias *.<URLnameofvirtualsite2>
    DocumentRoot /var/www/virtual/URLnameofvirtualsite2>/html
    ErrorLog /var/www/virtual/<URLnameofvirtualsite2>/logs/<URLnameofvirtualsite2>_error_log
    CustomLog /var/www/virtual/<URLnameofvirtualsite2>/logs/<URLnameofvirtualsite2>_access_log combined
    SSLEngine on
    SSLCertificateFile /etc/pki/CA/sys-0-cert.pem
    SSLCertificateKeyFile /etc/pki/CA/private/sys-0-key.pem
    SSLCACertificateFile /etc/pki/CA/ca-cert.pem
    # No weak export crypto allowed
    SSLHonorCipherOrder on
    SSLProtocol all -SSLv2 -SSLv3 -TLSv1
    SSLCipherSuite ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!3DES:!aNULL:!MD5
    SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0
    </VirtualHost>

    # -----------------------------------------------#
    # Web Site
    # -----------------------------------------------#

    <VirtualHost *:443>
    ServerName <URLnameofvirtualsite3>
    ServerAlias *.<URLnameofvirtualsite3>
    DocumentRoot /var/www/virtual/<URLnameofvirtualsite3>/html
    ErrorLog /var/www/virtual/<URLnameofvirtualsite3>/logs/<URLnameofvirtualsite3>_error_log
    CustomLog /var/www/virtual/<URLnameofvirtualsite3>/logs/<URLnameofvirtualsite3>_access_log combined
    SSLEngine on
    SSLCertificateFile /etc/pki/CA/sys-0-cert.pem
    SSLCertificateKeyFile /etc/pki/CA/private/sys-0-key.pem
    SSLCACertificateFile /etc/pki/CA/ca-cert.pem
    # No weak export crypto allowed
    SSLHonorCipherOrder on
    SSLProtocol all -SSLv2 -SSLv3 -TLSv1
    SSLCipherSuite ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+3DES:!3DES:!aNULL:!MD5
    SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown downgrade-1.0 force-response-1.0
    The reply is currently minimized Show
  • Accepted Answer

    Sunday, July 29 2018, 07:59 AM - #Permalink
    Resolved
    0 votes
    Are you using the ClearOS Web Site set up from the webconfig? If so:
    Are you loading to the default site or a subdomain?
    Are you using the Sandboxed or Standard Folder Layout?
    Where is your index file?
    What are its permissions and ownership?
    Can you post the contents of /etc/httpd/conf.d/flex-80.conf and /etc/httpd/conf.d/flex-443.conf?

    [edit]
    Do you have a .htaccess file, and, if so, what is its contents?

    If you don't use the ClearOS Web Site set, what is in your web sites .conf file in /etc/httpd/conf.d?
    [/edit]
    The reply is currently minimized Show
  • Accepted Answer

    dmb
    dmb
    Offline
    Saturday, July 28 2018, 11:01 PM - #Permalink
    Resolved
    0 votes
    Thanks for the reply. When I do that a "403 Forbindden" error message:

    "Forbidden
    You don't have permission to access / on this server."

    Any ideas?
    The reply is currently minimized Show
  • Accepted Answer

    Thursday, July 26 2018, 11:37 AM - #Permalink
    Resolved
    0 votes
    Reading the docs, if you have an index page, you do not want Show Indexes enabled.
    The reply is currently minimized Show
  • Accepted Answer

    dmb
    dmb
    Offline
    Thursday, July 26 2018, 10:27 AM - #Permalink
    Resolved
    0 votes
    Thanks for the reply. I had already set "Show Index" and I had already looked at the documentation.
    The reply is currently minimized Show
  • Accepted Answer

    Saturday, June 30 2018, 12:48 PM - #Permalink
    Resolved
    0 votes
    Assuming you are using the ClearOS Website config, how have you set "Show Index"? Have a look at the documentation attached to the page? Having said that, the option does nothing for me, but mine is a legacy set up.
    The reply is currently minimized Show
  • Accepted Answer

    dmb
    dmb
    Offline
    Saturday, June 30 2018, 09:47 AM - #Permalink
    Resolved
    0 votes
    Thanks for the reply. It turns out my ISP was blocking the ports so I changed that but now when I go to my websites it doesn’t load index.html even though it is there as I can see it in the shared directory on the LAN. What appears looks like a directory listing with no files listed with “Index of /“ as the heading. How can I fix this?
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, May 29 2018, 07:39 AM - #Permalink
    Resolved
    0 votes
    Do you have anything like IDS/IPS or app-attack-detector running? You can see any ipset blocks (attack-detector and IPS) with:
    for SET in `ipset list -name | egrep 'f2b|snort'` ; do ipset list $SET -output save | grep add | awk '{print $2 " "  $3}'; done


    Are you using the Web Server app? If so is Accessibility still "All"?

    Can you use a scanning site to see if port 80 (and possible 443) are open to the internet? You could use the Shields Up test at grc.com (but if you read the content be wary of the scaremongering)?

    If you've changed any external router, have you set up any port forwarding and made sure its management ports are not listening on ports 80 and 443?

    When you checked your dyn.com logs and said all is fine, do you mean that your dyn.com name resolves to your current WAN IP?
    The reply is currently minimized Show
Your Reply