CSE 422S: Studio 1

Raspberry Pi 3 Setup

"It's a dangerous business, Frodo, going out of your door. You step into the road, and if you don't keep your feet, there is no knowing where you might be swept off to."

—Bilbo, The Fellowship of the Ring by J. R. R. Tolkein, Book 1, Chapter 3

Welcome to day 1 of the Operating Systems course! We're going to start by making sure your Raspberry Pi is operational and works with the laboratory infrastructure.

In this studio, you will:

  1. Set up your Raspberry Pi 3
  2. Boot, log into, and explore different configuration settings of Raspbian Linux.
  3. Submit your answers to the first set of studio exercises (thus also validating that the class e-mail account is set up correctly and you are able to send e-mails to it).

Please work in a group of 2-3 people to complete the required exercises below, as well as the optional enrichment exercise if you wish to complete that one too.

As you work through these exercises, please record your answers, and when you are finished with all of the required exercises (and if you did it the optional one) send just one email for the whole group with those answers to eng-cse422s@email.wustl.edu with the phrase Raspberry Pi Setup Studio in the subject line.

Make sure that the name of each person who worked on these exercises is listed in the first answer, and make sure you number each of your responses so it is easy to match your responses with each exercise.

Required Exercises

  1. As the answer to the first exercise, list the names of the (2 or 3) people who have worked together on this studio.

  2. To start, you need to set up your Raspberry Pi 3 so that you're able to run a working version of Linux. If you have the reccommended starter kit from Canakit, you can follow these directions to set up and boot into the default Raspbian distribution, which is what we will be using in this course.

    A couple of key tips to avoid problems: make sure you install the heat sinks and MicroSD card that were provided in the kit after you have put the Raspberry Pi 3 card into the protective case, and make sure you set the language to US English and the keyboard to us before beginning installation.

    Once you have installed and successfully booted into Raspbian, and can see the desktop, please say briefly what image you see as the desktop's background, as the answer to this exercise.

    Note that if you run into problems later (e.g., when trying the optional enrichment exercise) and are completely shut out of your raspberry pi, you can re-image it by shutting it down, starting it back up, and holding down the shift key when it says to do so. Doing this will repeat the installation, destroying the image that was already there (and forcing you to repeat the following steps) but giving you a way to recover to this initial starting point).

    This in turn is strong motivation to back up copies of your work on other machines (possibly using svn, git, or another repository service, use multiple raspberry pi machines within your group for redundancy, etc. Starting with the next week's exercises, we will be making substantial changes to code etc. that you will need to manage effectively even if your raspberry pi should freeze up, lock you out, etc.

  3. Click on the raspberry icon at the top left of your desktop, select the Preferences menu item and then from that menu select the Raspberry Pi Configuration menu item. In the dialog window that appears, click on the Localisation tab, and click on each of the buttons in turn to read and configure the settings that your displays and keyboard will use. As the answer to this exercise, write down what each of the settings was (i.e., before you changed it, if you had to make a change).

    For the Set Locale... settings, set the language to en (English), the country to US (USA), and the Character Set to UTF-8, and click OK.

    For the Set Timezone... settings, set the area to America, set the location to Chicago, and click OK.

    For the Set Keyboard... settings, set the country to United States and set the variant to English (US), and click OK.

    For the Set WiFi Country... settings, set the country to US United States and click OK.

    Click on the OK button at the bottom of the dialog window, which may cause your computer to reboot. If it does not reboot automatically, click on the raspberry icon, click on Shutdown..., and click on Reboot.

  4. In its default configuration, the Raspberry Pi 3 is usually set up to boot automatically into a default account with username pi and password raspberry, which is not very secure for long-term use (though probably ok at least briefly while setting things up).

    To help avoid having your Raspberry Pi recruited into an evil bot swarm (or other undesirable and unauthorized use), re-open the Raspberry Pi Configuration dialog window, and on the System tab of the dialog window that appears click on the Change Password... button, and in the window that appears, type in raspberry as the current password, and then enter (and re-enter to confirm) a suitably strong new password that you should please also record somewhere so you can still get access to your Raspberry Pi.

    As the answer to this exercise please say yes or no for each of the following 5 items, to indicate whether your new password (1) contains at least one lowercase alphabetic character, (2) contains at least one uppercase character, (3) contains at least one numerical character, (4) contains at least one non-numeric, non-alphabetic character, and (5) is at least 8 characters long (if the answer to each of these is yes, then your password may be strong enough to be accepted - if not, keep trying until you succeed).

  5. Finally, we will set up wireless networking so that you can access the internet from your Raspberry Pi.

    Please click on the wireless networking icon to the upper right of your desktop, and select the wustl-2.0 network from the list that should appear (possily after a brief wait). When prompted to do so, enter your WUSTL Key id and password, and once you are connected to the network, click on the browser icon that's next to the raspberry icon on the top left of your desktop, to open up a browser. Enter the URL of the home page for this course, http://www.cse.wustl.edu/~cdgill/courses/cse422/ and confirm the page loads.

    Once you have done that, open up a terminal window and in that window enter the command

    hostname -I

    and note the IP address that appears.

    As the answer to this exercise, give the IP address for your raspberry pi.

Optional Enrichment Exercise

  1. Please see the Linux Users - Raspberry Pi Documentation page for more information about how to add other user accounts to your Raspberry Pi, create home folders, etc.

    Be careful with some of the commands on that page, as they can remove accounts, remove passwords, etc. which can leave you without a way to get into your Raspberry Pi (forcing you to start all over by re-imaging your MicroSD card, etc.)

    Try different and as the answer to this exercise describe what you did and what you saw when you did that.