Live system - Whilst training
Did something very similar in late 80's - training on Unix and trained the hard way to create new accounts/directories etc ( editing /etc/passwd directly ) - demonstrated how to create homeless logons etc.
Finally, on last day of course we were introduced to "easy" way to add/delete users - aka helpful unix scripts adduser/deluser.
Thought I'd tidy up !!! So I duly run deluser on the homeless account created above.
Helpful script prompts "Are you sure you want to delete ?" (the spaces here are critical and are hiding a fatal flaw for those uninitiated in Unix)
Duly press Y and enter and wait patiently.
After a couple of seconds "rm not found" starts scrolling up the screen ????? Call over the trainer who promptly goes white.
Yup - deluser found no home directory and promptly issued rm -rf / <SIGH>
Full rebuild from scratch required - system unavailable to go live following week.
So not ALWAYS a noob error in scripting.