You are about to buy a Raspberry Pi but you don't know what to buy and what to install later? It is not at all complicated and depends on your needs: with Raspberry it is possible to carry out many projects / use it in various ways:
- Use it as a normal PC Desktop (obviously don't expect awesome performance)
- Small home server (This could be one of the best uses - I have enabled the following services: HTTP, Samba, OpenVPN, CUPS, Sane - especially for CUPS [print server] is very convenient)
- Use it for various projects thanks to the GPIO module on the card
Note: now that the Raspberry Pi Zero has been released for a couple of months, many people ask themselves: "Is it convenient to buy it?"; my answer is NO, if you have to use it for anything that has nothing to do with electronics! It is useful for its very small size, and should be used for that. For other things it wouldn't make sense, you can't even connect it to the internet ...
Back to us
- MicroSD - Required for the installation of the operating system, I recommend at least 8 GB and also check the quality of the card (10 class ...), it must have a good read / write speed: Samsung MicroSD Class 10 EVO 16 GB (Amazon)
- Make sure you have a dedicated Raspberry charger (current 1A, voltage 5V), otherwise: WINGONEER Charger for mobile phones and Raspberry (5V, 2A)
- Case - Optional but recommended - Transparent case for RPi2 - we say that it is useful if it is not in a fixed position, for example, in my case that it is in a fixed position, I have placed a glass plate under the raspberry to avoid corrupting the tracks
- External storage (NAS Server): WD Blue 1TB 7200 RPM, SATA 3 -> USB
- External storage (*): Verbatim PinStripe 32GB
- You must (not necessarily) also purchase Mouse, keyboard, WiFi key if necessary: Keyboard, Mouse, WiFi key
Regarding the storage points, the HDD is necessary for those who want to configure a NAS with Samba or other service, and not necessary for other purposes. The pendrive is instead necessary for all other purposes, as the data will be written not on microsd but on the pendrive
The last point is not strictly necessary, as you can configure the raspberry with ssh, if the distribution you install is already set up, or you want to use it as a small server.
GNU / Linux distribution | FreeBSD
One of the most important points now is choosing the operating system / distro
- FreeBSD: Recommended for servers, light and very stable - FreeBSD / ARM / RPI
- ArchARM: FreeBSD alternative, "less" stable but very light - ArchARM / RPI
- Raspbian: Classical choice for general use (Specially Desktop) - Raspbian
- OpenELEC: Media Center with the Raspberry! - OpenELEC / RPI
These are the Linux distributions and the version of BSD I prefer, but eventually there are many more!
DE / WM, DM
- DE / WM: Xfce4, LXQt / i3wm, awesome - very light environments and window managers
- DM: LXDM, SLiM / Login console - Light Display Managers, eventually it is possible to access Xorg directly from the login shell
As for external storage, you can automount them using / etc / fstab - Debian Wiki: it / Fstab
Server Stack (HTTP)
- OS: Linux / FreeBSD
- Webserver: Nginx / Lighttpd
- SQL Database: Postgre
- Interpreter: it depends on your choices! (php, python, ruby: they are the main ones)
IP filtering: iptables, SSH security
I highly recommend modifying the iptables rules (Linux): IPTables | InTheBit, with iptables it is however possible to block, limit accesses and create other fundamental rules for security.
As for SSH - OpenSSH and JuiceSSH | InTheBit - security measures can be taken such as limiting concurrent access, attempts limits, blocking the root account and / or certain accounts, with iptables it is possible to deny access to certain IPs, block X Forward and transfer sshfs files and much more. Refer to the file
/ Etc / ssh / sshd_config
is well commented and is not difficult to read (just chew a little bit of English).
It is possible to execute commands to the Raspberry every tot. time: