You will need access to a Unix shell (Max OS X or Linux) or use MobaxTerm to login into the info server.
If you have not already done so, read chapter 3 (remedial UNIX skills) in Bioinformatic Data Skills. Alternatively, you could also use a tutorial like this one on using the shell from software carpentry.
In class this week Brian introduced some of the basic commands on the UNIX shell to help you login into a remote machine using ssh
So first you login into the remote machine:
ssh username@server.cawhere the username and server information are on your sheets.
Then we learned some commands to navigate around the file system like:
lsto list the files in the current working directory or:
ls /to look at the contents of the folder.
We also learned to navigate around to other directories (i.e. cd / to change to the root directory, or cd ~ to go back to the home directory) and determine our working directory (pwd). We discussed making new files (touch newFile), removing files (rm newFile), making new directories (mkdir myNewDirectoryName) and removing directories (rmdir). We used the mv command to both move and rename files, and cp to copy files (and scp to move files across computers). To get more information about the commands we used (including for finding flags for optional arguments) we used the man pages (like man ls). we used more to look at the content of a file one page or line at a time. To examine the jobs running on the machine we used both top and ps.
Given the tutorial, and your readings, we now want you to do several things.
- log onto the remote machine (info) that you have access to. What directory do you start in when you login?
- Without changing your working directory, look at the contents in the root (
/) directory. - the info server has most of the bioinformatic software located in
/usr/local. Please navigate (change directory) to this location. - using what we learned in class (and maybe using
manto find the right flags) take a look at all of the files. You will notice that there are more items in this directory than can be displayed on the page at one time. Instead look up the arguments for thelscommand that will allow you to simultaneously do the following:- display each item in the directory in its own row.
- provide more information about each item (in particular permissions like
drwxr-xr-x).
- What is the permission for the directory to the program
bowtie2for you (located inusr/local/). - return to your home directory.
- make a new folder called NewFolderTest.
- Navigate into NewFolderTest.
- Create a new empty file called EmptyFile.txt (hint remember the
touchcommand). - Copy EmptyFile.txt to a new file EmptyFile2.txt.
- Rename EmptyFile.txt to EmptyFile3.txt
- navigate back up to your home directory.
- try to delete NewFolderTest. What happens? How can you delete NewFolderTest and all of its contents?
- What is the top running process currently on the machine you are working on?