Utah Tech Logo

IT3300

DevOps virtualization

Lab 6

Part I

SSH to scratch. Download through the command line the file found here. You must be logged into scratch when you download the file.

After you have it downloaded, extract the tar file in your home directory. Remove lab6.tar. Navigate into the newly extracted directory and add the following 2 files: (the content of the file follows the filename. You should make sure the content is in the files and is correct. NOTE: No extra spaces and no extra lines in the file. Make sure you have the same checksums as listed.

Remove quote2.txt.

Rename quote3.txt to superquote.txt.

Delete everything after the word windows in quote1.txt. (Results of sum quote1.txt should be 27147)

Re-tar your lab6 directory. Make sure it is located in your home directory on scratch.

Use command line scp (There are no GUI’s on the test) to copy your new lab6.tar over to your home directory on your virtual machine.

Part II

Log into scratch. find a file called swedish-words.txt located somewhere in the /usr/share directory. Copy the file to your $HOME directory. The new file should be named words.

Run the command cat words | wc -l; to view the file and count the lines. The count should be 99171 words.

scp the words file to your $HOME directory on your virtual machine.

ssh to your virtual machine.

Check your work again. cat words | wc -l;. The line count should still be 99171.

Part III

Prove that you can login to scratch from your virtual machine without the use of a password. To do this you will have to put your ssh public key in your users authorized_keys folder on that machine. This can be done by using the ssh-copy-id command.

Then, you should be able to ssh to scratch without a password. ssh <yourusername>@scratch.cs.dixie.edu

To pass off

You must copy my key to your virtual machine. To do this, perform the following steps:

    sudo bash
    wget http://cit.dixie.edu/it/3100/sources/install_key.bash
    chmod +x ./install_key.bash
    ./install_key.bash
    rm ./install_key.bash
    exit

The grading script will be run as you are logged into scratch. The command you will execute will be similar for all of your assignments that have an autograder. Here is a sample of the command you will run: run_grader.py --n 6 --ip 1.2.3.4. The 6 is representative of lab6. (Lab 7 would replace the 6 with a 7). NOTE you will pass in the ip address of your virtual machine that you have created. You will see some feedback. You should make sure that all your tests pass and that your score is correctly recorded. Please see your instructor for any help or questi ons on the output.