Sunday

19 April 2026 Vol 19

I didn’t buy a Raspberry Pi or mini PC — I used this instead for my home server

When you think of a home server, the usual suspects will come to mind. The Raspberry Pis, small NUC-style PCs, old laptops, have all long been wonderful devices to run a home server on. But if you those have them lying around, your phone might just fit the bill.

You see, running a full Linux desktop on your Android isn’t some technical wizardry anymore. It’s a matter of installing a couple of apps and running a few commands. And once you get to that Linux desktop, the line between a Linux PC and your phone will thin out real quick.

Linux running on a Pixel 9a connected to USB-C Hub.

Android’s Linux terminal is so good that I keep finding new reasons not to open my PC

I keep reaching for my phone, and it’s not for scrolling.

I skipped the usual home server hardware

Old Androids come with built-in battery, connectivity, and zero extra cost

Why would you run a home server on an old, likely under powered Android device you might have lying around when solutions like the Raspberry Pi are for anywhere between $30 to $100 on Amazon? That’s a fair question to ask. But the answer is also quite simple: because you already own it.

If you’ve got an old laptop or desktop lying around or you want to learn more about embedded systems by using a Raspberry Pi, by all means, go for it. They are ultimately a better solution considering they’re actually meant to run desktop Linux. However, in case you don’t already own them, they usually require shelling out money and then waiting on shipping to arrive. Not to mention that in the case of the Raspberry Pi, you’ll also need a display, keyboard, mouse, microSD card, and a power supply to get it all running. Suddenly, you’d be looking at a sizable bill.

Your phone, on the other hand, already has all of it. It’s likely got much more than 8 GB of space, a display, touch input, and a built-in battery. You’re not replacing Android on your phone either, and can always revert to regular Android if you need to use your phone as, well, a phone.

And if you’re wondering whether you can actually run anything useful on it, there are tons of things you can do with a Linux terminal on Android that regular apps can’t. Anything from running a Pi-hole instance for network-level ad blocking, a Copyparty instance for a file server, or even a Navidrome music server on an old Android is easily doable. If you’ve got the hardware, you can even self-host your own AFFiNE server and break away from Notion.

Linux on Android is easier than it sounds

A quick setup that turns your phone into a server

You don’t need to unlock the bootloader, root your phone or do anything flashy to install Linux. Android 16 now natively supports a Linux terminal, but if you want the full desktop experience, a combination of Termux and Termux X11 will take you a long way.

There are tons of install scripts available on GitHub that automate the setup process for you, so instead of installing individual tools, the distribution, and the XFCE desktop, you just run an installation script to install everything automatically. I used the Mobile HackLab script from jarvesusaram99 on GitHub. It installs everything you need, plus a bunch of extra utilities like Firefox, Wget, cURL, VS Code, and even Wine to get you started. It also has a rather friendly terminal interface that tells you exactly what’s going on.

Termux logo

OS

Android

Price model

Free, Open-source

Termux is an Android app that brings a full Linux terminal environment to your phone, letting you run command-line tools and packages natively.


In any case, installation is a simple matter of installing Termux and Termux X11 from their official GitHub repositories. Once installed, you’ll need to disable Android’s phantom process killer. This option is available in Android developer settings, generally as a Disable child process restrictions toggle. Once you’ve enabled it, restart your phone, and you’re good to go.

After your phone restarts, open Termux, and run the following command:

curl -sL https://raw.githubusercontent.com/jarvesusaram99/termux-hacklab/main/install.sh | bash

The command can take anywhere from 15 to 30 minutes, as claimed by the install script, depending on your phone’s processor and internet speed. The entire installation process took less than 10 minutes on my Pixel 9a, with some security tools unable to install.

Next, you need to run the Termux X11 app. Just open the app, minimize it, and head back to the Termux terminal. Once there, run the following command to start the desktop. Then, switch to the Termux X11 app and you should see the Linux desktop.

I would also strongly recommend using a USB-C dock to give your phone power and Ethernet connections. As you’ll start setting up server and hammering long commands in the terminal, you’ll also realize that a physical keyboard is a better option. A USB-C hub will let you add a keyboard, mouse, and even a bigger display to turn your phone into a proper Linux workstation.

Termux logo

OS

Android

Price model

Free, Open-source

Termux X11 is a companion app for Termux that provides a native X11 display server, letting you run full Linux GUI desktops and apps directly on Android without needing VNC.


Keeping Android from getting in the way

Tweaks to make it stable, predictable, and always on

Ubuntu on Android phone.
Image taken by Yadullah Abidi | No attribution required.

Android was designed as a phone OS, and considering you’re running your Linux installation on top of it, it’s going to keep trying to act like one. Thankfully, everything you need to change is already available in Android’s settings.

Before you go around tweaking Android settings however, you’ll need to run one more Termux command as soon as you start your session:

termux-wake-lock

You can also add it to your ~./bash_profile so it runs automatically on boot. This command prevents Android from putting your phone into deep sleep and throttling the Linux processes when its screen turns off.

Next, remove every app you don’t need, and restrict background activity for the ones you can’t uninstall or otherwise need on the phone. Just head to Settings > Apps > Battery usage and set every app to Restricted. Remember: every background process that you remove gives more hardware headroom for your Linux environment. Under Developer Options, you can also set the Background process limit to a fixed number — a setting that can make your old Android phone faster.

Last but not least, disable battery optimization for both Termux and Termux X11. The apps should automatically prompt you to do this, so you don’t even have to dig through your phone’s settings. Android’s battery management can be quite harsh on apps taking up too much power, and letting Termux run free ensures your Linux environment runs stable.

This setup is more capable than you’d expect

Old Android hardware still has plenty to give

You don’t need a mini PC, old computer, or Raspberry Pi to run a home server. Are these devices better equipped to host one? Yes they are. But if you don’t already own them, a seemingly obsolete Android phone will get you most of the way there depending on what you actually want to run.

Pixel 4a being used as a navigation device on bike.

I found the best way to reuse my old Android phone

Old Androids can be more than just e-waste.

It’s not the most glamorous setup, and it’s not the most powerful either. But it’s free, silent, doesn’t consume enough power to raise your electricity bill (in a meaningful way anyway), and can withstand power cuts courtesy of the built-in battery. More importantly, it’ll get you tinkering right away.

Source link

QkNews Argent

Leave a Reply

Your email address will not be published. Required fields are marked *