Blog · A home network run like a small office

Bringing the media server back, and keeping it up

It had been off for weeks. Now it starts itself, and the PC it runs on is locked down.

In this series · Chapter 5, The media serverShow all 49 partsHide the list

1. Where it started

  1. 01Why I'm running my home like a small office
  2. 02What a read-only audit of my network found
  3. 03The first changes, and the ones I said no to
  4. 04Reuse first, build only what's missing
  5. 05Fifteen decisions before the first line of code

2. Remote access and keys

  1. 06One way in from outside
  2. 07An address that keeps itself up to date
  3. 08Where the passwords live
  4. 09Keys that can do one thing

3. Monitoring

  1. 10Is it my network or the internet provider?
  2. 11A watcher outside the house, and backups I've restored
  3. 12The drill that found the bug
  4. 13Alerts that only reach my phone when something needs me
  5. 14I had the monitor audit itself
  6. 15Teaching the hub to stop crying wolf

4. The network redesign

  1. 16"Don't take down my internet": the routine before every change
  2. 17The firewall upgrade, two days late
  3. 18Keeping the plan when the builder wanted to drop it
  4. 19Two Wi-Fi drops, and knowing when to stop
  5. 20The router at 90 percent
  6. 21Moving 40 gadgets without touching each one

5. The media server

  1. 22Bringing the media server back, and keeping it up
  2. 23The movie that stuttered on one TV

6. The control center

  1. 24An overnight prototype, and bars instead of dials
  2. 25A nice hub, tucked away in a drawer
  3. 26Instructions for a phone I don't own
  4. 27Three checks before anything goes live
  5. 28Buttons with a seatbelt
  6. 29Rewind: replaying a Wi-Fi outage
  7. 30"I just want a more sensible layout"

7. Security

  1. 31A security scoreboard that started at a D
  2. 32Who's knocking: a security tab in two evenings
  3. 33Matching every program to the public flaw lists
  4. 34A DNS log for the house
  5. 35A weekly scan that can't annoy anyone
  6. 36The week of the scary flaw list

8. A private AI assistant

  1. 37A private AI for the house that can't touch anything

9. How the work got done

  1. 38Keeping a non-developer in charge
  2. 39A house manual that rebuilds itself every night
  3. 40My AI assistant keeps blocking itself, and I'm glad
  4. 41What it cost, what's next, and what I'd bring to an office

10. After the rebuild

  1. 42The backup that filled its own disk
  2. 43Two messages, one second, wrong order
  3. 44My help tool said "fine" at 7 megabits

11. Groceries

  1. 45Reading our grocery orders until the store locked us out
  2. 46I was testing a cart button when I found out nobody wanted one
  3. 47My first grocery rule would have nearly doubled what we buy
  4. 48The third store was the cheapest on nothing
  5. 49The house AI's only grocery job is picking a picture

The house has a media server that streams our own library to the TVs in the house. When this project started, it had been unplugged for weeks. Bringing it back turned into a small lesson in making a service run itself.

It only ran when someone was signed in

When I switched the PC back on, the media server didn't answer. It turned out it only started when someone signed in to the PC. After a power cut or an update restart, it stayed off until someone noticed.

The fix was a small watchdog task. It starts the server when the PC boots, then checks every 5 minutes and starts it only if it isn't already running. To test it, the assistant stopped the server hard at 11:37. At 11:41 it was back, and exactly one copy was running.

"Exactly one" mattered. A day earlier, I'd accidentally started a second copy by clicking the old desktop shortcut. That shortcut moved somewhere I wouldn't click it.

Locking down the PC

The PC that runs the media server also hosts the hub, so it needed the same care as a server in an office. In one evening:

  • File shares that exposed whole drives were removed, after confirming nobody was using them.
  • A support app the manufacturer had preinstalled was uninstalled, which also freed up memory.
  • The PC's firewall was switched on for every network type, and remote desktop was limited to a short list of machines.
  • Two-step sign-in was turned on for the media server account.

The biggest find was a setting in the media server itself. It had given every device on the home network owner-level access, with no sign-in. Clearing it meant that requests without a sign-in were refused, which is how it should have been all along.

Streaming over a small upload

Upload is the small side of a home connection, and the media server alone could fill it. So any stream that leaves the house, even to a device on my VPN, is capped at 12 Mbps, with 30 Mbps in total. About 11 percent of the library, 143 of 1,254 items, is over 12 Mbps, so those get converted on the fly to fit.

There was one surprise. When the gadget network went in, TVs on it would have counted as remote too. The assistant set the media server's list of home networks so TVs on any house network count as local.

For context: upload bursts sometimes reach 45 Mbps, a little over the plan, but over a week the house uploaded 126 GB, an average of only about 1.7 Mbps. Upload is fine most of the time and tight in bursts, and a burst is exactly when a stream stutters.

Where it ended up

It starts on its own now, gets checked every 5 minutes, and runs as exactly one copy. If you're doing the same, look for settings that trust everything on the local network too. "It's inside the building" isn't a security policy.

Have something in mind?

Tell me what you're trying to do. I reply within two business days.

Get in touch