RU beehive logo ITEC dept promo banner
ITEC 345
2013fall
ibarland

homelectshws
D2Lbreeze (snow day)

deterlab-startup-instructions
deterlab startup
hw03 prelude

Overview

This document contains (only) instructions for starting up your deterlab machine; the “real” hw03 instructions, to be carried out on that machine, are at hw03 treasure/info hunt [see D2L].

deterlab.net is a site which allows you to create virtual personal machines and even entire networks. They call such machines/networks an “experiment”. There are four main steps you'll follow (with detailed instructions below): Overview

  1. Log in to deterlab.net and set up your virtual machine (your experiment).
  2. From your local machine, use a putty (or, from mac/linux, a terminal window) to ssh to deterlab's public server users.deterlab.net.
  3. Finally, from that public server, you'll ssh to the individual machine you created in step I, and follow the instructions in hw03 treasure/info hunt [see D2L].
  4. Transfer your answer-file back to your local machine, submit it on D2L, and shut down the deterlab experiment.

Detailed instructions

  1. Find the email you got from deterlab.net (you might need to check your spam folder). Note that your deterlab username will be of the form ru245zz, where zz will be two lower-case letters (e.g.ru245ap”).

    The email contains a link which will bring you to a page to set up your deterlab password.

    Warning: Do not lose your password; I will deduct 2pts from your score, if I have to manually re-set your deterlab account! Also, don't use your RU password, or any other sensitive password, on deterlab; I and other administrators might be able to access them.

    Once you have logged in to deterlab.net, do update your profile's Full Name (but you don't need to complete the address, phone#, etc.)

  2. Starting the deterlab experiment.
    (If deterlab is down for routine maintenance, I suggest you momentarily skip to part V, and prepare by figuring out exactly what you'll type when reach Vb.)
    1. Download and save-to-disk the file linux_deterlab_intro.ns.
    2. Select Open Experimentation > Begin an Experiment (screenshot below)
    3. Fill out the fields as follows:
      1. Select Project: ITEC245
      2. Group: Default Group
      3. Name: yourRUUsername (e.g. ibarland) This is used (only) in setting up a name for your virtual machine. In all other places on deterlab, when it asks for a username, deterlab wants your deterlab username, something like ru245zz.
      4. Description: something like “hw03 - linux intro”1.
      5. Your NS file: Upload the linux_deterlab_intro.ns file that you just downloaded in step II.1.
      6. Swapping:
        • Idle-swap: 1 hour. (The default is 4 hours, but we are among the kinder, gentler, more polite citizens of Deterlab).
        • Max Duration: 8 hours.
        • Linktest Option: Skip Linktest.
        Note that after either of these limits, your “experiment is swapped out” automatically.
      7. Swap In Immediately: leave this box unchecked for now.
      8. Click Submit.
    4. Wait for a while as Deterlab finds pre-loads your experiment. You are shown a pane "Working ..." where logging messages scroll by; it will finish with “Experiment ITEC245/yourUserId has been successfully created!” This should only take about a minute.

    5. Swap In Your Experiment:
      My DeterLab > Experiments > [your name, in EID list] > Swap Experiment In > Confirm.
      This step can can easily take five minutes or more; be patient while deterlab finds an open machine and and configures it. It should finish with “Swap Success!”.

      If you get the message “*** Admission Control: ITEC245/ITEC245 has too many nodes allocated!”, all of the machines available for our class are being used. Wait for other students finish and terminate their experiments, and try again. Be sure to start soon enough, that you'll be able to finish along with your classmates!

      Important: If you are working on the homework but are going to leave for an hour or more (say, to class or dinner), please swap out your experiment (the same way you swapped it in, above). The virtual machine servers are in tight use.

    6. Go to Experimentation > Active Experiment List
    7. Click on your name in the “EID” field
    8. Click on the Details tab. You should see something similar to this (here, the name of the experiment is RULinux; it will be a bit different for you). If you don't see this, be sure you really did wait a few minutes for the swap-in to complete.
    9. Look for the “Qualified Name” of the virtual machine created for you. In this example screenshot it is: node0.RULinux.ITEC245.isi.deterlab.net. You'll need to ssh to this machine below, so I suggest copy/pasting it.
  3. Log in to the deterlab public server (from campus/home):
    Use ssh to log in to users.deterlab.net. Use your Deterlab username/password.

    Using ssh: If you never remotely logged in to a machine using SSH, don’t panic. Well, panic just a little, and then read on:

    Note that when sshing to a new machine, you'll get a message similar to:
    The authenticity of host some.host.name can't be established.
    ECDSA key fingerprint is so:me:lo:ng:he:xa:ha:sh:co:de.
    Are you sure you want to continue connecting (yes/no)?
    
    Answer yes (and ssh will log something like: Warning: Permanently added some.host.name (ECDSA) to the list of known hosts.). This is all fine.

  4. Log in to your experiment (from users.deterlab.net):
    From users.deterlab.net, ssh into the virtual machine, whose name you copy/pasted in step I.9. That is, something like ssh ru245zz@node0.RULinux.ITEC245.isi.deterlab.net
    Congratulations; you are now the proud part-time leaser of a free Linux machine. Note that the terminal window you are looking at is the third of a layer: that shell on your virtual machine is being run from inside the shell on users.deterlab.net, which is being run from inside putty (or Terminal).
    (Um... Which is being run from your login of the your local machine's OS, which is being run from the GUI manager of your local machine.2) So when you finally finish, you'll wrap up by exiting all three layers.
  5. At last, you can begin! The exact tasks you need to do are in deterlab-hunt.html [see D2L].
    1. The document starts with some Linux info (much is review; some is new material but isn't needed for the hw (e.g. screen); some is new material that is needed for the hw (e.g. find/locate).
    2. Then, follow the three tasks (treasure hunt, etc.). This should leave you with a tarball (a .tar.gz or .tgz file) in your home directory, on the virtual machine.
  6. Now you just need to submit the answer file, and shut everything down.
    1. You'd reasonably think that we need to transfer the file from your virtual machine (which is not accessible to the general web) to the gateway users.deterlab.net. However, you don't actually need to: Much like your H: drive is mounted onto whatever RU computer you log in to, similarly your virtual machine's home directory was the same as your users.deterlab.net's home directory. So your tarball is already in the home directory of the gateway machine, you don't need to do anything for this step, yay!
    2. We'll copy the file from users.deterlab.net to your local machine. From your local machine, 3 using scp (Mac/Linux terminal — “secure copy”), e.g. scp ru245zz@users.deterlab.net:myAnswerFile.tar.gz myLocalCopy.tar.gz, or WinSCP (download for windows; it has a gui interface like putty).
    3. Now you can submit that (local) file to the D2L hw03-dropbox.
    4. If you haven't already, you can log out of your virtual machine (type exit), and then out of the shell on users.deterlab.net, and then shut down putty.
    5. Although your experiment will eventually swap out by itself, it's good karma to swap it as soon as your done, freeing up resources for your classmates, and other students across the country. (as visible on the left side of the screenshot w/ experiment details).

    6. Before you can start future homeworks, you'll want to Terminate the experiment (not just swap it out). You can do this at any point after you've submitted your homework, though you can wait until after it's been graded, if you like.

1This “description” field is for the Deterlab administrators to let me know if any experiment has gone rogue. Since I'm only using deterlab for one class, it won't be too hard for me to figure out what project they might be referring to.      

2 And I guess the your local hardware is running in The Universe, as is your brain, which also has a terminal-window into said Universe. Or, if you're a fan of The Matrix, your brain's terminal window is getting input some other machine.      

3You certainly could run scp to transfer from another machine to your own computer; this would require knowing your own computer’s IP address (as from www.whatsmyip.org/). Also, your machine's OS needs to be configured to accept incoming ssh connections, and a client needs to be running and listening to the port. (On a Mac, a client is running by default, but you might need to visit System Preferences > Sharing > Remote Login, to make sure a firewall isn’t rejecting all incoming ssh attempts. Of course, allowing this on your machine opens yourself up to attack, if they can find/guess an account name and password on your machine.)
For all these reasons, I recommend running scp on your local machine, as in the main instructions.      

homelectshws
D2Lbreeze (snow day)


©2013, Ian Barland, Radford University
Last modified 2013.Sep.21 (Sat)
Please mail any suggestions
(incl. typos, broken links)
to ibarlandradford.edu
Powered by PLT Scheme