ispCP - Board - Support
User limit & Quota - Printable Version

+- ispCP - Board - Support (http://www.isp-control.net/forum)
+-- Forum: ispCP Omega Support Area (/forum-30.html)
+--- Forum: Usage (/forum-34.html)
+--- Thread: User limit & Quota (/thread-5812.html)



User limit & Quota - tango - 02-25-2009 06:59 AM

One question, If I create a user (vu2001) and his example 500MB memory allocation, it shall be quota vu2001 not displayed the limit.

Is it installed or not I made a mistake?

Sorry my English is Bad, it was from German to English with google translator translates


RE: User limit & Quota - RatS - 02-25-2009 04:44 PM

We are using a soft quota stored in our database, that's the reason why there is no hard quota shown for the user.

To explain why it is handled like this: I assume - because this is an VHCS relict - that the changes in the boot manager necessary for the use of quota and the unavailability of quota in former linux kernels have been the main reasons for using soft quota.


RE: User limit & Quota - tango - 02-25-2009 07:23 PM

we would do in the future hard quotas change ?


RE: User limit & Quota - RatS - 02-25-2009 09:53 PM

maybe Big Grin


RE: User limit & Quota - cyber2 - 08-02-2009 07:53 PM

Do you made a hard quotas change?
if not - there is my dirty & simple script for set hard quotas

PHP Code:
#!/usr/bin/perl

#  Hard quota installer  for CentOs VPS v0.1                 
#  dirty & simple script created by 2lexx@mail.ru 02.08.2009 
#  to check quota  just type in console: repquota -a         


use DBI;

my $host "localhost";
my $port "3306";
my $user "root";
my $pass "PASSWORD_FOR_MYSQL_ROOT";
my $db "ispcp";


$dbh DBI->connect("DBI:mysql:$db:$host:$port",$user,$pass);
$sth $dbh->prepare("select domain_name,domain_uid,domain_disk_limit*1e3 from domain");
$sth->execute;

while (
$ref $sth->fetchrow_arrayref) {
`
/usr/sbin/setquota -u vu$$ref[1] 0 $$ref[2] 0 0 /`;
print 
"Hard quota for user vu$$ref[1],domain $$ref[0] is set to $$ref[2] 1k blocks\n";
}

$rc $sth->finish;
$rc $dbh->disconnect

I have been crontabbed it and it works ok Wink
Any suggesions?

Sorry my English is Bad, my native language is perl Wink


RE: User limit & Quota - MasterTH - 08-03-2009 03:37 AM

hard quotas are good but not for all users.
vserver often don't have the option to set hard quotas because they use the kernel of the host and theres nothing enabled with quotas.
soft-quotas are not as bad as it looks. i prefer them.


RE: User limit & Quota - kilburn - 08-04-2009 06:52 AM

MasterTH Wrote:soft-quotas are not as bad as it looks. i prefer them.

Me too. My customers would get really angry if their website stops working because it can't create any temporary files anymore due to a hard quota. We know it's his fault, but he won't ever agree...


RE: User limit & Quota - WuChEn - 11-25-2009 06:05 AM

What does it do? Oo
Set quota vor any dir? Oo

Gratz WuChEn