Editing
XFS
From Linix VServer
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
So, you use the lovely XFS file system, but those meanies at linux-vserver have told you it's not supported. :) No problems. To get the same sort of effect as dlimits, while using the XFS file system, you can use Project Quotas. Let's say we want to limit /vserver/foo to 5G of space. Edit /etc/fstab, and put prjquota as an option for /vserver, and reboot. (I don't think -o remount works). It should look like this: <pre># grep prjquota /etc/fstab /dev/cciss/c0d0p7 /vserver xfs noatime,prjquota 0 0 </pre> Warning: XFS: cannot mount with both project and group quota <pre>echo "1235:/vservers/foo" >> /etc/projects</pre>(I use the context for the project ID number) <pre>echo "foo:1235" >> /etc/projid</pre>(This is just so you can refer to a project by name) Now we just set up the quota.... <pre>xfs_quota -x -c 'project -s foo' /vserver</pre> And set our limits on it. (bhard = blocks hard, bsoft = blocks soft) <pre>xfs_quota -x -c 'limit -p bsoft=4800M bhard=5G foo' /vserver</pre> Voila. Vservers with XFS. You can check the usage, etc with: <pre># xfs_quota -x -c 'report' /vserver Project quota on /vserver (/dev/cciss/c0d0p7) Blocks Project ID Used Soft Hard Warn/Grace ---------- -------------------------------------------------- foo 10002856 4915200 5242880 00 [--none--] .... </pre> It does work, but df -h doesn't show the limit properly in the vserver. It does show the size, and the used, but the avail it still takes from the <pre># df -h Filesystem Size Used Avail Use% Mounted on /dev/hdv1 5.0G 3.0G 17G 21% / </pre> [[Category:Documentation]]
Summary:
Please note that all contributions to Linix VServer may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Linix VServer:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Page actions
Page
Discussion
Read
Edit
History
Page actions
Page
Discussion
More
Tools
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
About
Overview
Paper
News
Developers
Donations
Search
Getting Started
Downloads
FAQs
Documentation
Support
Participate
How to participate
Report a Bug
Communicate
Teams/Projects
Hall of Fame
Resources
Archives
Recent Wiki Changes
Pastebin
Related Projects
VServer Hosting
Happy VServer Users
Tools
What links here
Related changes
Special pages
Page information