This page describes several common tasks related to managing virtual machines in the VM Cluster ("SKY").
Running administrative commands
When we provision your VM, you will be given access to it via SSH using your RCC credentials. We will configure your RCC credentials with sudo access, so that you can run administrative commands on your VM. To run an administrative command, simply prefix it with sudo:
# Example SUDO invocation [jsmith@sky-researchgroup-vm1] $ sudo vi /etc/fstab [sudo] password for jsmith: [enter your RCC password]
Managing SSH Access
When we provision your VM, we will configure SSH to allow only specific groups to login. You can see which groups are able to login by looking at the /etc/ssh/sshd_config file. In the following example, only the root, admins, and genomics groups are allowed to login. root and admins are local groups, and the genomics group is an RCC-managed group.
$ tail /etc/ssh/sshd_config # Example of overriding settings on a per-user basis #Match User anoncvs # X11Forwarding no # AllowTcpForwarding no # PermitTTY no # ForceCommand cvs server # Allow Groups AllowGroups root admins genomics
You can add access for more groups (both local groups and RCC groups) by adding them to the AllowGroups line.
CAUTION: If you remove or comment out the AllowGroups directive, all RCC users will be able to login to your VM. It is best to not change this parameter unless you know what you are doing.
There are two ways to manage users on your VM:
- Grant access to users using RCC accounts. Anybody who needs to access your VM must have an RCC account and be added to a specific group in order to login to your VMs. The advantages of this method are that you do not need to worry about creating, updating, deleting, and managing security for user accounts. Your VM users can use the same credentials on your VM as they do to login to other RCC systems. This is the preferred method for account management.
- Grant access to users by creating local accounts. Simply create new users and groups on your VM as you would on any other Linux Server. If you do this, you must be sure to not create any account that overlaps with an RCC username. Avoid using FSUIDs when creating new accounts.
Granting RCC Accounts access to your VMs
If you wish to use RCC account management to manage users, take note of which groups are allowed access to your VM (see Managing SSH Access above). Then, simply login to the Account Management section of this website, browse to Groups and add/remove whichever users you wish to grant access to. If you are not able to add or remove users, you will need to request group administrator privileges by submitting a support request.
Creating local users for your VMs
Creating local users is done as it would be on any Linux system. There is one caveat, however. To keep things orderly, you should ensure that an existing RCC account does not already exist with the username you wish to use:
# User 'xyz05d' already exists as an RCC account, so you should choose another username $ id zyx05d uid=99881(zyx05d) gid=92313(zyx05d) groups=32313(zyx05d),513(genacc) # User `zzz99d' does not exist yet, so you can create it. $ id zzz99d id: zzz99d: no such user
There are several ways to create a new user, the most common of which being `adduser`:
# Create a new user named 'anewuser' $ sudo adduser anewuser
Starting, stopping, restarting, and rebuilding VMs
If you need to restart your VM for any reason, you can do so the same way you would any other linux server:
# Restart VM immediately [jsmith@sky-researchgroup-vm1] $ sudo shutdown -r now
After running the restart command, you will need to wait several minutes for your VM to reboot. If you are unable to gain access after reboot, let us know.
Currently, we do not provide a self-service control panel for starting or stopping VMs, or for accessing the console. However, you can submit a support request for an RCC Staff Member to do so. In general, VMs are expected to run 24/7, so stopping and starting should only be necessary on occasion.
If you would like us to perform a "factory reset" on your VM, deleting all data and reverting it back to a fresh install, submit a support request.
Installing and managing packages
All VMs in the cluster use the yum package manager. The RCC maintains and manages a local software repository that contains most common Linux packages, as well as specialized scientific software that we provide on the HPC and Spear (see a full list). Installing software is usually as simple as running yum:
# Install NANO text editor $ sudo yum install nano # Search for packages with "php" in the title $ sudo yum search php # Remove package "vi" $ sudo yum remove vi # Install Apache HTTPD server $ sudo yum install httpd
You can also compile and install software on your VM using standard compliation/build tools. If you need assistance installing software on your VM, let us know.
Mounting Lustre or Panasas filesystems
Occasionally, you will need to mount the Lustre or Panasas filesystem on your VM. If you need to do so, submit a support ticket. An RCC staff member will create a storage export on our system and provide you with instructions for mounting the filesystem on your VM.