User Tools

Site Tools



The CHPC cluster uses CentOS as its operating system and follows the user private group convention for user accounts. This means that each user has a username (UID) and a corresponding group (GID). This scheme allows for easier set up of shared directories on the various file systems (home or Lustre) that users have access to.

Default umask

The default umask is set by the umask command in your .bashrc or the system wide /etc/bashrc file. For RedHat derived systems (CentOS) the default umask is 002 which means the the group permissions of your files and directories will match the user permissions and include write access, the w flag.

This is needed for shared groups (not your private user group) where all members of the group need write access.

Checking your current umask

Simply run the command umask without any arguments on the shell:


and your current umask setting will be displayed:


To change it, run the umask command with the desired umask as the sole argument:

umask 022

And you can confirm this by running umask on its own again.

CHPC Standard

The CHPC departs from the user private convention in one important way. The convention would normally only specify that the user is a member of the user's private group. The CHPC adds the user name of the CHPC staff member responsible for supporting your programme.

So, instead of


where there is no user in the group, we have


where chpcstaff would be the username of the CHPC staff member.

This is to allow our staff to have access to your files to help you with technical issues.

Disabling write access

If you want to remove the w access from the group permission you will need to change your umask and also change all the current permission bits.

Step 1: umask

Edit your .bashrc file in you home directory and add the line

umask 0022

at the end of the file. Save it. Now when you log in next time your umask will block w from group access.

Step 2: remove w access from all files and directories

Warning: this can take a long time if you have a lot of files so first launch an interactive session before running these commands.

qsub -I

Use the find command:

find . -exec chmod g-w \{\} \;


Shared Group Directory

The above is used to share a directory on the cluster amongst the members of a CHPC research programme, also known as a project.

The PI of a project can request a Linux group be created on the cluster for their programme, using the short name, also known as the project name. This is the same project identifier used with job scripts to in

The PI of a project can further apply for a shared group directory on /mnt/lustre/groups, however, this requires special motivation as described in the CHPC User Policy document. The setgid bit will then be set on that directory.

/app/dokuwiki/data/pages/howto/umask.txt · Last modified: 2022/03/18 12:12 by wikiadmin