Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Repurposing my old Chromebook to a low power home server (tamas.dev)
109 points by boros2me on Sept 28, 2020 | hide | past | favorite | 80 comments


This list isn't so much repurposing a chromebook for a home server as setting up a complex work environment on a chromebook. I hope it doesn't discourage people from just running a simple webserver on their extra computers.

It's pretty much just 'apt-get install nginx' and a port forward on your router for ubuntu-flavors, isn't it? All that extra software setup for managing container and databases for monitoring and visually displaying logs, the extra software for dealing with the bandwidth that comes with containers, etc, doesn't have meaning or use in this context. He doesn't even actually mention which webserver he uses. It's all meta and no server.


Harsh but fair. If he had explained that he wanted to get more experience playing with Docker and other fancy toys then he could have won you over. Getting Docker to work on a 2Gb/16Gb Celeron Chromebook with a cheap USB stick is a fair technical challenge.

But you are right though. You can apt-get install nginx on Gallium to run many things. Fair use cases include an OwnCloud, a media server, a home security gizmo using the microphone and camera, a personal website and much else that could be done. It would be great to run these things and it be next to no power with a refurbished/recycled machine.

Or you could run Virtualbox to host another flavour of Linux so you can host Docker and use that to test your installation, no actual apps or real work done at all.


It's pretty much just 'apt-get install nginx' and a port forward on your router

Isn't this what leads to home networks being cracked and added to botnets (or your webcams broadcast to the public)?

If you aren't willing to commit to good sysadmin practices like doing regular patches and segmenting off the public webserver from the rest of your network, you're pretty much guaranteeing that you're going to get hacked some day. Auto updates can help, but if you're not actively monitoring, some day an update is going to fail to apply due to a package conflict and you're going to remain unpatched.

If all you need is a simple webserver, you're better off letting someone else host it.


No. nginx remote exploits are extremely few and far between. Hosting a static site made out of html pages and actual files in directories is incredibly low risk and requires no maintainance or particular security knowledge.

If all you need is a simple webserver it's best to host it yourself. If you need anything more you're better off letting someone else host it.


I use Asus EeePC subnotebooks for that. They're about US$30-$50 on eBay, and there are models with 64-bit CPUs. I run the CPU and disk test, wipe the disk, and install XUbuntu. A few script mods make the device stay on when the lid is closed, but the screen turns off.

It's more convenient than packaging up a Raspberry PI. You get keyboard, screen, disk, power supply, and battery, plus some USB ports, in one compact unit.


Don't forget the extra USB ports and SD card slot. Some Chromebooks and the older RPis have only two USB ports.

If you run NetBSD, you will not have to disable anything for the device to stay on when the lid is closed.


But doesn't that use way more power than a pi? And weren't they also slow AF?

I remember I had a celeron notebook from 2011 and it was slow back then even with an SSD. I gave up on the idea that it would be an efficient always-on server.


Probably slower too. Depending on the model of CPU. Those early 32-bit Atoms were soooooo slow!


I disagree, a 10yr old laptop, that was designed to be bargain bin parts, for a now dead niche of netbooks, that has 10yr old parts can't compete with a pi4 for $30 ($50 nicely equipped w/ case and SD card) or a pi nano.

It's not even close.

The LCD, battery and I/O keyboard/mouse/usb are nice but, no hdmi, just VGA...

It makes sense if it's Free but even then, the pi simplifies this so much and then you have no moving parts.


Netbook has SATA and nice enclosure for hard drive. But the main reason is reuse.


RP4 has UASP, you can buy a SATA hat, and you can put it in a box with your drive if you don't want to look at it.

I have some netbooks lying around and I'd still prefer to buy an RP4 for little projects here and there. Reuse be damned I guess. For me, the main reasons to go with RP4 are gigabit ethernet, less power draw, less need for noisy fans, and a large community.


That would add $43.00 and $56 for the aluminium case though you'd have 4 SATA. Or start with external USB drive use 3d printing or duct tape to make DIY case.

I can't imagine Raspberry Pi community is bigger than Linux users on laptop and desktop. And how can one separate?

On a plus side of Raspberry Pi I would add GPIO with PWM, SPI, I2C and Serial.


Oh man, I forgot about EeePCs... I had one of those in ~2010. 32-bit with 1GB of ram and a single 1GHz CPU IIRC. 10" display. Good times.


My raspberry pi 4 has been running as a home server and gitlab runner under my tv stand for a few months now and works great! I just need to set up a backup scheme at some point since the whole thing runs on an sd card.

It seems easier than ever to repurpose old hardware for home servers with docker and all the great projects out there!


My main gripe about the Raspberry Pi is the SD card unreliability. I know you can boot from USB now but I wish there was a way to integrate an SSD directly on the board (something in the m.2 2242 form.factor) to make it more resilient and also faster.

I'll probably go with a small NUC or something like that instead, especially if there's some AMD Ryzen systems coming out in that form factor.


Yeah I agree about sd card reliability concerns. The funny thing is that I've used as cards as data storage inside gun launched munitions (Howitzers!) And they survived 10,000 G of acceleration, but too many writes is a problem!

I use a mounted usb drive for logging and storage so hopefully that helps the sd card stay fresh.


> The funny thing is that I've used sd cards as data storage inside gun launched munitions (Howitzers!) And they survived 10,000 G of acceleration

In the name of countless fellow HNers, tell us more right now!


I'm assuming those were industrial cards? A previous employer would stick them in enclosures next to high power motors for decades at a time without issue. Expensive as hell, but damn were they reliable.


No they were normal off the shelf cards, but they were soldered directly on to the PCB and everything was vacuum potted.


Have a look at the Dell Optiplex Micro line - I just picked up one of these. Sips power, ultra quiet. Runs ESXI with no issues. https://www.amazon.com/Dell-Optiplex-i5-8600T-802-11ac-Bluet...


Yeah those are great. I think they're over-priced for most home hacking applications, but you can find older models for much cheaper at Woot.com: https://computers.woot.com/offers/dell-optiplex-3040-micro-i...



But this (naturally) goes over USB, too. So you're wasting bandwidth (and money).


USB isn't a big issue if UASP is supported.

EG 149MB/s on dd writes.

See https://www.jeffgeerling.com/blog/2020/uasp-makes-raspberry-...


> especially if there's some AMD Ryzen systems

The Asus PN50 with Ryzen 4000U series APUs is starting to become available in the US and other countries. Zen2, laptop chips. Tiny computers: 1.93" x 4.50" x 4.50" (or 4.9cm x 11.5cm x 11.5cm). I don't have experience with these, but they were on my list before I decided to go a little bigger and get the desktop APUs in the same series whenever they start shipping to the US.


I don't want to start an argument, but for what it's worth RISC is a bit more energy efficient and the Pi is quite a bit cheaper.


Sure, RISC is more energy efficient, that's why AMD and Intel are microops behind an x86 decoder :p

A ryzen is a lot more capable than a Pi, and sometimes that's worth the material and power cost. Mostly, I was just pointing out that there are some systems out there to buy if you want though.


Look into rk3399 boards. They have m.2 add-ons that connect to the PCI-E lane on the board.

https://www.pine64.org/rockpro64/

https://libre.computer/products/boards/roc-rk3399-pc/


That, and also I really want a protected power input jack that isn't a USB jack. Like a good locking 2-pin Molex Micro-Fit connector, or 2-pin JST-EH, XT30, or some other low profile locking or tight-fitting connector would be great.

I'm tired of having to power the Pi over the expansion header while people keep saying "don't do that because you bypass the power protection" well no shit but there isn't any other option if I don't want to use USB.


Just out of curiosity, why not use the USB?


Unreliable for moving robots, not locking, easy to snap off the board, PITA to strip USB-C cables, break out the +5V/GND wires to splice to a DC-DC converter (and the breakout boards take much more space than just a proper power jack).

95% of the time I power Pi with DC-DCs, not from a wall source. (But even for a wall source, it's way way way easier to find 5V3A, 5V5A, even 5V10A adapters that give you nice, easy to use +5V/GND terminals or wires than it is to find a USB wall wart that can deliver enough current for the Pi 4.)

In general, I want a power connector for power when integrating the Pi into a larger device.


> My main gripe about the Raspberry Pi is the SD card unreliability.

It's a very real issue. I managed to burn out a SD card that wasn't even being used, i.e. only the /boot partition was on the SD card, and it pointed at an external drive for the root. Presumably that means the heat alone of being connected to a Pi was enough to burn out the card.


Seeed have a nice looking range of x86 for this type of application: https://www.seeedstudio.com/ODYSSEY-c-1492.html


What about using high endurance SD cards, like the ones used on dashcams? They're can be more than twice as expensive but I haven't had one failing on me yet.


I seem to recall some one (Argon) has just launched a case for that Pi plus an m.2


Yeah, I have a Pi 4 as a home server.

I had it connected to a UPS that went bad, and that trashed the bootloader/firmware on the Pi.

I had to reflash, and it works, but I have also had two 2.5” usb3 drives die in the last month (I had a independently powered usb3 hub attached).

If you care about your files and time, have a working backup strategy in place.


Raspberry Pi is great but for some applications it is too small. It becomes more cables than computer so to say, does not stay put. A larger and heavier computer is my preference then .


> I just need to set up a backup scheme at some point since the whole thing runs on an sd card.

OT: In my experience "set up a backup at some point" all too quickly becomes "shit, I _knew_ I needed a backup".


I use netbook as wifi router [1] / storage (sshfs, samba). To disable sleep on lid close [2]

    /etc/systemd/logind.conf
    HandleLidSwitch=ignore
Never thought of it as UPS, probably can implement graceful shutdown on low battery level [3]

[1] https://wiki.archlinux.org/index.php/software_access_point

[2] https://wiki.archlinux.org/index.php/Power_management#ACPI_e...

[3] https://wiki.archlinux.org/index.php/laptop#Hibernate_on_low...


One reason to do this is because, fan-less intel Celeron Chromebooks are the most accessible x86 Single Board Computer(SBC) currently available.

If you have a x86 specific workflow, then there are not much choices out there at such low power/price scale e.g. I used one for running a Chromium puppeteer task, as Chromium was nearly unusable in similar or better specced ARM SBCs running Linux.

But that's a one-off example, for almost every headless application an ARM SBC like Raspberry Pi makes more sense.


Is that because Chromium isn't as optimized for ARM as it is for x86? Or is it just because the ARM SBCs are lower speed cores? Curious to know more specifically


I believe believe both to be the reason, but I'm of opinion that optimization issue for ARM contributes more to this problem than lack of power.

Chromebooks ditching ARM seems to add credibility to my suspicion, in spite of ARM chromebooks being more favourable to run Android apps.


One thing to keep in mind: support for running generic Linux on anything past Braswell (so, 2016 or so) in a Chromebook is pretty much impossible - the replacement firmware doesnt exist, or has major issues like not supporting suspend/resume. Most Apollo Lake and newer Chromebooks support running Debian in a VM inside ChromeOS though - there is quite a bit you can do this way.


That's a shame, anyways Crostini has improved a lot, I tested the same workflow mentioned in parent and had no specific issues. But there's no USB-passthrough yet and so using Bluetooth or other USB dependent hardware isn't possible in Crostini yet.


"[...]especially knowing it can run on batteries for 10 hours (allegedly), without having a UPS."

In my experience of trying the same, this is a swollen Li-Ion battery waiting to happen.


Given that the monitor is a big part of power draw, it will probably last longer than that with the lid closed. Of course if you lose power, you probably lose the wifi router it's connected to anyway.


I bought a few cheapo UPS units one time. They're only 2-prong (no ground) and the capacity is low. But they were like $20 each with "refurbished" batteries from the vendor.

All of my routers are 2-prong so I have one unit for every router/switch/AP in my house. Actually really helpful and if I was running a Chromebook for a server like this, I could keep my services accessible remotely even if a short power outage happened!


There are kernel modules to float charge at 80% (or any %) and not stress the battery.


Is there a generic way to do it now, or is it still hardware-specific? (Last time I looked I was on a thinkpad and using tp_smapi)


So unplug it ever few days for an hour?


I don't know if it works on chromebook hardware, but some laptops let you manually control whether/when the battery is charging, ex. https://unix.stackexchange.com/questions/48534/how-to-adjust...


Or use a timer, 0.5 h every night?


Yep, it is fire hazard.


Everything with a lithium ion battery is a potential fire hazard.


I have an ancient Thinkpad X200s with a cracked screen. For years it's been my favorite go-to home server running Linux + Docker. :P


Seconding this. X200/210/220 are dirt cheap, come with modern CPUs, cooling fans (!), quality Ethernet ports and run x86-64 containers unmodified. You can cram 16GB of RAM and SATA SSDs into an X220.

Much less hassle and similar price to an RPi.


Please don't use the X220 or T420 for servers though.. They're the go-to main laptops for many Thinkpad fans because they're so inexpensive and very well-built for everyday use. There are only so many left. I can't imagine using another laptop besides my T420, I'm not sure a better laptop exists and I'm gonna have to take it to my grave if Lenovo doesn't get their act together and release another Thinkpad with a full keyboard.

That being said, good computers going to good people for them is always a good thing no matter the use case.


T430 is fine too, its my daily driver and has the same charger as the T420.

I run SmartOS on another t430 with a cracked screen which has a bunch of guest KVM and zones. Runs ZFS in a mirror and 16G ram, backed by an APC unit for the modem router.

I blogged recently about my setup here:

https://russell.ballestrini.net/weechat-on-boot-in-a-tmux-se...

(Hosted on said laptop)


Where the hell is a X200 is similarly priced to a RPi?!

In my neck o the woods(Austria) a X200 series is around 150-200 Euros. Add 16GB of Ram and an SSD an you're looking at at least 250 Euros instead of just 40 for a PI.


My beef with the Pi is that it's not just EUR40 for the device; you also need to add on:

- power supply

- quality SD card

- heatsinks

- a case

and then deal with

- non-x86

- thermal issues

- SD cards

- the CPU is too tiny to do anything useful anyway

Sorry to hear that X2x0 is expensive where you live. I find that the small additional investment over the RPi is worthwhile.


Ha. My home server for a very long time was a RPi 3B+. Totally fine for all kinds of background home server-y tasks, including running a local jupyter server for one-off calculations. (When I need a lot of cpu for something, I probably need a beefy gpu, which is a whole other beast.)

Power supply: It's USB powered. For a home server, I find it convenient to plug it into a USB port on the router, to which it is also connected for ethernet.

SDCard: It was set up to only use the sdcard to boot and use a USB stick as root, which gets around all of the sdcard issues. This is not a totally plug-and-play experience, though. My understanding is that the newer firmwares finally allow direct boot from USB, though.

Case: You can DIY it easily. The case for my home server was basically a folded piece of cardstock on which I drew a picture of a once-bitten pear. Other times I've used legos or dremel tooled altoid tins.

Heat sink: Unnecessary prior to the Pi4. (which also ramped up the cpu and power usage quite a bit...) They keep producing the older models, so it's mainly a matter of picking where you want to live on the compute vs heat management scale.


You forgot to add the extra power consumption of a laptop vs a pi. It adds up.


You do?

Heatsink and case were totally optional in my experience (or a case would make thermals worse). Power supply maybe, if your phone charger did not already work. SD Card or flashdrive; I have many of these lying around.

There is something to be said for having keyboard, pointing device and screen included with a used laptop, but the stuff you list it seems you just don't actually need.


Curious what workloads you're intending to run on the RPI that you find the CPU is tiny.

Granted, the RPi2 had a slow CPU, but I am finding the RPi4 is snappy enough for "serve a website out of a docker container" workloads. I am hitting SD card I/O limits faster than I hit CPU limits.


I use a Lenovo M series Tiny for this. I have a fanless celeron unit running devuan.


ServeTheHome has been doing a ProjectMiniMicro on testing out different second hand ~1L sized mini-pcs. The series starts with a fairly unimpressive old Dell unit & some background. Matches a lot of what I've been doing at home.

https://www.servethehome.com/introducing-project-tinyminimic...

I do like the idea of getting a free battery back-up &built-in crash cart for my server. On the other hand, a lot of these mini-pc's have much more powerful cores & more expandability, typically both an m.2 nvme slot and a 2.5" sata, two so-dimms, and a lot more video & usb out.


I ran a thinkpad T61 as a server for a bit. It’s a decent solution and yes it has a built in UPS :)

Really these big clusters rarely need to be run 24/7 so it’s more economical to run one node doing stuff that has to be on all the time. Everything else I run in virtualbox on my desktop which is a fairly hefty Ryzen which gets turned off when I don’t need it.

I will replace my Lenovo M series with a VPS node when someone does one that Devuan works on.


I did this with an old phone with broken screen! Put in an SD card and it runs Resilio Sync (you could also run Syncthing). Works very well, and it sips power.


I have a working Chromebook with a broken screen. Sure would be nice to put it to work! Loved that little machine when it was working, perfect for the kids and to take to client meetings (all day battery). It's now in storage, because paying to fix a screen on a $200-something computer doesn't make sense.


When I end up with old hardware that I don't want to fix or re-purpose, I tend to put it on an ebay auction for $0.99 + shipping (or whatever), and hope that someone else can get some additional life out of it.


Good idea, although I'm not wild about selling a Chromebook I can't access but previously had signed into my Google accounts to some stranger.


You should be able to de-authorize it from any working Google login on another device - the security page shows all of your other Google sessions, and you can kill any of them. It even nags you to kill ones that haven't been used in over a month or so. Seems to be even more effective than logging out on the device, though that's probably a good idea too if you can.


Can you use an external display? Some chromebooks have hdmi out, and you might be able to use adapters for others?


Yeah, I suppose that's a reasonable concern in this case.


Do most of these Chromebooks have the SSD soldered onto the SoC? Or, are they replaceable?

My use case would be similar to this, but also to serve as a lightweight local backup server (never accessed, unless laptop and iCloud backups fail). One 500gb SSD would be sufficient for my use.


Yes, you're right, most of them do. Most of the Chromebox's don't though. They typically allow memory and disk upgrades, and they are quite cheap on the used market. The ASUS CN60 is popular. https://www.ebay.com/itm/Asus-Chromebox-CN60-Intel-Celeron-2... ($30, buy it now)


You could put the SSD in an external USB enclosure, I've had luck with that strategy for "spinning rust" external drives.


My old chromebook is being repurposed as a chromebook. My daughter's school has asked kids to bring computers to class this year. Mostly for Google classroom usage between remote and in person days. We still have the 11" Acer I got her 5 years ago for $170 and it still runs ok. I taped over the cracks in the case and now she has a great tabeltop device and if she loses it, I don't care.


My only main problem with this setup is that you are essentially limited with available mini PCI-E slot, since there's no additional sata port to add.

You could probably find one with dvd-drive slot and swap it with HDD caddy.


tldr: Install Gallium OS (AKA Ubuntu) and run arbitrary server




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: