Hands-On Internet of Things with Blynk
上QQ阅读APP看书,第一时间看更新

Creating a configuration file for SSH

The Raspbian Stretch Lite doesn't have any configuration settings enabled to work with the SSH protocol for secure remote login from another computer. Therefore, first you should create a configuration file to enable the use of the SSH protocol:

  1. With the SD card connected to your computer, open Command Prompt and change to your Pi's boot partition (let's assume the boot partition of the SD card is i):
C:>i
  1. Then type the following command to create an empty file named .ssh on the root of the boot partition of the SD card:
i:>echo .ssh
  1. Remove the SD card from your computer, and place it into the SD card slot on the Raspberry Pi. It will only fit one way.
  2.  Connect the USB Wi-Fi dongle to one of the USB ports (unless you have a Raspberry Pi 3).
  3. Connect the Ethernet cable between your Raspberry Pi and the router.
  4. Finally, connect the power supply to the micro USB port of the Raspberry Pi, and apply power. You will see a steady red LED and intermittently flashing green LED. Wait until the green LED turns off.
  5. Log into your router's portal and find the dynamic IP address assigned with your Raspberry Pi:

Raspberry Pi can be found under Device List

  1. You will notice that the allocated IP address for my Raspberry Pi is 192.168.1.5. You may get a different IP address based on your network topology.