Why I'm putting Ubuntu Server in Oracle VM

I'm learning to harden and monitor servers BEFORE I put a live TOR middle relay on a VPS. Oracle VM VirtualBox is my safe sandbox. If I break something here, no one gets hurt.

But VirtualBox has gremlins.

What are Oracle VM Gremlins?

Gremlins are the little state-loss bugs that happen when you shut down a VM the wrong way, boot it cold every time, or let VirtualBox lose its config.

If you don't contain them, they force you to reinvent the wheel every single time you start a VM:

  • SSH config resets or disappears
  • You have to re-select OpenSSH server in the installer
  • Network adapter goes from Bridged back to NAT
  • You sit through "Loading essential drivers" forever

Fix: Contain the gremlins. Don't do a full shutdown every time.

My 3 containment rules now:

  1. Save the configs - screenshot or copy your SSH config / netplan after it works
  2. Keep the machine in SAVED STATE - Machine > Close > Save the machine state, instead of Shut Down
  3. Keep snapshots of working VMs - Machine > Take Snapshot, right after a clean boot and SSH login works

Steps Taken to Mount the Ubuntu Server (Clean Start)

  1. Free up resources: Threw everyone off qBittorrent to free RAM/CPU for the Ubuntu boot. 900 DHT clients = hairdryer laptop.
  2. Snowflake proxy can stay on - it uses way less.
  3. Clean up: Removed any extra old ubuntu-*.iso files from Downloads folder to prevent confusion.
  4. Start Oracle VM VirtualBox as Administrator (Right-click > Run as administrator on Windows).
  5. Remove old not-working Ubuntu server from Oracle VM list - Right-click > Remove > Delete all files if prompted.
  6. Create new VM > Launch NOW!, hopefully 🫣

VM Settings That Help With Gremlins:

  • Type: Linux, Version: Ubuntu 64-bit
  • RAM: 2048 MB minimum
  • CPUs: 1 or 2 (more CPUs = more heat + soft lockups)
  • Network: Adapter1 - NAT Adapter2 -Host-only Adapter for SSH practice

Install Steps and Hiccups (and Solutions)

Hiccup 1: Laptop became a hairdryer
Normal. VirtualBox + Ubuntu update = 100% fan. Fix: Lift laptop on a book for airflow, plug in charger, let it cook.

Hiccup 2: Soft lockup - CPU# stuck for 41s
Message: watchdog: BUG: soft lockup - CPU#0 stuck for 41s!
What it is: VM froze because host was overwhelmed.
Fix: Wait 2 mins. If it repeats, Machine > Power Off > Power Off the machine, then Start again. It resumes.

Hiccup 3: Reboot failing after "Installation completed"
The installer says reboot but hangs.
Fix: Machine > Power Off > Power Off the machine. It's safe - install is already done.

Hiccup 4: Stuck on "Loading essential drivers..."
Should be 10 seconds, but hangs and heats up.
Fix: Machine > ACPI Shutdown. If it won't, Power Off. Next boot, disable 3D Acceleration in VM Settings > Display if it keeps happening.

Why This Ubuntu is Probably Gremlin-Proof

Because this time I saved the SSH correctly during install:

At the software selection screen, I made sure [X] was on OpenSSH server (Spacebar to select, not Enter).

Now the SSH server is baked into the install, not a temporary fix.

Lab Login - For My Lab Only (Not a public server):
Username: ubuntumelissa
Password: ubuntu123!

This is a local-only VM, so I'm keeping the simple password here so I remember it. I will NOT reuse this for the real VPS.

The Boot Bug Explained

What it does? VirtualBox + Ubuntu Server kernel sometimes fight over CPU timing on Windows hosts, especially with qBittorrent or high CPU load. It throws soft lockups and gets stuck on drivers.

How to fix it long-term:

  1. Give VM only 1 CPU in Settings > System > Processor
  2. Disable 3D Acceleration in Settings > Display
  3. Use Saved State, not Shut Down, every day
  4. Take a Snapshot named "WORKING-SSH-LOGIN-OK" right after you see ubuntumelissa login: for the first time.

Tomorrow's plan: Boot with charger plugged in, check if we get to login without gremlins.

19 blogs in 1.5 months. The troubleshooting IS the learning.t