-
Notifications
You must be signed in to change notification settings - Fork 0
Customising your bash profile for ease and efficiency
A customised bash profile can help make your personal experience of using the HPC easier and more efficient.
It is controlled by a hidden file in your home directory named ~/.bash_profile. The . at the beginning of the filename makes it invisible to a normal ls, but ls -al will show you all invisible files in a directory. ~/.bash_profile is automatically loaded when you log into the HPC and any preferences you set within it are applied to your shell environment.
One of the most useful applications of a bash profile is to set shortcuts for commands you commonly use. This can be done with alias, which allows you to attribute some command to a single word of your choosing. For instance, if you are frequently navigating to a specific project area, you can add the following line to ~/.bash_profile to avoid having to type out the whole path every time:
alias myproject='cd /ei/projects/pathtoyourprojectarea/'
Then you only have to type myproject to navigate to that directory.
If you don't already have a ~/.bash_profile file, you can create one with nano ~/.bash_profile. Here's a basic starter template you might want to use:
alias data='cd /ei/projects/pathtoyourprojectarea/'
alias scratch='cd /ei/.project-scratch/pathtoyourscratcharea/'
Then you can simply add a new line for each feature you add. There are endless customisations you can make. For instance, you can set up a quick shortcut to viewing what jobs you personally have running on the queue:
alias jobs='squeue -u username'
Have a search online for inspiration to optimise your ~/.bash_profile. After editing ~/.bash_profile always remember to log out and back in to the HPC for the changes to take effect.
- Induction
- HPC Best practice
- Job Arrays - RC documentation
- Methods to Improve I/O Performance - RC documentation
- Customising your bash profile for ease and efficiency
- Customise bash profile: Logging Your Command History Automatically
- Using the ei-gpu partition on the Earlham Institute computing cluster
- Using the GPUs at EI
- HPC Job Summary Tool
- EI Cloud (CyVerse)
- Git and GitHub
- Worked examples
- Job Arrays
- Using Parabricks on the GPUs
- dependencies
- Software installations
- Workflow management system
- Transfers
- Local (mounting HPC storage)
- Remote - <1gb (ood)
- Remote - <50gb (nbi drop off)
- Remote - No limit (globus)
- mv command
- The nbi-download partition (retrieving external datasets)