INC-001: I deleted my own home directory on a production server

While removing an old project, a pasted command lost its line breaks and turned into rm -rf on my entire home directory. I recovered SSH access by rescuing the boot volume through a second...

severity: SEV-1 | kind: outage | date: 2026-06-10 | duration: ~3h | status: RESOLVED

Impact

4 production apps for Prasad Academic (PIMS Evalu Pro, EaseExit, Elective Registration, Status Dashboard) lost their code and config; SSH access to the server was lost.

Summary

While removing an old project, a pasted command lost its line breaks and turned into rm -rf on my entire home directory. I recovered SSH access by rescuing the boot volume through a second instance, rebuilt every service, and hardened the server so a single typo can't do this again.

Timeline

Root cause

Pasting multi-line commands merged rm -rf ~/CCD-App-Backend and cd ~ into rm -rf ~/CCD-App-Backendcd ~. The trailing ~ was passed to rm as a second target, deleting everything inside /home/ubuntu — including all app code, .env files and .ssh/authorized_keys. No confirmation, no trash, no backup of home.

rm -rf ~/CCD-App-Backendcd ~

What didn't work

Resolution

Action items

Lesson

_Data in the database survived because it lived outside the home directory. Everything else survived because it was in Git. The only things truly lost were the things I never backed up: secrets and keys. Now those are backed up daily._

tags: oracle-cloud, linux, ssh, pm2, nginx, incident-response