Website is down. Private hosting. What should I do?

In this example we were checking Python website on a private hosting Godaddy. But the recommendations about your hosting stats are applicable for any types of websites.

My first step

Check all the websites that are hosted on this hosting and check are they online or not?
If all of them are not online, than it is a problem with a server completely. If just one website is not working, most likely it means that you made a mistake with your last website update.

Mistake with website update

Check were you have a project for your website. Many developers use bitbucket for their website development. If it is the case, check your last changes or changes of your developer. If necessary, come back to your last version of update.

Problem with your server

Go on your server provider account. I will give you an example based on Godaddy hosting provider. But obviously the same actions can be taken on any other server. Check your account.

The very first step is to try to switch off and switch on the server. Click on “Power” button. Sometimes it can work right away.

What the stats can tell you?

Open the following window and check the parameters of Stats & Usage. I describe only the most common situations.

1. High CPU usage

If your CPU has jumped in 1 day, you might have hacked hosting. Please, contact your hosting provider immediately.

2. Disk Space Usage is full

This number can jump fast, in this case you probably had a hack attack on your site. Or if it is steadily growth, most likely you have some back-up of your website, emails, pictures. How to check it, I will tell you later in this article.

3. SMTP Relay Usage is full

If SMTP Relay Usage is full, most likely you had a DOC attack (SMTP relay attack). How to delete spam from mail folder on server check further.

Python website does not work, steps to recover your website.

Now when we studied the statistics of our server, we have a bit of understanding if it is the whole server that is down or a single website. And where to search for a problem. Now connect to your website via SSH and do the following steps:

1. Check server status
Use one of those commands:

It should write “success”

Or use this one

It should write “is running”

2. Check inodes usage

Check inodes usage
Check inodes usage

You should have some extra inodes in the column IFree or IUse shold be less than 100%

3. Check in which folder you have big files

This command will show you in which folder you have some big files. After you have to go and check this folder.

4. Spam in mails. Delete spam from mail folder

My website is on Django Python, so here is a command  to delete files by keywords. You can use it through SSH.

Explanation

“Credit” is your keyword. You can insert different ones that spammers would probably use in your emails. Try “credit”, “loans” and etc.

Files that were created in the last 2 day. You can put more instead of +1, for more days

5. Big number of back-ups

Connect through FTP to your website, find folder data/mysql-backup and delete files types:
my-domain-name_2020-02-12.sql.gz
my-domain-name2_2020-02-12.sql.gz
Don’t delete all of them, keep for the last couple of days in case.

Still need a help with your website? Please, contact us for a help.

Leave a Reply

Your email address will not be published. Required fields are marked *