Website down after resize

June 10, 2017 114 views
Apache MySQL PHP CentOS

My website stops working when I resized my droplets? I already tried to remove/disable the domain but I still can't access the IP.

Although I can access the IP via putty.

1 Answer

Hi @conxbjordan

Did you resize up or down? Can you have a look in the Apache error log:

sudo tail -30 /var/log/apache/error.log

If you run the following command, does it list your IP - if yes, then your domain is working - it's probably just Apache that isn't running:

dig YourDomain.com A
  • Hi @hansen Thanks for replying.

    I resize up my droplets.

    I tried sudo tail -30 /var/log/apache/error.log but no such file or directory.

    Tried the dig. It does show my IP. I already did apachectl restart it seems apache is running.

    I've seen the error logs here it is:

    [Sun Jun 11 07:05:43.465301 2017] [mpm_prefork:notice] [pid 17760] AH00170: caught SIGWINCH, shutting down gracefully
    [Sun Jun 11 07:05:44.630280 2017] [suexec:notice] [pid 17798] AH01232: suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
    [Sun Jun 11 07:05:44.692633 2017] [auth_digest:notice] [pid 17798] AH01757: generating secret for digest authentication ...
    [Sun Jun 11 07:05:44.695016 2017] [lbmethod_heartbeat:notice] [pid 17798] AH02282: No slotmem from mod_heartmonitor
    [Sun Jun 11 07:05:44.836335 2017] [mpm_prefork:notice] [pid 17798] AH00163: Apache/2.4.6 (CentOS) PHP/5.4.16 configured -- resuming normal operations
    [Sun Jun 11 07:05:44.836439 2017] [core:notice] [pid 17798] AH00094: Command line: '/usr/sbin/httpd -D FOREGROUND'
    
    • @conxbjordan

      Hmmm. Can you go and look in your Apache configuration. You've probably changed the default error log location. Have a look in /etc/apache2/sites-enabled/ or /etc/apache2/httpd.conf.

      On Ubuntu there's a really simple command that lists all services listening on the interfaces, but I don't know the similar command for CentOS:

      sudo lsof -iTCP -sTCP:LISTEN -P
      

      The only command I know, requires that you specify the port number:

      sudo fuser -v -n tcp 80
      

      This should output something about Apache. But you can also just run the

      sudo apachectl status
      

      By default CentOS comes with the firewall enabled - could that be the reason why you're not getting thru to Apache?

      sudo iptables -L
      
Have another answer? Share your knowledge.