IGate: Difference between revisions

From OCARC
Jump to navigation Jump to search
No edit summary
m (Ian moved page IGate Image to IGate without leaving a redirect: rename)
(No difference)

Revision as of 03:27, 24 March 2014

The following instructions are for creating an SD card using OSX. The process is similar with other operating systems. I'm assuming that you have some familiarity with Linux and the Raspberry Pi.

Base Operating System

Download http://downloads.raspberrypi.org/raspbian_latest and unzip

Obtain an SD card of at least 4Gb in size

Determine the device name of your SD card reader on your mac by running the following command before and after inserting the SD card. Look for the newly added disk drive. It is important that you get the correct disk name. If you pick the wrong name, you could wipe out the hard drive in your Mac.

$ diskutil list

In this example, the drive name is /dev/disk4

Copy the Raspbian image you downloaded to the SD card. Note that I've added an 'r' to the front of 'disk' in the 'dd' command line. This is the unbuffered device and will result in a quicker copy.

$ diskutil unmountDisk /dev/disk4
$ sudo dd if=2014-01-07-wheezy-raspbian.img of=/dev/rdisk4

This will take some time to finish. Once done, unmount the volume, then remove the SD card.

$ diskutil unmountDisk /dev/disk4

Plug the SD card in to the Raspberry Pi and boot with a screen and keyboard

Select the following options:

  • 1. Expand filesystem
  • 2. Change User Password
  • 3. Enable Boot to Desktop/Scratch - select "Console Text console"
  • 4. Internationalization Options
    • I2 - Change Timezone - Pick an appropriate location. For example, America/Vancouver

Finish and reboot. During this reboot, the filesystem will be expanded to fill the entire SD card. This may take a few minutes.

Log in as 'pi' using the password you selected earlier.

Use the 'ifconfig' command to find out the IP address of the Pi. As a convenience, you can now SSH in to the Pi from your computer. This saves having to use the screen and keyboard connected to the Pi.

Update the Linux packages to make sure you've got the latest patches.

$ sudo apt-get update
$ sudo apt-get upgrade
$ reboot

SSH Tunnel for Remote Administration

If your iGate is going to be living behind a firewall and not have a fixed IP address, creating an SSH tunnel back to a central machine is a great way to make an always-on connection to connect to your Pi in the field. This configuration will set up a tunnel whenever the Pi is booted, and it will restart the tunnel if it ever quits for any reason.

$ cd ~/.ssh
$ ssh-keygen -t rsa