GUIDE - Fresh Setup of Raspberry Pi 2 (B)

Recommended Posts

So little did I know that today the RPi 3 would be announced, However I got my RPi a few days back. Alot needs to be done to get it to work "properly" out of the box. Now I got the RPi with the 8GB Memory card from here.


Could not be happyer with ModMyPi. Extremely Fast Order Processing and Shipping.


So a few things I noticed (or rather what I have done with it so far...)


I am basing this from Raspian by the way, It works fine so far.


Anyway the first thing ANY Linux user should do is the obligatory.....


sudo apt-get update
sudo apt-get upgrade


Self Explantory....


Next ....


There are a built in set of tools to do a few "Advanced things" by all means play around with the other settings, However there is a specific option to make available ALL the disk space. Run this on the command line...


sudo raspi-config


I installed a few monitoring tools of my own preference. 


sudo apt-get install rpi-update htop iftop iptraf


If you are running it as a headless server, This implies you have SSH access and your Pi is shoved behind a <<Insert generic place to put your Pi>> Especially if your using it as a low powered server and not the GUI for any Media Center Apps etc. 


Remove the following....


sudo apt-get remove aspell desktop-base desktop-file-utils dictionaries-common dillo fonts-droid fonts-freefont-ttf fontconfig fontconfig-config galculator gnome-icon-theme gnome-themes-standard gpicview gsettings-desktop-schemas gsfonts gsfonts-x11 hicolor-icon-theme leafpad lightdm lightdm-gtk-greeter lxappearance lxde lxde-common lxde-core lxde-icon-theme lxmenu-data midori mime-support openbox omxplayer penguinspuzzle x11-common wpagui python3 python3-minimal python-pygame x11-common

turn off the swap space, the SD card might be slower so we dont need to use that.


sudo apt-get purge dphys-swapfile dphys-config


THIS alone is worth its waiting gold, A DNS Based Ad Blocker. I highly recommend it and I highly recommend you donate to the author. Copy and paste this command directly. 


curl -L | bash


Update the RPI Firmware


sudo rpi-update


You should have a good basic system to do with whatever you want by now. 


Back up the System to an Image File so you can easily restore it. 


dd if=/dev/mmcblk0p1 of=/path/to/img/file/raspi.img bs=1M 

I installed transmission, Granted I mounted a USB hard drive to torrent from and to. But you can do whatever you like just be sure to mount it. These are the settings you need to change.

sudo apt-get install transmission-cli transmission-common transmission-daemon
sudo service transmission-daemon stop
sudo nano /var/lib/transmission-daemon/info/settings.json
*************Change the Following Settings***********

"rpc-whitelist": ",192.168.*.*",
(Optional) -----------------> "rpc-password": "{62b16db87b89a91dd49a5110a7cafc06d20eb4f2wtK6kqPj",
(Optional) -----------------> "rpc-username": "transmission",

sudo service transmission-daemon start
The default rpc-username and password is “transmission”
/var/lib/transmission-daemon/downloads/ <-------------------Default Downloads

Enjoy!! Please ask any questions below........



Link to comment
Share on other sites

A few tweaks to the CPU for the Pi....


root@raspberrypi:~# apt-get install cpufrequtils
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
The following NEW packages will be installed:
  cpufrequtils libcpufreq0
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 53.5 kB of archives.
After this operation, 274 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 jessie/main libcpufreq0 armhf 008-1 [12.9 kB]
Get:2 jessie/main cpufrequtils armhf 008-1 [40.6 kB]
Fetched 53.5 kB in 0s (72.0 kB/s)
Preconfiguring packages ...
Selecting previously unselected package libcpufreq0.
(Reading database ... 33671 files and directories currently installed.)
Preparing to unpack .../libcpufreq0_008-1_armhf.deb ...
Unpacking libcpufreq0 (008-1) ...
Selecting previously unselected package cpufrequtils.
Preparing to unpack .../cpufrequtils_008-1_armhf.deb ...
Unpacking cpufrequtils (008-1) ...
Processing triggers for man-db ( ...
Processing triggers for systemd (215-17+deb8u3) ...
Setting up libcpufreq0 (008-1) ...
Setting up cpufrequtils (008-1) ...
update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults
update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults
Processing triggers for libc-bin (2.19-18+deb8u3) ...
Processing triggers for systemd (215-17+deb8u3) ...
>>>>>>>>>>Installing Packages>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
root@raspberrypi:~# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors
conservative ondemand userspace powersave performance

>>>>>>>>>>Check what is available>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
nano /etc/default/cpufrequtils
# valid values: userspace conservative powersave ondemand performance
# get them from cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_available_governors 
GOVERNOR="performance" * Change this to what you want, See above. If the file does not exist. Save and Exit.
**************AFTER REBOOT CHECK*******************************************************

root@raspberrypi:/mnt/USBHDD# cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
********************************Benchmark It********************************************
root@raspberrypi:/sys/devices/system/cpu# time echo "scale=1500; 4*a(1)" | bc -l

real    0m6.785s
user    0m6.730s
sys     0m0.010s


More Information:

Link to comment
Share on other sites

Thanks!! I love the RPi and what it can be used for. Shame my Aluminium case got lost in the post so its literally just hanging by a network cable over a desk at the minute. :laugh:

Link to comment
Share on other sites

This topic is now closed to further replies.