this post was submitted on 22 Jan 2024
29 points (93.9% liked)

Linux

47290 readers
783 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

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?

top 50 comments
sorted by: hot top controversial new old
[–] [email protected] 4 points 7 months ago* (last edited 7 months ago) (1 children)
[–] [email protected] 2 points 7 months ago

Been there, done that

[–] [email protected] 3 points 7 months ago

rm -rf /var

I don't know what I was thinking on to type it 😅

[–] [email protected] 5 points 7 months ago* (last edited 7 months ago)

Not really a "braking my linux setup", but still fun as hell! Back in university, a friend of mine got a new notebook at a time... we spent the night at the university hacking and they wanted to set the notebook up in the evening. They got to the point where they had to setup luks via the cryptsetup CLI. But they got stuck, it just wouldn't work. They tried for HOURS to debug why cryptsetup didn't let them setup LUKS on the drive.

At some point, in the middle of the night (literally something like 2 in the morning) they suddenly JUMPED from their seat and screamed "TYPE UPPERCASE 'YES' - FUCK!!!"

They debugged for about six hours and the conclusion was that cryptsetup asks "If you are sure you want to overwrite, type uppercase 'yes'". ... and they typed lowercase. For six hours. Literally.

The room was on the floor, holding their stomach laughing.

[–] [email protected] 6 points 7 months ago (1 children)

Accidentally executed a JPEG (on an NTFS partition) and the shell started going crazy. reboot was not successful =[

[–] [email protected] 3 points 7 months ago (1 children)

Bro and it does not give any format error or anything?

[–] [email protected] 3 points 7 months ago (1 children)

Nope, I guess the processor just skips bad instructions, or most numbers are valid....

[–] [email protected] 4 points 7 months ago

New fear unlocked

[–] [email protected] 3 points 7 months ago

Renaming a mount point while mounted was a fun experience in losing data back in the big box Redhat 5.0 days.

[–] [email protected] 4 points 7 months ago* (last edited 7 months ago)

The only time was within a VM. I accidentally wrote

rm -rf ./* while my cwd was /

I use absolute paths with -rf now, to prevent the error again.

Every other breakage I had was with apt shitting itself. It has always been fixable just annoying.

I now use Fedora, to prevent the error again.

[–] [email protected] 9 points 7 months ago

It was my first time using a Linux GUI. I was comfortable with CLI, but it was my first time having it installed on a laptop instead of just sshing into a server somewhere.

So naturally, instead of learning how the GUI worked, I tried changing it to be exactly like Windows. I was doing things like making it so I could double click shell scripts and other code files and they would run instead of opening them up in an editor. I think you see where this is going, but I sure as hell didn't.

Well, one of my coworkers comes over and asks me to run this code on this device we were developing. We were still in the very early stages of development, we didn't even have git set up, so he brought the code over on a USB stick. I pop it into my laptop. I went to check it once by opening it in an editor by double clicking on it... Only it ran the code that was written for our device on my laptop instead of opening in an editor.

To this day, I have no idea what it did to fuck my laptop so bad. I spent maybe an hour trying to figure out what was wrong, but I was so inexperienced with Linux, that I decided to just reinstall the OS. I had only installed it the day before anyway, so I wasn't losing much.

[–] [email protected] 4 points 7 months ago (1 children)

A few years ago I was having obscure audio problems on Ubuntu so I tried replacing pulseaudio with pipewire. I was feeling pretty cocky with using the package manager so I tried

sudo apt install pipewire

Installed successfully, realized nothing changed, figured maybe I had to get rid of pulseaudio to make it stick.

sudo apt remove pulseaudio

Just two commands. Instant black screen, PC reboots into the terminal interface. No GUI. Rebooting again just brings me back to the terminal.

I fixed it eventually, but I'm really not very computer literate despite using Linux, so I was sweating bullets for a minute that I might have bricked it irreversibly or something.

[–] [email protected] 3 points 7 months ago* (last edited 7 months ago)

I feel like you can fix linux as quickly as you can fuck it up (as long as you know what you did)

[–] [email protected] 3 points 7 months ago

Can't say I have any interesting stories. Most of mine are just the head-scratching "I don't know why that didn't work; guess I need to reinstall" kind of story. Like enabling encrypted LVM on install and suddenly nothing is visible to UEFI. Or trying to switch desktop environments using tasksel and now I have a blank screen on next reboot. That lame kind of stuff.

My coworker though... he was mindlessly copy/pasting commands and did the classic rm -rf $UNSETVARIABLE while in / and nuked months of migrated data on his newly built system. He hadn't even set up backups yet. Management was upset but lenient.

[–] [email protected] 5 points 7 months ago

I used to work at this place that had a gigantic QNX install. I don't know if QNX that we used back then had any relation to q&x now They certainly don't look very close.

It was in the '90s and they had it set up so that particular nodes handled particular jobs. One node to handle boot images and serve as a net boot provider, one node handled all of the arcnet to ethernet communication, one node handled all the serial to mainframe, a number of the nodes were main worker nodes that collected data and operated machinery and diverters. All of these primary systems were on upper-end 386s or 486s ,they all had local hard disks.

The last class of node they called slave nodes. They were mainly designed for user data ingest, data scanning stations, touch screen terminals, simple things that weren't very high priority.

These nodes could have hard discs in them, and if they did, they would attempt to boot from them saving the net boot server a few cycles.

If for some reason they were unable to boot from their local hard drive, They would netboot format their local hard drive and rewrite their local file system.

If they were on able to rewrite their local file system they could still operate perfectly fine purely off the net boot. The Achilles heel of the system was that you had no idea that they had net booted unless you looked into the log files. If you boot it off your local hard drive of course your root file system would be on your local hard drive. If you had net booted, and it could not rebuild your local file system, your local root file / was actually the literal partition on the boot server. Because of the design of the network boot, nothing looked like it was remotely mounted.

SOP for problems on one of the slave nodes was to wipe the hard disk and reboot, in the process it would format the hard drive and either fix itself or show up as unreliable and you could then replace the disc or just leave the disc out of it. Of course If the local disk had failed and the box had already rebooted off netboot without a technician standing there to witness it, rm -Rf would wipe out the master boot node.

I wasn't the one that wiped it, but I fully understand why the guy did.

Turns out we were on a really old version of QNX, we were kind of a remote warehouse mostly automated. They just shut us down for about a week. Flew a team out. Rebuilt the system from newer software, and setup backups.

[–] [email protected] 4 points 7 months ago

I can't remember what I did to break it, but back when I was in high school I was tinkering right before class and rendered my laptop unbootable. I booted into an Arch Linux USB, chrooted into my install, found the config file I messed with, then reverted it. I booted back into my system and started the bell ringer assignment as quickly as I could. I had one minute left when the teacher walks by, looks at it, and says that I did a really good job. She never knew my laptop was unbootable just 2 minutes earlier.

[–] [email protected] 5 points 7 months ago (1 children)

A regular update I guess...

[–] [email protected] 3 points 7 months ago

I had a few programs for various things and one was simply an extension from the gnome extension manager. I updated it and my screen turned black and I couldn't get it back. I had to revert to a previous version, then uninstall everything until I figurd out what caused it.

It took several hours.

[–] [email protected] 1 points 7 months ago

I wanted to move my Arch VM to bare metal, so I copied out all the important bits. Then I wanted to move that copy to a new drive so I could boot into it.

I THOUGHT I'd MV all the files in the Arch install's etc directory using sudo MV /etc ...

I also (somehow) mashed my install's etc with Arch's and bungled both, with no live CD to help.

I learned a thing or two about absolute file paths...

[–] [email protected] 1 points 7 months ago* (last edited 7 months ago) (1 children)

I was testing a custom initramfs that would load a full root into a ramdisk, and when I was going to shut down I tried to run rm -rf --no-preserve-root / to see what would happen, since I was on a ramdisk anyway. The computer would not boot after that because it nuked the UEFI options.

[–] [email protected] 1 points 7 months ago

On arch, UEFI boot vars are mounted at /sys/firmware/efi/efivars. It's unwise to rm -rf them....

[–] [email protected] 3 points 7 months ago

I cant remember anymore... Let me explain ... My first computer was with at-the-time-very-new windows xp, using primary for games, after some time it got bloated with stuff so i had to reinstall again and again over time. Then i discovered redhat,centos and debian... I started heavily distro hopping. My passion for software grew to the point that I was installing new software on daily basis, just to explore new things. But nothing seemed stable enough, ubuntu, fedora, sabayon, gentoo, arch... And their derivatives all broke under my fingers to the point that i had to do more fixing than discovering new software, I took it as a challenge and continue. At around the time of university I discovered NixOS, as with any new technology I went head on with it. It took a lot of trial and error since at the time there were no documentation for any of it. I spent months reading the code, but I never gave up, since what I have found was a gem. I found the OS that is resistant to my curiosity, I just cant seem to be able to break it. Now I use NixOS everywhere that I can, even on my work computer. I do not need to reinstall after initial installation. Well... only when hardware fails...

[–] [email protected] 4 points 7 months ago

I set up a progressive backup of my home folder... to my home folder. By the time I got home that day it was impossible to log in because there was no room to create a login record. Had to fix that by deleting the backup file using a live CD.

[–] [email protected] 3 points 7 months ago (1 children)

Back when I started using Linux, I really wanted something that was super different from windows (I used Gnome 3 for like 3 years). I decided one day to try out Fedora cause, hey, I can live on the bleeding edge.

Second day I had it installed, I was having issues with the audio. Decided to try reinstalling pulse. Apt autoremoved it and somehow completely nuked the entire GUI. Stuck in terminal mode, I found that I had no ethernet to connect to, nor could I figure out how to connect to a wifi network with a password or download packages to a USB. After a couple hours, I gave up, wiped the drive, and went back to Mint.

Nowadays I'm happier in my little comfort zone.

[–] [email protected] 3 points 7 months ago

Same thing happened to me! I was on Ubuntu, trying to replace pulse and when it got removed instantly kicked me to the terminal. Eventually I fixed it but now I also just Mint, lol

[–] [email protected] 3 points 7 months ago* (last edited 7 months ago)

I had issues with a new version of glibc that prevented me from working on music in Ardour on Manjaro. I then proceeded to force-downgrade glibc (in the hopes of letting me get back to work) and that broke sudo and some other things, which I found out after rebooting. That was an interesting learning experience. Now I snapshot before I do stupid stuff. :]

[–] [email protected] 2 points 7 months ago

I recently broke the networking stack by uninstalling ca-certificates

I was using a slightly risky command to delete unneeded packages, and for some reason ca-certificates was on the list

At least the fix was simple. Boot the rescue iso and reinstall them

[–] [email protected] 4 points 7 months ago

One day on my main Arch installation I created a container inside a directory, and "booted" into it by using systemd-nspawn. When I was done with it I decided to do a rm -rf / inside the container just to be funny. Then I noticed that my DE on the host froze and I couldn't do anything. Then I realized that systemd-nspawn mounts some important host's directories on the container, and I deleted those when I did the rm -rf /. I didn't lose anything, but it was scary.

[–] [email protected] 2 points 7 months ago

The first time I wanted to try Linux I did by installing elementary OS in dual boot mode (with windows) and everything went well, I played with it a bit and then I returned to Windows..

So, few days after that I realize that I have a lot of space in the Linux partition and I didn't have plans to use it anymore so I go to drive's & partition's manager on windows to delete my elementary OS partition..

Oh Lord when I restarted my PC, grub was showing nonsenses and I couldn't boot on windows again, I was in panic, I spent the rest of the day trying to fix grub to boot windows. At the end of the day I did it and save all my files and I uninstall grub properly, but what a day 😂

[–] [email protected] 3 points 7 months ago

I've literally done the rm -rf / thing. I thought I was in a different subdirectory, but I was in / and did rm -rf .

When it didn't return after half a second, I looked at the command again and hit CTRL+C about 20 times in the span of 3 seconds.

I had to rebuild the install, but luckily didn't lose anything in /home.

[–] [email protected] 3 points 7 months ago* (last edited 7 months ago) (2 children)

sudo apt upgrade -y

To this day I can’t figure out why it killed the GUI and all terminal commands on a Mint install…

[–] [email protected] -2 points 7 months ago

I stay away from apt. apt-update for me has never messed like apt has.

[–] [email protected] 1 points 7 months ago (1 children)

I’m relatively new to Mint, but I thought that sudo apt update just checked for updates and sudo apt upgrade -y was for actually installing the updates. I don't see why that would break it though.

[–] [email protected] 1 points 7 months ago

You're right, I messed up - I always switch between the two, because "update" makes more sense in my head. I fixed the text.

[–] [email protected] 3 points 7 months ago (2 children)

Connect via ssh to my home server from work

Using a cli torrent client to download stuff

Decide I need a VPN.

Install VPN again from CLI

Run VPN which disconnects my ssh connection

Even when I get home, the server is headless so I have to locate a keyboard and mouse before I can fix.

[–] [email protected] 2 points 7 months ago

Dang, similar stuff happened to me on nixos. Had to instruct one of the relatives on how to reboot the machine and choose a previous generation in the boitloader 🤣

[–] [email protected] 1 points 7 months ago
[–] [email protected] 1 points 7 months ago* (last edited 7 months ago)

I had rEFInd and GRUB installed entirely by accident, and a botched update for Arch hosed my entire EFI setup making it impossible to boot Linux or Windows w/o a LiveCD. Thankfully it self repaired once I nuked rEFInd. I ended up going back to Ubuntu, but I hate snaps. I still would recommend Arch for most Linux users who want the power windows.

load more comments
view more: next ›