Folder size restriction

Chavo

New member
Joined
Jun 21, 2006
Messages
2
Hi all,

Does anyone know whether it's possible to restrict the size of a specific folder? I have set up a ftp folder for my clients, but to prevent a hacker or anyone else from completely stuffing my server with junk I would like to restrict the size of the (semi-public) ftp folder to, say, 50 MB.

If that's possible, can I get (e-mail) notification when the folder is almost full?

Thanks in advance for any help!


Chavo
 
Hello,

There is nothing in DA that would restrict a folder's size.

proftpd *may* have a quota option which you could look into adding.. Im not too sure though.

Past that, create a cron script that checks the size and emails you if it's over.

John
 
John and Chavo bring back memories... it was 1995, and I was building our first webhosting server (on an old Slackware distribution, linux kernel version 0.99).

And I was asking the same question.

Someone explained to me that I'd be better off letting people use as much space as they wanted, and billing for it :) .

And that was back when a large drive was 1 gigabyte.

I took the advice and I've never looked back :) .

Jeff
 
Sorry for not replying earlier... it's a hectic period and I seem to have no time for other matters than the strictly necessary. :(

@jlasman: I am not going to let my clients pay for the space... It is me who is offering the service: I want them to put it there for my convenience.:D

@DirectAdmin Support: I'ts a pity there isn't. would have been nice. The alternatives you suggest are way above my ability.:confused: I'm just a simple unknowing irrelevant little end-user :rolleyes:.

If anyone manages to find a way to achieve this, I would me more than grateful. Otherwise, I'll just leave it unristricted and check manually.

Thanks for your advice!

Chavo
 
In a cronjob:

du -sh /path/to/folder > check.out ; mail [email protected] <check.out

may work. The /path/to/folder needs to be readable by the user running the cronjob.

Jeff
 
Back
Top