[SOLUTION] Clean Full Disk space by /dev/vda1

How to empty sda1,vda1 on VPS

Sometimes your OS (Ubuntu, Linux, etc…) disk space might become full, by /dev/vda1/, /dev/vda2/, /dev/vda3/ or etc… (To check that, just navigate to root directory by using command: cd .. and then use df -h to see the disk usage) . 

Jenkins or Docker (or other) might be the issue

Many times, that problem might be coming from Jenkins / Docker. If you use Jenkins, then I suggest that you making the logs smaller. For that, in /etc/logrotate.d/jenkins you might use:

/var/log/jenkins/jenkins.log {
daily
copytruncate
missingok
rotate 2
size 1M
nocompress
notifempty
maxage 30
}

Still full disk?

Even after you made the above suggestion and disk space is still full, then maybe you have deleted a large file already, while that file was being stillused by some process? To find out what might be using that space, one solution is to use the command lsof / | grep deleted and there will show up the processes that might be taking the space. You have to restart those services. Just use:

sudo systemctl restart processName

and then check again with df -h  and you will see the space is now free!

 

DigitalOcean VPS

Do you want a reliable VPS server starting from $5/month? You can try DigitalOcean with free trial.

 

Leave a Comment

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

Puvox - Blog
Scroll to Top