edit users quota in a script

2009-02-07 Thread Nicolas Letellier
Hello.

I use a script to create automatically my users (with pw, and mkdir, etc...). I 
use quota, and I have to excute 'edquota -u user', and enter quota 
informations. So, the process can not be automaticated. And cannot be part of 
my script.

I don't find informations in edquota(8) manpages about editing user quota 
without open a file.

Is an other solution exists? I'm looking for a solution in command line (for my 
script).

Regards,

-- 
 -Nicolas.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: edit users quota in a script

2009-02-07 Thread Manolis Kiagias

Nicolas Letellier wrote:

Hello.

I use a script to create automatically my users (with pw, and mkdir, etc...). I 
use quota, and I have to excute 'edquota -u user', and enter quota 
informations. So, the process can not be automaticated. And cannot be part of 
my script.

I don't find informations in edquota(8) manpages about editing user quota 
without open a file.

Is an other solution exists? I'm looking for a solution in command line (for my 
script).

Regards,

  
The edquota(8) command accepts a '-e' option that allows it to set 
quotas non-interactively. Try man edquota again.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: edit users quota in a script

2009-02-07 Thread Nicolas Letellier
On Sat, 07 Feb 2009 14:09:13 +0200
Manolis Kiagias sonic200...@gmail.com wrote:

 Nicolas Letellier wrote:
  Hello.
 
  I use a script to create automatically my users (with pw, and mkdir, 
  etc...). I use quota, and I have to excute 'edquota -u user', and enter 
  quota informations. So, the process can not be automaticated. And cannot be 
  part of my script.
 
  I don't find informations in edquota(8) manpages about editing user quota 
  without open a file.
 
  Is an other solution exists? I'm looking for a solution in command line 
  (for my script).
 
  Regards,
 

 The edquota(8) command accepts a '-e' option that allows it to set 
 quotas non-interactively. Try man edquota again.

Haaa... yes, I forgot -e option. Thanks a lot!

Regards,

-- 
 -Nicolas.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org


Re: edit users quota in a script

2009-02-07 Thread Stephen Corbesero

Besides the -e switch to edquota as has already been mentioned, I used
to make extensive use of the -p switch to use a prototype.  

For example, you could create a fake user (or group) named
q-typical, assign that user the quotas for a typical user, and then
use

 edquota -p q-typical newuser

to assign those quotas to the new user.  You could maintain several
prototypes for different classes of users or groups.



On Sat, Feb 07, 2009 at 01:00:25PM +0100, Nicolas Letellier wrote:

 Hello.

 I use a script to create automatically my users (with pw, and mkdir,
 etc...). I use quota, and I have to excute 'edquota -u user', and
 enter quota informations. So, the process can not be
 automaticated. And cannot be part of my script.  I don't find
 informations in edquota(8) manpages about editing user quota without
 open a file.

 Is an other solution exists? I'm looking for a solution in command
 line (for my script).


-- 
Stephen CorbeseroIt's always darkest 
Bethlehem, PA 18015  before pitch black.
corbes...@ptd.net
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to freebsd-questions-unsubscr...@freebsd.org