Lagringshotell Technical Description
Setup, Quotas, Management...
This article is only relevant for the IT staff at dept. of Geosciences.
The "lagringshotell" (storage hotel) is USIT's name for the campus-wide network attached storage (NAS). It is currently a system from Hitachi (HNAS), but the underlying technology could likely be changed in the future without the user noticing.
Data storage on the lagringshotell appears similar to a "disk" to the end user, available as NFS or SMB. There are some differences, notably the quota system and lack of rigid file system barriers.
Unlike traditional disk systems, the storage is a continuous (large) file system, with quota trees defining maximum size for directories. Think of a quota tree as a disk, but with vastly better utilization of the space, as free space is available to all quota trees. The quota trees are also the SMB shares.
Current data structure
Our department has a single top quota tree /uio/lagringshotell/geofag/ that has a maximum quota for all department use. This directory is exported by NFS to all hosts in the group geofag-hosts, and is root-exported to geo-master.
To mount this directory and its subdirectories with a unified name on Linux, a little trick is made to utilize the /net/hostname mechanism for the automounter:
sverdrup$ ls -l /uio/lagringshotell lrwxrwxrwx. 1 root root 38 Nov 9 10:56 /uio/lagringshotell -> /net/lagringshotell/uio/lagringshotell
This way, the name /uio/lagringshotell/geofag et.al. will work on all Linux hosts. Note that the symlink must be created manually.
Below this top directory, we (currently) have the following directories:
sverdrup$ ls /uio/lagringshotell/geofag/ admin data geolgf kurs pgp students ceed geohyd icemass metos projects
This list should be fairly static. Do not create additional directories (or files) here without discussion in the group, and consultation with USIT.
The lagringshotell implements snapshots, similar to what we have on the home directories on e.g. kant. To access a snapshot, simply enter it:
sverdrup$ pwd /uio/lagringshotell/geofag/kurs/GEG sverdrup$ ls -a . .. GEG2110 GEG2250 sverdrup$ cd .snapshot sverdrup$ pwd /uio/lagringshotell/geofag/kurs/GEG/.snapshot
Note that the .snapshot directory is not visible in a directory listing (not even with a full listing, ls -a). The exception is the top directory:
sverdrup$ ls -A /uio/lagringshotell/geofag/ admin data geolgf kurs pgp .snapshot ceed geohyd icemass metos projects students
One consequence of this is that a find(1) job should not be started like this, ie. on the top directory:
geomaster# find /uio/lagringshotell/geofag/ -name .... # Don't do this
This will cause find(1) to traverse the snapshot tree. This is probably not what you want! Instead, do
geomaster# find /uio/lagringshotell/geofag/* -name
In addition to the quota on the top directory /uio/lagringshotell/geofag, there are quotas on all directories two levels down! However, there are no quotas one level down.
|/uio/lagringshotell/geofag||Top directory, total department quota.|
|/uio/lagringshotell/geofag/*||No quota on these directories.|
Most of these quotas are "disk" quotas, and can be inspected with df(1), eg:
sverdrup$ df -h /uio/lagringshotell/geofag/projects/hades/ Filesystem Size Used Avail Use% Mounted on lagringshotell:/uio/lagringshotell/geofag 5.0T 2.1T 3.0T 41% /net/lagringshotell/uio/lagringshotell/geofag
The exception is the "students" area /uio/lagringshotell/geofag/students, where quotas are per-user, default 100 GB. To inspect a user quota, you have to assume that users identity. E.g., as root:
geo-master# su -s /bin/sh foobar -c "df -h /uio/lagringshotell/geofag/students/geolgf/foobar" Filesystem Size Used Avail Use% Mounted on lagringshotell:/uio/lagringshotell/geofag 600G 334G 267G 56% /net/lagringshotell/uio/lagringshotell/geofag
Note the use of the "-s" switch to specify a shell, as the user "foobar" has no valid shell on geo-master. On public machines like sverdrup, this is usually not needed.
Quotas are set or changed by USIT, on request from Geo-IT. Such a request needs to contain the directory or user in question, and the new quota.
New quota areas (directories) need a globally unique name. Thus, don't choose generic names like "admin" or "data", use eg. foo-data, even if this will result in a bit weird names. See the icemass directory for examples of this.
Do not create new directories in /uio/lagringshotell/geofag/*/ . Let USIT do this.
Student directories can be created and chown'ed to the user in question, the default quota will automatically apply. You don't need to contact USIT unless you want to change that.
Quotas will only be set on the levels discussed above. This is a demand from USIT, as this makes management simpler.
For new storage areas (quota trees), do create a directory 00-ADMIN with a file Projectdiskinfo.txt containing relevant information on the directory: The project leader, other users, project URL's, RT ticket numbers, disk size (quota) agreed upon, project start and end date, and other relevant info. The file can be readable to all, but only root should be able to change or remove it.
For student areas, do create a file README.txt detailing at least size, if different from default. Do include the RT reference as well. A student's area should normally be purged before they can receive their Masters diploma.