Skip to content
Igor edited this page Aug 27, 2017 · 9 revisions

Welcome to the RaspberryPi wiki!

How to initialize Raspberry Pi with network on first boot without keyboard, screen and cable. Even with WiFi. 3 Things to do:

  • Burn normal Jessie image on SD card.

  • Add empty ssh file in boot partition of the SD.

  • Add wpa_supplicant.conf file in boot partition of the SD with content.

    network={ ssid="your_ssid" # Add next line for hidden SSID only. scan_ssid=1 psk="your_pass" key_mgmt=WPA-PSK priority=100 }

Setting hostname to Raspberry Pi

Batch install of Python modules:

`sudo pip install -r requirements.txt`

Get project from remote git repo:

`git init`
`git remote add origin ssh://server/path/`
`git clone ssh://server/path/`

Recommended software to install for Smart home use:

sudo apt-get install -y python-dev
sudo apt-get install -y mosquitto mosquitto-clients python-mosquitto
sudo apt-get install locate
sudo apt-get install chkconfig
sudo pip install paho-mqtt
sudo pip install Adafruit_GPIO
sudo pip install redis             # ?
sudo pip install hiredis           # ?
sudo apt-get install redis-server  # ?

Problems and solutions

When Raspberry pi keeps the IP and stops network communication: You can clear that buffer by reading from it (cat /dev/xconsole), but then it'll fill up again over time. You can also remove a bit of configuration to stop that buffer being used.

As root edit the /etc/rsyslog.conf file and remove the following lines from the bottom of the file. daemon.;mail.;` news.err;\ *.=debug;*.=info;\ `.=notice;.=warn |/dev/xconsole

(you could also comment them out by putting a # at the start of the lines)

You can then restart the rsyslog service with sudo systemctl restart rsyslog.service

How to remove/uninstall restartd sudo rm -f /etc/init.d/restartd /usr/sbin/restartd /etc/init.d/restartd Restartd is useful service for some cases.