Category Archive: Raspberry Pi

RPi Setup

This is a list of things that I like to do to every RPi/ Linux server that I setup for personal use.

Jan 16

Setup SSH

Generate a new SSH key ssh-keygen -t rsa -b 4096 -C “sprinklers_pi” Update your computer to use the new one eval “$(ssh-agent -s)” ssh-add ~/.ssh/id_rsa View your new public key cat /home/pi/.ssh/id_rsa.pub Add it to authorized key file of other computers to allow this computer password-less SSH access vim ~/.ssh/authorized_keys

Jan 16

Install tmux

Install the dependencies sudo apt-get install libevent-dev libncurses5-dev Download the latest version of the source code here wget “https://github.com/tmux/tmux/releases/download/2.3/tmux-2.3.tar.gz” Unpack the download tar xvfz tmux-2.3.tar.gz Move to that directory and compile the source code cd tmux-2.3/ ./configure && make Install the compiled code sudo make install Create a configuration file for later configuration and use …

Continue reading »

Jan 16

Use PiHole to resolve local DNS

dnsmasq will read any file in dnsmasq.d as a configuration file; this is how Pi-hole works too. The file (02-mydns.conf) you’ve added tells dnsmasq where to find another hosts file (hosts.mydomain). This will survive installs and updates by the Pi-Hole curl script. Anytime you update your hosts.mydomain file you will need to restart dnsmasq for …

Continue reading »

Jan 16

Setup Pihole

Run this command: curl -L install.pi-hole.net | bash Setup router to point to Pi-Hole for DNS Edit the /etc/hosts file to add all computers to it for convenience Setup DNSCrypt instructions here

Jan 16

How to Set a Static IP Address

Find and edit the interfaces file sudo vim /etc/network/interfaces Find the block of code that look like this and replace it with the IP addresses that fit your network. face eth0 inet static netmask 255.255.255.0 gateway 192.168.0.1 address 192.168.0.107

Dec 13

Boot into graphical mode on Kali

Find out what level you are currently running on who -r Find the name of the service manager currently running chkconfig –list | grep ‘2:on’ If gdm3 is not installed/ used, install it sudo apt-get install gdm3 If chkconfig is not installed, install it apt-get install chkconfig Turn ON the service to auto boot to …

Continue reading »

Dec 13

Setup Raspberry Pi for remote desktop

Change the IP address to be static through your router Backup the existing network configuration sudo cp /etc/network/interfaces /etc/network/interfaces.backup Set the new ip address Edit the interface file sudo vi /etc/network/interfaces Find the part the looks like this and replace the ip address with the new, static one iface eth0 inet static address 192.100.1.102 netmask …

Continue reading »

Dec 13

Setup Raspberry Pi

How to flash an OS image onto an SD card

Dec 11

Flash Raspberry Pi image on a SD Card

Format the SD card (FAT32) diskutil list diskutil eraseDisk fat32 RP\ HD /dev/disk3 Flash the OS to the SD Card diskutil unmountdisk /dev/disk3 cd Downloads/ sudo dd bs=1m if=kali-1.0.9-rpi.img of=/dev/disk3 note: ctrl-t (to see status durring dd)   Other helpful info Diskutil commands diskutil eraseVolume JHFS+ [name] /Volumes/SecondVolume diskutil reformat /Volumes/SecondVolume diskutil rename “{current name of volume}” …

Continue reading »