By tclarencek
Hi. I have a VPS here. From time to time, all the websites hosted on the VPS don’t go through (“took too long to respond.”) by TIMEOUT. Then after some time it will again go through. but when i check the metrics, i don’t see any high utilization of CPU, Bandwidth or even disk I/O. what could possibly cause this temporal issue. But i can SSH into the server very well
Actually i host on an NGINX server that hosts subdomains on 2 domains. one runs on a docker container and i proxy it through the main NGINX while the other works directly under wordpress with the main NGINX server. I also have a phpmyadmin subdomain and all go down! I’m so confused
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Accepted Answer
SSH to the server
sudo apt(yum) install htop
then once installed just run
htop
This will show what processes are running and which are using more resources.
You would also tail logs.
cd /var/log
sudo tail -f syslog
sudo tail -f nginx/access.log
sudo tail -f php.XX.log
while tailing logs, browse your sites until you see traffic show in the logs, and experience the slow downs
Hi there @tclarencek,
As you are able to SSH to the Droplet, it sounds like your Nginx service is experiencing some issues.
What I could suggest here is, the next time you notice the problem, SSH to your Droplet and do the following:
- tail -100 /var/log/ngnix/error.log
You can also use this script here to summarize your access log.
- tail -100 /var/log/nginx/error.log
- sudo systemctl status docker
Feel free to share any of the logs here so I could try to further advise.
Regards, Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.