University of California at Berkeley Department of Electrical Engineering & Computer Sciences (EECS) Instructional Support Group Sep 27, 2026 /share/b/pub/disk.quotas CONTENTS: * Disk Quotas for Instructional Accounts (UNIX & Windows) * Extra disk space if you need it (UNIX & Windows) * Can't Login? Symptoms of exeeding your quota (UNIX & Windows) * How to get logged to reduce your disk usage (UNIX & Windows) * How can I find what to delete? (UNIX & Windows) * WARNING! You can lose files (UNIX) * "Quota" vs "du" (UNIX) * Counting in "blocks" or "kilobytes"? (UNIX) * Using USB drives on our workstations * Why is disk space so limited? Disk Quotas for Instructional Accounts ------------------------------------------------------- Disk quotas are system-enforced limits placed on the amount of storage space allocated to individual users or groups. Because physical storage media and cloud resources carry finite capacities and ongoing financial costs, system administrators use quotas to prevent any single user from unintentionally or intentionally consuming all available space. Without these boundaries, a run-away process, massive log files, or unmanaged downloads could quickly exhaust the disk, causing shared services, system processes, and graphical desktop logins which frequently require temporary disk space to function to fail for everyone. By guaranteeing fair distribution and predictable system behavior, disk quotas maintain overall server stability, protect multi-user environments from service disruptions, and help organizations control infrastructure expenses. -> Linux: We offer an in house script labeled 'iquota' that can be found at /share/b/bin that culls quota information and displays it in a more human readable format. If instead you want the raw data you can use the command 'quota'. Please refer to the man page for quota, by typing 'man quota'. -> Windows: To find your Windows quota do the following. Right click your home directory and select "Properties". Quotas and Extra disk space if you need it ------------------------------------------ Each class-specific account has a 20GB disk usage limit. The data in your home directory is backed up daily and lasts as long as you have the account. You can also obtain temporary extra disk space (20GB). It is not backed up, and it is deleted after the end of the current semester. To create an extra directory for yourself, login to the WebAcct service at http://inst.eecs.berkeley.edu/webacct and click on the "Account Details" or "Make /home/tmp Directory" buttons. The directory is created in /home/tmp/$USER on the UNIX systems and is also accessible from your matching Windows account, if you were issued one, as \\napinst\tmp\$USER. It appears as your Windows P: drive. You may also want to create a sym link to your new /home/tmp directory on UNIX. Here is the UNIX command to create a link called 'tmp': ln -s /home/tmp/$USER tmp Can't Login? Symptoms of exeeding your quota ----------------------------------------------- -> LINUX accounts: You type your login and password, the login window goes away, it appears that you are getting logged in but after a few seconds the login window just reappears. Also, you can still login to your account from over the net. This problem occurs when you login at a console in our lab or RDP. Graphical environments (like GNOME or MATE) need free disk space to complete the login process, so exceeding your storage quota causes the login to fail. One way to fix the situation is to either log in via a text console or by remotely connecting using ssh. Once you achieve either type of connection you should try to reduce your disk usage by deletig old or unneccessary files until you get back under your quota. Once this is done you can attempt to login again on the graphical console or through RDP. -> Windows accounts: You get an error message pop up that says something like "you can't use NT5 permissions on this filesystem". The missing or useless error messages are caused by essentially the same problem on UNIX and Windows: the file access software does not interpret the error condition properly from the quota manager software. We hope newer versions of all the related software will improve this one day. How to get logged to reduce your disk usage (UNIX & Windows) ------------------------------------------------------------ -> UNIX accounts: 'ssh' is not blocked by the quota limit, so you can login from another account (perhaps from your home computer) and clean up. Also, each CDE login screen has a way; select "FAILSAFE" from the Options menu, then log in. You get one simple window that doesn't use a window manager or try to open any of your files, so you can delete some files. -> Windows accounts: You should be able to login, but you will be unable to add anymore files until you reduced your disk usage. How can I find what to delete? (UNIX & Windows) ----------------------------------------------- -> UNIX accounts: First look for large files that you could delete. Here are UNIX commands that display the size (in KB) of files and subdirectories (the '~' means your home directory): du -ks * .[a-z]* .[A-Z]* # files and dirs in the current dir find ~ -type d -exec du -ks {} \; # all subdirs in your account Look for things to delete in the large directories, such as - "core" files (left behind by programs that crashed) - .nfs files (left behind by the NFS remote filesystem software) - old files in your ~/.netscape/cache directory - excessive email stored in your ~/mbox file or ~/Mail directory These commands can be used to delete such files: find ~ -name core -exec rm {} \; find ~ -name \.nfs\* -exec rm {} \; rm ~/.netscape/cache/*/* rm .mozilla/default/*.slt/Cache/* ls -la ~/mbox ~/Mail The .nfs* files are created by the UNiX filesystem to keep track of files or programs that you have opened. If you remove the .nfs file which is still open, then it simply gets renamed to .nfs again so the client that has it open can still use it. To delete a .nfs file, you first should close the file in the application that has the file open, or stop the program if it is a binary you are trying to remove. Usually the application will delete the file as it shuts down. The default browser caches of netscape and mozilla are higher than needed. You can reduce your cache size so that the disk space that is used for it is smaller. To reduce your cache size in Mozilla: 1) Click on Edit-->Preferences 2) In the Preferences dialog box, click on plus (+) next to "Advanced" 3) Select "Cache" 4) Change your cache size to something small such as 2 MB. -> Windows accounts: Your profile directory (for example, U:\{your_logon}\profile) under your Windows home directory stores may things that you do when you logon and saves them. The contents of this directory are downloaded to your workstation when you logon and is copied back to the home directory of the server when you logoff. This directory can grow huge over time and can cause delays when you logon and logoff as well as uses up your disk quota. Windows by default limits the profile to 30 MB, and if you exceed that. and you get an error message when you try to logoff. You should clean out the "U:\{your_logon}\profile\Temporary Internet Files" directory, either manually or by deleting them using the options of your WEB browser ("View/Internet Options/Delete Files" in IE). You may also change settings so the directory doesn't get so large. You can clear the disk cache that saved by your broswer (in Netscape, select "Edit/Preferences/Advanced/Cache/Clear Disk Cache"). You can remove old files and directories you don't need any more. For more information, please see https://inst.eecs.berkeley.edu/cgi-bin/pub.cgi?file=windowsprofile.help WARNING! You can lose files (UNIX) ---------------------------------- -> UNIX accounts: The accounting for disk quotas is done by the operating system on the computer where the file system is locally mounted (the "file server"). On the EECS Instructional computers, all home directory file systems are exported from the file servers to the other computers, using software called "NFS" (Network File Service). This allows users to access their home directories from any computer. Unfortunately, NFS does not respect the quota accounting software, and the soft quota warnings are ignored. That means that if you are logged into a system other than your file server and you exceed your hard quota limit, the file that you are trying to save may be deleted! We hate this, but cannot fix it - this behavior is inherent in the operating systems of our computers. The best protection against this is to be aware of your disk usage and be careful. "Quota" vs "du" (UNIX) ---------------------- -> UNIX accounts: Note that "quota" counts not only the disk usage in your home directory, but also any other files owned by you on the same disk partition. The "du -s" command simply adds up the disk space used by the directory or file that you specify. For this reason, "quota" and "du" often display different numbers when referring to your home directory. Counting in "blocks" or "kilobytes"? (UNIX) ------------------------------------------- -> UNIX accounts: The "quota" command typically computes in 1024-byte units (kilobytes). However, the "du" command may use 512-byte "blocks" or 1024-byte "kilobytes". The Solaris UNIX systems default to 512-byte blocks, but can take the -k option to force "du" to compute in kilobytes. Other UNIX systems may compute the usage in kilobytes. So if you run the "du -s" command on an HP computer, it will give you a number that is roughly twice as big as the same command run on a DEC computer. (The different computing algorithms seem to generate slightly different results.) Adding to the confusion is the influence of NFS (Network File System), the software that allows systems to access one anothers disks over the network. NFS attempts to adjust for the difference in units, and that can end up doubling or halving the correct answer. Here are examples of the bizarre results: home directory if logged quota du -s ~ is on: in on: says usage is: says usage is: ====================== ============= ============= ============== User 1: HP system HP system 3933 (KB) 7722 (blocks) DEC system 3933 (KB) 1968 (KB) * ---------------------- ------------- ------------- -------------- User 2: DEC system DEC system 4133 (KB) 4133 (KB) HP system 4133 (KB) 8168 (KB) ** ---------------------- ------------- ------------- -------------- * here NFS is over-compensating, dividing by 2 in error ** here NFS is over-compensating, multiplying by 2 in error The bottom line is: trust the "quota" command, which displays the quota in kilobytes from the system that holds your home directory. Read "man du" on the system where you run it to determine if it is using blocks of kilobytes. Using USB flash drives on our workstations ------------------------------------------- The Windows PCs and LINUX PC's in EECS Instructional labs can read standard UCB memory sticks. You can copy files to and from it. We encourage students to keep a backup copy of their own files this way. Why is disk space so limited? ---------------------------- Cheap hard drives are deceptive. The actual cost of scaling storage goes far beyond the drives themselvesyou also need to account for extra servers, expansion bays, backup systems, and maintenance fees. On top of that, software keeps getting bigger with every update, eating up fresh storage almost as fast as you can add it. EECS Instructional Support 378/382/384/386 Cory Hall http://inst.eecs.berkeley.edu inst@eecs.berkeley.edu