Initial Server Setup 🖥️
Welcome to the dark side of home servers… 🕶️
Section titled “Welcome to the dark side of home servers… 🕶️”They say curiosity killed the cat.
But in our case, it only killed some USB sticks, broke a few OS installs, and maybe destroyed your sanity.
Welcome aboard! 😈
This guide will walk you through setting up your home server with the required packages, updating all the existing packages, and additional configurations like setting up a static IP.
I’ll be using my Raspberry Pi 5. If you’re using a PC or laptop, feel free to skip the Raspberry Pi Setup section and jump right into the fun parts. Just make sure your PC is running Linux — preferably not Windows (unless you love pain). You can try it in a VM, go dual boot, or go full chaos mode and wipe everything for a fresh Linux install.
Go big or go home, right? 💣🐧
But why a Raspberry Pi ? Why Linux ? ⤴️
Prerequisites 📦
Section titled “Prerequisites 📦”- Raspberry Pi 5 with power supply (or a PC/laptop if you’re feeling rebellious)
- MicroSD card (32GB or larger)
- External storage (HDD/SSD) if you want to hoard files like a dragon
- Keyboard, monitor, and Ethernet/Wi-Fi for initial setup
1️⃣ Raspberry Pi Setup 🛠️
Section titled “1️⃣ Raspberry Pi Setup 🛠️”Steps to Follow
Section titled “Steps to Follow”-
Download Raspberry Pi Imager
Get it from here. Trust me, using random ISO torrents is a great way to get new “friends” (a.k.a. malware).
-
Flash the OS
Use the imager to flash Raspberry Pi OS (64-bit) onto your microSD card. While flashing, enable SSH in advanced settings.
-
First Boot
- Insert the microSD card, connect to a monitor and keyboard, and power it up.
- Follow on-screen setup. Pro tip: use Ethernet — Wi-Fi is like that friend who promises to help but always flakes.
-
Update your system
Terminal window sudo apt updatesudo apt upgrade -yWatch those packages update. It’s like watching paint dry but slightly more satisfying.
-
Install basic tools
Terminal window sudo apt install nala -y # APT’s glow-upsudo nala install openssh-server -y # SSH serversudo systemctl start sshsudo systemctl enable sshsudo systemctl status sshIf SSH fails, take a deep breath. And maybe a shot. Then check logs.
🤖 Automated Setup Script
Section titled “🤖 Automated Setup Script”If you want to save time (and avoid copy-pasting commands like a caveman), you can use the provided setup.sh
script.
curl -O https://raw.githubusercontent.com/deepesh611/Home-Server/main/setup.shchmod +x setup.sh./setup.sh
What it does
- Updates your system
- Installs
nala
if missing - Installs
btop
andopenssh-server
- Starts and enables SSH
- Logs everything to
/var/log/script_install.log
2️⃣ Assigning a Static IP 📡
Section titled “2️⃣ Assigning a Static IP 📡”Your server deserves a stable life. Floating IPs are for ghosts.
-
Find your gateway and MAC address
ifconfigipconfigNote your
default gateway IP
and your server’sMAC address
. -
Router time
-
Log into your router (usually via 192.168.x.1).
-
Navigate to DHCP or Static IP settings.
-
Reserve an IP for your server’s MAC address.
-
-
Reboot
sudo rebootYour server now sticks to one IP, like that friend who overstays their welcome.
3️⃣ Assigning a Local Domain Name (Optional) 🌐
Section titled “3️⃣ Assigning a Local Domain Name (Optional) 🌐”Make your life easier than typing IP addresses like it’s the 90s.
-
Router DNS settings
Find Static DNS options (mine lives under: Advanced > Applications > Static DNS).
-
Set domain
- E.g.,
server.local
- Point it to your static IP.
- E.g.,
-
Test
Terminal window ping <server-ip>ping <domain-name>If this fails, scream into the void — or fix your router settings.
4️⃣ Accessing Your Server 🛢️
Section titled “4️⃣ Accessing Your Server 🛢️”Connect from your PC/laptop:
ssh <username>@<ip-address-or-domain-name>
Default username is usually pi
or root
.
🎭 Conclusion
Section titled “🎭 Conclusion”Congrats, you now have a basic home server setup!
Soon you’ll be serving files, running containers, and telling your friends, “Yeah, I run a server at home,” while they stare in awe (or concern).
Check out the next sections for advanced guides — like adding external storage, deploying apps with Docker, or accidentally bricking your network and questioning your life choices.