C5 Disk space usage
PermalinkBefore cleaning
296504kb total
After deleting all most most recent update
255948kb total
/files/tmp contained 156.2MB of cruft, tossed all of it
After emptying files/cache
86888 total
Difference = 296504kb - 86888kb = 209.6MB
I get the /updates directory, you may want to rollback although C5 should have the ability to delete old updates from the dash if your site's working fine.
What's the deal with the /files/tmp directory, why doesn't it get cleaned?
/files/cache is self-evident anyway and by comparison not so big.
Amazon AWS will charge me for all the bandwidth I use over a certain amount and chucking 200MB around for a small website that I don't need to after having BZipped all that up for backup is comical. Never mind for the other ten sites which I assume are just as bloated. It's costing people money - I doubt I'm alone in using hosting with bandwidth charges (AWS is good value though, I must say).
There's still a now-redundant 33MB /concrete directory too, as the /updates/xxxxx version is used instead.
Don't misconstrue me as hating C5, it's great, but this... THIS... is a real faux-pas.
Off to check the other sites now and more than likely write a cruft script for cron which I really shouldn't have to be doing.
is and what other stuff runs on there? I know why I chose this method over
rsync, AWS backup and various other methods.
What about the files/tmp/ disk space not being cleaned, presumably growing
forever?
G
On 7 June 2012 15:43, concrete5 Community <discussions@concretecms.com>wrote:
growing and growing forever then it's a flaw without some explanation of
why it's right for it to do it.
G
On 7 June 2012 18:18, concrete5 Community <discussions@concretecms.com>wrote:
<?php $wwwbase = '/www'; // get www dir list $list = `ls $wwwbase`; $list = explode("\n", $list); foreach($list as $item) { $item = trim($item); if(empty($item)) { continue; } if(is_dir("$wwwbase/$item/files/tmp")) { `rm -rf $wwwbase/$item/files/tmp/*`; echo "Cleanup.php: Removed contents of $wwwbase/$item/files/tmp/\n"; } }
Which is run before backups with a crontab line such as:
0 0 * * * /usr/bin/php /root/cleanup.php
On a typical site all you have to backup is anything in the root override folders, the /config folder and then stuff in the files folder(not the cache and tmp obviously), and the sql backup. It's typically 60MB at the most for me.
And you should be rsyncing anyway for incrementals which typically never even does anything but a few files and the sql backup which usually comes in around 6MB for me.
This really isn't a good way to back up your clients websites and is definitely wasting money.