Solved

enabling quota problem.

Posted on 2004-03-21
10
690 Views
Last Modified: 2013-12-15

Hello,

I've a problem while trying to enable quotas using "quotaon -a".

The error message is every time:

quotaon: using //quota.user on /dev/hda3 [/]: Invalid argument

quotacheck is running without errors and is generating "aquota.user".

Is there any option/config possibility to say the server to generate quota.user and not aquota.user?

Or any idea what to do?

Thanks
j79
0
Comment
Question by:j79
  • 5
  • 5
10 Comments
 
LVL 17

Accepted Solution

by:
owensleftfoot earned 125 total points
Comment Utility
Edit the file /etc/fstab:

Add userquota after defaults, using lower case.


1.)  /dev/hda7   /home  ext2  defaults, userquota     1 2

Then create two files for the partions

2.) touch   /home/quota.user
3.) touch  /home/quota.group
4.) chmod 600 /home/quota.user
5.) chmod 600 /home/quota.group

You must reboot the system.

6.) edquota  –u  sam ( username )

Soft limit = Maximum amount of disk disk usage a quota user can have on
the system.

Hard limit =  A user cannot go beyond. If this limit is reached, the
user will not be able to use any additional space.
0
 
LVL 2

Author Comment

by:j79
Comment Utility
Done as you said, also done a checkquota after reboot.

# quotaon -a
quotaon: using /home/quota.group on /dev/hda3 [/home]: Invalid argument
quotaon: using /home/quota.user on /dev/hda3 [/home]: Invalid argument

It's creating aquota.user and aquota.group in the home directory and not quota.user and quota.group

j79



0
 
LVL 17

Expert Comment

by:owensleftfoot
Comment Utility
quota.user etc are from version 1 of quota. Version 2 uses aquota.user etc.
What does quotaon -v -a tell you?
0
 
LVL 2

Author Comment

by:j79
Comment Utility

Hello owensleftfoot,

quotaon -v -a
quotaon: using /home/quota.group on /dev/hda3 [/home]: Invalid argument
quotaon: using /home/quota.user on /dev/hda3 [/home]: Invalid argument

"quota -V" tells:
Quota utilities version 3.03.
Compiled with RPC and EXT2_DIRECT
Bugs to mvw@planets.elm.net, jack@suse.cz

I noticed that hda3 seems to use ext3 ? Does this matter anything?

0
 
LVL 17

Expert Comment

by:owensleftfoot
Comment Utility
Could you post your /etc/fstab?
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 
LVL 2

Author Comment

by:j79
Comment Utility

The original fstab is/was:

/dev/hda3       /               ext3    defaults,usrquota       1 1
/dev/hda1       /boot           ext3    defaults        1 2
/dev/hda2       swap            swap    pri=42          0 0
devpts          /dev/pts        devpts  mode=0620,gid=5 0 0
proc            /proc           proc    defaults        0 0

0
 
LVL 17

Expert Comment

by:owensleftfoot
Comment Utility
The example I gave you was for enabling quotas on a mounted /home partition. You need to create aquota.user in the / directory of your filesystem.
http://www.tldp.org/HOWTO/Quota.html will take you through things step by step.
0
 
LVL 2

Author Comment

by:j79
Comment Utility

thank you owensleftfoot, but it's not helping me.
aquota.user is being crated automatically after running a quotacheck, as I said above.
But if I try to start/enable quota it's not working because of expecting quota.user.
I also tried a link for quota.user to aquota.user, still without success.

j79
0
 
LVL 17

Expert Comment

by:owensleftfoot
Comment Utility
You can force quotaon to use either version 1 quota (quota.user) or version 2 (aquota.user) with the -F switch. To use quota.user files use quotaon -a -F vsfold
To use aquota.user use quotaon -a -F vsfv0
0
 
LVL 2

Author Comment

by:j79
Comment Utility


I did this 2-3 steps and it works now, don't ask me why.

rm aquota.user
touch quota.user
chmod 600 quota.user
quotacheck -uvma
quotaon -a

Anyway, thank you for the assistance owensleftfoot.

j79

 
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Introduction We as admins face situation where we need to redirect websites to another. This may be required as a part of an upgrade keeping the old URL but website should be served from new URL. This document would brief you on different ways ca…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now