core.#### files eating tons of disk

Hey guys,

I’ve been noticing a ton of files named core.[number] in the directory “/usr/libexec/webmin/virtual-server” and I’m wondering if this is normal.

I’ve been having trouble keeping my server’s disk usage under control, and I tracked down a few problem areas with the shell command “du”.

The virtualmin directory “/usr/libexec/webmin/virtual-server” has pages and pages of files that start with “core.” (such as core.1123, core.2273, etc). Their dates vary from around today to about 2 months ago, and they are using over 16 gigabytes on my system.

I only run a handful of virtual servers, didn’t modify the vanilla virtualmin install to much aside from a cronjob per virtual server and some scheduled backups.

Is this normal behavior, or is there some way I can reduce the disk space usage somehow? Disk space on my host isn’t cheap! lol

“core” files are usually created when a process crashes. For one you can clean up those files, you probably don’t need them. To find out what crashed and why, take a look at the syslog in /var/log. Oftentimes it’s due to memory or resource issues.

Are you running on an OpenVZ based VPS? See if you have the file /proc/user_beancounters, and if so, post its contents here (inside [code][/code] tags to preserve line breaks).

Hey dude! Aren’t you the same person who helped me with an issue sometime ago? So cool… thank you twice.

Anyway, I’m on OpenVZ but I didn’t have a /proc/user_beancounters folder. However I was able to delete all the core.#### files and recover TWENTY GIGABYTES for my vps, lol.

Is there some way to auto purge these core files after a certain date, or should I just write up a quick script?


Well, it’s pretty unusual for those to appear, and there isn’t really an automated way to remove them… you could always try writing a script to do that though, and adding that script to cron.

However, it’s possible that means you’re running into resource problems though, and that you may want to talk to your provider about how to see what limits are being reached. Normally, the /proc/user_beancounters file does that, but if that doesn’t exist, they may be able to point you in the right direction.


Thanks man. I have an idea of what may have happened. I ran a ‘yum’ update that caused my VPS to have network or somesuch drivers that weren’t compatible with their virtualization panel or something, and I must have manually restarted the VPS 10’s of times before having them go into the machine. I started running into disk space issues right after that.

I’ll keep a general watch on the system though. I’m sure there are several other places I’m probably screwing up too.