LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 04-22-2009, 11:52 AM   #1
jax8
Member
 
Registered: Feb 2004
Location: Australia
Distribution: Ubuntu, Fedora 10
Posts: 632

Rep: Reputation: 31
Assigning quotas in bash script


I want to assign quotas to users through a bash script. The problem is that edquota loads an interactive vi session. This is no good for my bash script as I want to do everything automatically.

Any ideas??
 
Old 04-22-2009, 02:03 PM   #2
colucix
Moderator
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,503

Rep: Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957Reputation: 1957
Use the setquota command: you can specify hard and soft limits on the command line. Use -u username to set the quota for a specific user.
 
Old 04-23-2009, 03:30 AM   #3
jax8
Member
 
Registered: Feb 2004
Location: Australia
Distribution: Ubuntu, Fedora 10
Posts: 632

Original Poster
Rep: Reputation: 31
perfect, thanks
 
Old 04-23-2009, 06:13 AM   #4
jisjis
LQ Newbie
 
Registered: Apr 2009
Posts: 18

Rep: Reputation: 0
Quote:
Originally Posted by jax8 View Post
I want to assign quotas to users through a bash script. The problem is that edquota loads an interactive vi session. This is no good for my bash script as I want to do everything automatically.

Any ideas??

SETQUOTA - Is your friend !

Linux

Last edited by jisjis; 04-26-2009 at 04:42 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Bash script for mail quotas Golgo13 Linux - Server 5 11-02-2008 04:07 AM
help with a little perl script and assigning variables sal_paradise42 Programming 8 10-15-2008 12:44 PM
Strange if statement behaviour when using bash/bash script freeindy Programming 7 08-04-2008 06:00 AM
assigning quotas for /home mounted using NFS shishirkotkar Linux - Software 1 05-01-2008 04:24 AM
Setting disk quotas in a script JohnE1 Linux - Enterprise 2 06-27-2007 05:05 PM


All times are GMT -5. The time now is 09:42 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration