LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
Search this Thread
Old 07-20-2011, 09:12 AM   #1
rmvilhena
LQ Newbie
 
Registered: May 2011
Posts: 3

Rep: Reputation: 0
Import/export filesystem quotas


Hello.

I wanted to know if it's posible to import filesystem quotas. And if so, how can I do it?

I recently migrated a server, and presently the users don't have any quota limitations.

Thanks.

Regards,
Vilhena
 
Old 07-20-2011, 04:26 PM   #2
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, Ubuntu, SLES, CentOS
Posts: 1,790

Rep: Reputation: 324Reputation: 324Reputation: 324Reputation: 324
@ Reply

Hi there,

I have never tried that before but I think the following steps might work:

1. Run quotacheck on the mounted partition. Suppose mounted partition is /opt/data then run: quotacheck -cvug /opt/data (This will create usr.quota and grp.quota files on that partition.

2. Make sure that you enable usrquota and grpquota option in /etc/fstab to reflect that.

3. If you have a backup of user and group quota files from old server then copy it over to /opt/data. This will replace the quota files there and I think it should take the values from old files which you have just placed in the mount point.
 
Old 07-20-2011, 07:45 PM   #3
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.5, Centos 5.10
Posts: 16,287

Rep: Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034Reputation: 2034
According to this http://linux.die.net/man/8/repquota repquota can report quotas set, which may be safer than copying over old files & certainly useful for comparing old vs new.

Note filenames
Quote:
aquota.user or aquota.group

quota file at the filesystem root (version 2 quota, non-XFS filesystems)

quota.user or quota.group

quota file at the filesystem root (version 1 quota, non-XFS filesystems)
 
Old 07-25-2011, 05:05 AM   #4
rmvilhena
LQ Newbie
 
Registered: May 2011
Posts: 3

Original Poster
Rep: Reputation: 0
Thank you all for your replys.

I haven't tried your solutions because I have to bounce the server in order to activate the quota filesystems.
But tomorrow morning I'll do the reboot and i'll try what you've said.

Once again, thanks a lot!

Regards,
Vilhena
 
  


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
How to import and export database umwai Linux - Newbie 1 03-06-2009 02:00 AM
import and export command mrbutabara Linux - Newbie 1 02-17-2009 09:21 AM
how to export/import users/passwords ? dlugasx Linux - Server 3 02-02-2009 06:33 AM
Export-Import with pipe files asi Linux - Software 2 06-05-2007 11:25 AM
Accessing import and export symbols ? unclesam Linux - Newbie 2 01-11-2006 08:14 AM


All times are GMT -5. The time now is 06:29 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