Saturday, October 27, 2012

Shelling In from Windows

So I'm guessing that you may have heard the phrase 'shell in' before.  No, it's not betting on a rigged shell game on the streets of New York City.  I had heard 'shell in' a lot of times (I hang with geeks), and vaguely understood that it meant controlling one computer from another computer (via a network) - but that was about as far as I went before owning a Pi.  It is a very useful ability to have, however, as it will let you do things on the Pi with only an ethernet cable, power, and your internet router.

Firstly you will need to scan the IP addresses on the router.  This will tell you what is connected (including the Windows machine you are using, and the the Raspberry Pi).  The program I use is called Angry IP Scanner.

Step 1:  Download it here.  I am using version 3.0 beta-6 (if you don't know what that means, don't worry about it).

Step 2:  Run the program (it's called ipscan-win32-3.0-beta6 in my case, yours will be ipscan-win...? where the ...? is whether it's 64 or 32 bit (32 bit will run in 64 bit windows, so it's easier to just use that one unless you have issues) and the rest of the ...? is the name of the version.  I use it enough that it was worth pinning a shortcut to my taskbar.

Step 3:  When you first open it it'll scan only a range of 1 IP address (shown at the very top of the screen).  That is the address of the computer you are running the program you are working on.  The IP address of the Pi will probably be within a few numbers of this, depending on how many devices you have joined to your router

So in the first box of the IP range (highlighted in blue) put a number 10 below and in the second box enter a number 10 above your computer's address.  Press 'Start.'  Since it's plugged directly into the router the 'Ping' will be very low.  Yup, the Pi's address on this router is '' - remember that number, you'll need it in a minute.

Now that you know where your Pi is on the network.  You need to connect - for that we'll be using PuTTY.

Step 1:  Download and run it.

Step 2:   Enter the address of the Pi into the Host Name (or IP address) box:

Leave the Port as 22 (no changes there) and click the Open button (highlighted in blue).

Step 3: Then the PuTTY window opens you will be asked who you want to 'login:as' - This is your user name.  If you are running Raspbian the default is:

You will then need to enter your password.  Hopefully you've changed this from the default, but if not, this will be:

Congratulations, you've successfully shelled in to your pi.  You will only be able to use the command line tools from here (since anything else will require a monitor to be plugged into the pi), but that's enough to install software, and do cool stuff like 'Dark Pi Rises' or creating an IP camera to watch your animals.

 Wow, exciting.

A bit shout-out to Tim for teaching me how to shell in and helping me grab the software.


  1. Hi there, my name is Mark and i'm a noob in Dublin. This is a great blog. Very useful to all noobs. Some of the uber geeks on the raspberry pi forums seem to think that we can understand their explanations. I wanted to ask you do you have to be connected to the internet to ssh into the pi or can you do it over wifi using vpn.

    1. Woot! My first comment.

      Now that's taken care of... The answer is no. You don't have to be connected to the internet. This technique works whether you router is connected or not.

      Sorry for the delay between posts, glad you like the blog. I had to translate from the geek too (with help), hence the blog.

  2. hi following this tutorial:
    I was able to access the GUI(desktop) on my pi through putty
    instead of launching it with startx you use lxsession& though, you can also use graphic programs straight from putty without opening up the desktop i.e. leafpad&
    thought this might be helpful to people viewing this page

  3. Who was that masked man?

    Thanks for this - I'm afraid I must have missed your comment. I'll check it out and post an update. Thanks!