Frequently Asked Questions
UBC Mathematics: MathNet FAQ [Sshfs usage]



UBC Mathematics: MathNet FAQ [Sshfs usage]




Question: How to mount/unmount MathNet home directory using sshfs ?
Author:
Date: Aug 22 2012

We use "sshfs" to mount your MathNet home directory securely.
For your convient, we created a sshfs script in "/usr/local/bin/mathfiles".
For usage, type 'mathfiles' at the command line terminal.

Before running the 'mathfiles' script, you must ssh to our ssh proxy server first.
This will store your new RSA key to your virtual server home dir.
Type 'ssh 137.82.36.23'
Type 'yes' to to continue connecting. This will store your new RSA key.
Type 'exit' to logout

To mount Mathfile, Edit .bash_profile and remove these hashes.


$ vim .bash_profile
...
mathfiles mount
sync
cd mathfiles
...

To unmount mathfiles after logout, Edit .bash_login and remove these hashes


$ vim .bash_logout
...
cd ~
sync
/usr/local/bin/mathfiles unmount
...

Logout and Login your VM again.
You need to supply your MathNet passwordd twice.
Once for your VM and once for mounting your MathNet's home directory.

Confirm your MathNet location
$ ls
You should see your MathNet files.

Notes:
If you are running batch jobs, don't edit the bash_profile and bash_logout to use sshfs during login/logout period. Instead, sshfs mount and unmount MathNet files manually.

To Mount:
$mathfiles mount
$cd mathfiles

To unmount
$cd
$mathfiles unmount

Do not save anything important on your local VM disk since it has limited snapshot and backup.

 
Top