What's (are) the funniest/stupidest way(s) you've broken your linux setup?

Tinkering is all fun and games, until it’s 4 am, your vision is blurry, and thinking straight becomes a non-option, or perhaps you just get overly confident, type something and press enter before considering the consequences of the command you’re about to execute… And then all you have is a kernel panic and one thought bouncing in your head: “damn, what did I expect to happen?”.

Off the top of my head I remember 2 of those. Both happened a while ago, so I don’t remember all the details, unfortunately.

For the warmup, removing PAM. I was trying to convert my artix install to a regular arch without reinstalling everything. Should be kinda simple: change repos, install systemd, uninstall dinit and it’s units, profit. Yet after doing just that I was left with some PAM errors… So, I Rdd-ed libpam instead of just using –overwrite. Needless to say, I had to search for live usb yet again.

And the one at least I find quite funny. After about a year of using arch I was considering myself a confident enough user, and it so happened that I wanted to install smth that was packaged for debian. A reasonable person would, perhaps, write a pkgbuild that would unpack the .deb and install it’s contents properly along with all the necessary dependencies. But not me, I installed dpkg. The package refused to either work or install complaining that the version of glibc was incorrect… So, I installed glibc from Debian’s repos. After a few seconds my poor PC probably spent staring in disbelief at the sheer stupidity of the meatbag behind the keyboard, I was met with a reboot, a kernel panic, and a need to find another PC to flash an archiso to a flash drive ('cause ofc I didn’t have one at the time).

Anyways, what are your stories?

jws_shadotak,

Not quite catastrophic but:

I’m in the process of switching my main server over from windows to Linux

I went with Deb 12 and it all works smoothly but I don’t have enough room to back up data to change the drive formats so they’re still NTFS. I was looking at my main media HDD and thought “oh, I’ll at least delete those windows partitions and leave the main partition intact.”

I found out the hard way that NTFS partitions can’t just reclaim space like that. It shuffles all the data when you change the partition. It’s currently 23 hours into the job and it’s 33% done.

I did this to reclaim 30 MB of space on a 14 TB drive.

avidamoeba,
@avidamoeba@lemmy.ca avatar

Tried to convert Ubuntu to Debian by replacing the repos in sources.list and apt dist-upgrading. 💣 Teenagers…

9488fcea02a9,

I didnt break anything, but there was this one time i was setting up a new lxc container i had just spun up. I installed nginx, and a bunch of other packages, started writing new config files… Then i noticed my prompt was user@desktop$ instead of user@server$

Whoops… I was in the wrong terminal window, typing commands into my desktop instead of the container i was setting up.

fl42v,

Oh, I just remembered another one or three. So, resizing the partitions. My install at the time had a swap partition that I didn’t need anymore. Should be simple, right? Remove the partition and the corresponding fstab entry, resize root, profit. Well, the superblock disagreed. Fortunately, I was lucky enough to be able to re-create the scheme as it was, and then take my time to read the wiki and do the procedure properly (e2fsck, resize2fs and all that stuff).

Some people I’ve met since, unfortunately, weren’t so lucky (as far as I remember, both tried to shrink and were past mkfs already) and had to reinstall. The moral is, one does simply mess with superblocks; read the wiki first!

glibg10b,

I wanted to use fio to benchmark my root drive. I had seen a tutorial saying that the file= parameter should point to the device file, so I pointed it at /dev/sda. As you might expect, the write test didn’t go so well.

krimson, (edited )
@krimson@feddit.nl avatar

Many many years ago I wanted to clean up my freshly installed Slackware system by removing old files.

find / -mtime +30 -exec rm -f {};

Bad idea.

SSUPII,

Debian sid a few years ago: Uninstalled Python2, system became unusable and couldn’t neither reinstall from APT neither recompile it

glibg10b, (edited )

Before installing Arch on a USB flash drive, I disabled ext4 journaling in order to reduce disk reads and writes, being fully aware of the implications (file corruption after unexpected power loss). I was confident that I would never have to pull the plug or the drive without issuing a normal shutdown first. Unfortunately, there was one possibility I hadn’t considered: sometimes, there’s that one service preventing your PC from turning off, and at that stage there’s no way to kill it (besides waiting for systemd to time out, but I was impatient).

So I pulled the plug. The system booted fine, but was missing some binaries. Unfortunately, I couldn’t use pacman to restore them because some of the files it relied on were also destroyed.

This was not the last time I went through this. Luckily I’ve learned my lesson by now

Kjev,
@Kjev@discuss.tchncs.de avatar

Somehow convinced a person to run sudo chmod -x /usr/bin/*

I don’t remember the exact command so it could be a bit different but it did the job. It was a fun evening.

avidamoeba, (edited )
@avidamoeba@lemmy.ca avatar

An intern nuked their workstation by sudo chmod -R 777 /. Turns out adding exec to everything isn’t good either.

fl42v,

Daaem, I guess the poor dude at the receiving end did not consider it particularly fun. Well, at least they had sbin working, so probably possible to recover without a live cd. Huh, guess who’s now spinning up a VM to check it out 🤣

captainjaneway,
@captainjaneway@lemmy.world avatar

Linux Mint: removed all taskbars from the desktop. I was hoping it would just allow me to reset them to the default. But in reality, it breaks the GUI and it’s very hard to reset from the GUI. Suddenly my keystrokes weren’t being detected and I couldn’t open up applications with any sort of regularity. After a lot of dicking around, I got the terminal working so I could reset Cinnamon.

It’s not the worst way I’ve broken a machine. But it was one of the most annoying.

d950,

When Ubuntu 16.04 had just been released, I tried upgrading my 14.04, the whole system broke and I had to install another os (Manjaro won).

That day I learned Ubuntu too can be a bit stupid.

Static_Rocket,
@Static_Rocket@lemmy.world avatar

This is where someone tracks down an upgrade path chart you didn’t know existed and points out some goofy intermediary release, not an lts for some reason, that you were supposed to upgrade to first…

jordanlund,
@jordanlund@lemmy.world avatar

Not me, but one I saw… dude used chmod to lock down permissions across the board… including root… including the chmod command.

“What do I do?”

🤔

“Re-install?”

fl42v,

Yeah, a very unfortunate one: probably, the most painful to recover from. I’d just reinstall, honesty 😅 At least with mine I could simply add the necessary stuff from chroot or pacstrap and not spend a metric ton of time tracking all the files with incorrect permissions

Kjev,
@Kjev@discuss.tchncs.de avatar

oh… uh…

cmnybo,

I managed to do that back when I was new. Luckily it was a fresh install, so I didn’t lose much when I had to reinstall.

So far, that has been the only time I really screwed something up outside of a virtual machine.

captainjaneway,
@captainjaneway@lemmy.world avatar

There’s got to be other tools though that could change the file permissions on chmod, right? Though I suppose you’d need permission to use them and/or download them.

fl42v,

You can dump the permissions from the working system and restore them. Quite useful when working with archives that don’t support those attributes or when you run random stuff from the web 😁

  • All
  • Subscribed
  • Moderated
  • Favorites
  • linux@lemmy.ml
  • localhost
  • All magazines
  • Loading…
    Loading the web debug toolbar…
    Attempt #