TLDR
- Turned a Raspberry Pi 4 into a headless Ubuntu Server box.
- Pre-configured Wi-Fi and SSH so I can log in remotely from first boot.
- Added basic firewall rules plus auto Wi-Fi reconnect for resilience.
- Enabled kernel-panic auto-restart so the Pi recovers instead of hanging.
- This Pi is now my always-on base server for future tasks.
Task Requirements
I wanted a Raspberry Pi 4 running Ubuntu Server as a headless, always-on box, reachable over SSH without a monitor or keyboard. It needed to be up 24/7 on my network, ultimately with a fixed local IPv4 address, and hardened enough that it survives Wi-Fi drops or crashes without manual intervention.
Goal
The goal was to get a reliable, always-on Ubuntu Server running on the Pi that I can reach over SSH at any time, and treat as the base platform for later tasks, rather than trying to run specific apps straight away.
Implementation Steps
- Flashed Ubuntu Server onto a microSD card for the Raspberry Pi 4 using the imager tool, enabling headless setup from the start.
- Used the imager’s advanced options to pre-configure Wi-Fi credentials so the Pi connects to my network on first boot, and enabled SSH so I could log in remotely without a screen or keyboard.
- Booted the Pi headless, confirmed it joined the Wi-Fi, and connected via SSH from another machine to verify basic access.
- Added basic firewall rules to restrict incoming connections to what I actually need, tightening things up a bit from the default open state.
- Configured auto Wi-Fi reconnect so that if the wireless connection drops, the Pi will bring it back without me having to poke it.
- Enabled kernel-panic auto-restart so that if the Pi hits a kernel panic it will reboot itself instead of sitting there wedged and unreachable.
Notes & Decisions
The focus here was wiring and reliability rather than running any particular application yet. I deliberately kept the scope to getting a solid base server with network access and resilience, and leaned on ChatGPT for the hardening tweaks (firewall rules, reconnect behaviour, and kernel panic handling). This Pi is now the “always-on” node everything else can build on, so I cared more about it recovering from problems than about polishing any higher-level services.
Next Ideas / Follow-ups
- Configure and confirm a fixed local IPv4 address so the Pi is always reachable on the same IP.
- Actively test the resilience tweaks by simulating Wi-Fi drops and crashes to make sure it really comes back as expected.
- Decide and plan which services or apps to run on this Pi next, now that the base server is in place.