Some Bits: Nelson's log

Server outage postmortem

Some notes on a personal server outage. Highlights:

  • Smart power switches are great
  • Would love a remote console of some sort
  • Having any sort of remote shell other than the server would be nice
  • Remote Unifi is helpful
  • My Intel ethernet device / e1000e driver may have a bug
  • A second network interface?
  • I’d sure like a watchdog

I left San Francisco on the morning of Apr 18. At 2:38AM Apr 19 I got notified some of my services running on my personal Linux server there weren’t working. No problem, I thought! This is what Proxmox is for! Only I couldn’t reach the Proxmox hypervisor: the whole machine was down.

Long story short, today (Apr 22) I power-cycled the machine and it came back fine.

Smart power switch

My first thought on the 19th was to reboot the server. Then I went looking for the smart power switch I thought I’d set up and couldn’t find it. I have like 4 brands of switches and apps. And I forgot to check Emporia, the newest one. Mostly that’s my car charger but they have a nice set of smart power switches too. I finally found it this morning (while looking at a list of devices on my LAN), power cycled the machine, and the reboot worked. Yay!

Remote console

I’d sure love a remote console for this server. Something I can log into remotely. I’ve got another blog post coming on options for that, I think PiKVM might be my solution. Next time I buy a server I should buy something like an HPE Proliant with remote management.

Remote Unifi

My Ubiquiti router has remote management with a web interface. I’ve used this more than I thought I would. I used it on the 19th the moment I knew things were wrong. It let me confirm the house Internet was working and that the Proxmox host was no longer on my LAN.

Remote shell

Usually when things go wrong and I’m not home I log into a VM on my server and poke around with diagnostic tools. But with my server down I had no VM to log into. Kinda wish I had a second machine, a little RPi or something. I finally figured out you can get a remote ssh shell on the router via the Unifi console. The Linux environment you get there is very limited but at least I could run ping.

Second network

I should consider adding a second network device, a cheap WiFi adapter, just as a backup. Would be nice to bypass the ethernet switches too.

Watchdog

The root cause of the failure was the networking going down. It’d be nice if my Proxmox server had a watchdog to reboot itself. In this case the computer was fine, just not the network, so that’s a little trickier. In the past every time I’ve set up watchdogs it caused more problems than it solved. The real Proxmox solution is to cluster and use high availability, but I don’t really want to buy more computers.

Root cause / ethernet problem

So why’d it crash? I’m not certain, but here’s the big sign of trouble

Apr 19 09:06:59 sfpve kernel: e1000e 0000:00:1f.6 eno1: Detected Hardware Unit Hang:

That got logged once every two seconds once it started. tailscaled also started complaining it couldn’t connect to the network. Everything else more or less kept running fine, scheduled tasks and backups and stuff. Just no network.

Looking at my logs, this error message has been logged about 150 times in the past year and a half. But in previous times it’s been transitory, a few errors and then it recovers itself without a reboot. This last outage was the first time where it got stuck and didn’t reboot.

Looking online, this error is frequently asked about. I don’t have the stamina to read all the diagnoses of what might be wrong. I did ask some AIs though. The usual cargo cult advice is to do something like ethtool -K eno1 gso off tso off to disable various advanced ethernet device features like hardware supported checksums or segmentation. Also some thought that power management might be a problem. Kind of hate the idea of this. I thought Intel ethernet devices were well regarded and supported in Linux.

I updated Proxmox from 8.3.? to 8.4.1 a few days before this crash. If it happens again it might be a problem with this kernel (6.8.12-9-pve).

Updates

The server crashed again the same way last night at about the same time.

Apr 23 09:08:37 sfpve kernel: e1000e 0000:00:1f.6 eno1: Detected Hardware Unit Hang:

This is happening during the 2am busy cron job window, so it’s possible there’s system load involved. There’s a big backup job running of my primary VM which takes about 8 minutes. The backup does complete! And I’d hope it doesn’t generate network traffic. But who knows. FWIW I was able to run the backup job manually without causing a problem.

After that Apr 23 crash I turned off GSO and TSO and it hasn’t crashed the last two nights. Given the code I’ve read, I’m guessing segmentation is in fact the problem.

I’ve got a separate blog post just about this kernel problem.

Apr 29: got a crash late last night with GSO and TSO turned off. At 04:52:56 UTC (about 10pm local), so a few hours earlier than the previous crashes. So turning those features off helped but didn’t solve the problem. Going to try turning off many more options as in this unit file and see how I do. But still a one-off, I keep hoping Proxmox releases a fixed kernel.
/sbin/ethtool -K eno1 gso off gro off tso off tx off rx off rxvlan off txvlan off sg off