[ Skip to the content ]

Institute of Formal and Applied Linguistics Wiki

[ Back to the navigation ]

Table of Contents

IT tricks

Various tips how to increase your productivity (esp. in Linux).


Who uses which editor and is willing to provide a mini-training for new users (show config, favorite macros, highlighters etc.).
Feel free to add your name and editor.


Directory-local Bash history

Colorful manpages

Add this to your .bashrc (tested on .zshrc). Colors can be easily customized.

man () {
        env LESS_TERMCAP_mb=$'\E[01;31m' \
        LESS_TERMCAP_md=$'\E[01;38;5;74m' \
        LESS_TERMCAP_me=$'\E[0m' \
        LESS_TERMCAP_se=$'\E[0m' \
        LESS_TERMCAP_so=$'\E[38;5;246m' \
        LESS_TERMCAP_ue=$'\E[0m' \
        LESS_TERMCAP_us=$'\E[04;38;5;146m' \
        man "$@"


  export PS1='[\t]\[\033[2;31m\]\h:\W\[\033[01;95m\]$(__git_ps1 "(%s)")\[\033[2;31m\]>\[\033[0m\] '

Plots, vector graphic

LaTeX, pdf

TAR archive mounting

If you work with data consisting of many small files, you should store them in tar archives to save inodes and use LUSTRE filesystem efficiently. There is a way to mount a tar archive to a specific directory in a similar way you would mount an ISO image. You can use this command to mount (read-only) ARCHIVE (possibly compressed) to DIRECTORY:

/opt/bin/tarmount ARCHIVE DIRECTORY

and umount when you finish your work:

/opt/bin/tarmount -u DIRECTORY

If you mount your data in this way, there is only one open operation instead of thousands or millions of such operations when opening each file separately. This will positively affect runtime when your data is stored on the LUSTRE filesystem.

Run the command with –help option to see instructions for more advanced usage. The original tool can be obtained here.
It can be installed as AppImage.

Practical usage notes

  1. tarmount is based on FUSE. You need to do call the tarmount command on every node where you need to access the tarfile contents. If two jobs are running on the same node both of them will see the mounted content.
  2. if you finish your work you should always call tarmount -u DIRECTORY. If you don't the directory will not become blocked for any subsequent attempts to tarmount anything on them and may be in a weird state indicated by many '?'s in output of the ls -al command. This can be solved by calling simple umount DIRECTORY
  3. The tarmount command creates a database in the directory where the ARCHIVE is stored. The database is not automatically deleted by tarmount -u. It is however reused by any subsequent tarmount command called on the same ARCHIVE. This may speed up access for all jobs using the same tarmounted archive across the cluster.


[ Back to the navigation ] [ Back to the content ]