Install Rasbian Stretch on Rasberry Pi

  • Download Raspbian Stretch Lite
  • Write image to SD card (Rufus or etcher) or use the dd utility
    • sudo dd if = “name_img” of = “/dev/name_blk_device” bs = 4096
    • lsblk
      • to identify the device run lsblk command before and after inserting the card
  • After writing the image, mount the SD card
  • Touch a file named “ssh” to the boot folder (this enables SSH access), or echo > ssh (on windows)
  • Insert card into RaspberryPi
  • connect to laptop using an ethernet cable
  • ping raspberrypi.local
    • if raspberry.local does not resolve, scan your local network using nmap to identify the ip address of the pi and ssh using the ip address
      • ifconfig – to identify the ip address of your laptop (assume this is
      • nmap – will identify hosts on the local network)
      • look for the pi. It will have port 22/tcp open
    • if pi cannot be located, workaround is to connect the pi directly to a keyboard and monitor, boot, login as default user (see default user details below) and then use raspi-config to enable wi-fi and ssh
  • SSH into the pi (e.g. using Putty or cmd line – ssh pi@<ip-address>)
    • username: pi
    • password: raspberry
  • passwd – to change the default password
  • sudo bash – to drop into a root shell
  • ifconfig
  • nano /etc/wpa_suuplicant/wpa_supplicant.cong – to edit the wpa_supplicant file
  • add
    • network {
    • SSID = “your_ssid”
    • psk = “your_password”
    • }
  • reboot
  • connect over ssh
  • apt update
  • apt upgrade
  • reboot
  • SSH using Putty
  • raspi-config
    • use option A1 to expand SD card  to allocate full  disc
    • enable vncserver
      • Start or stop the service with:
        • systemctl (start|stop) vncserver-x11-serviced.service
        • Mark or unmark the service to be started at boot time with:
        • systemctl (enable|disable) vncserver-x11-serviced.service
        • connect using a client like remmina
  • df – h – to see disc details
  • apt-get install lightdm (for installing the desktop environment)
  • apt-get install

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.