LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   I'm an idiot moments. (https://www.linuxquestions.org/questions/linux-general-1/im-an-idiot-moments-4175510176/)

basica 07-05-2014 01:08 AM

I'm an idiot moments.
 
I just had one so I'll start.

I recently updated my arch install on my raspberry pi and I could no longer ssh into it. I suspected that might be the issue or perhaps some changes I made the night before. Anyways I spend about an hour trying to figure it out. Reseting config files, reinstalling packages, removing anything attached to the pi and so on. Rebooting and restarting services etc etc.

Anyways I ran ifconfig in sheer exasperation and found that at about the time I ran the update, the IP address changed. So yeah, feel like a total idiot. Now you share :D

coralfang 07-05-2014 02:33 AM

Bought a second hard drive for backups, decided to put it INSIDE the computer (which was a stupid move). Moved my music to the disk (stupid idea, i should have copied not moved), then later in the day i had to format a USB stick, so i insert the usb stick and created a new partition table on /dev/sdb, not thinking that i now have a second drive (which was on sdb)

Ended up formatting my backup disk. Doh. Then spent the next 2 days re-ripping all of my CDs....

qlue 07-05-2014 07:16 AM

Quote:

Originally Posted by coralfang (Post 5198929)
Bought a second hard drive for backups, decided to put it INSIDE the computer (which was a stupid move). Moved my music to the disk (stupid idea, i should have copied not moved), then later in the day i had to format a USB stick, so i insert the usb stick and created a new partition table on /dev/sdb, not thinking that i now have a second drive (which was on sdb)

Ended up formatting my backup disk. Doh. Then spent the next 2 days re-ripping all of my CDs....

Ever tried recovering with photorec? :P

Actually, you should have been able to use TestDisk to recover the previous formatting and directory structure. I've used that before in a similar situation. (backed up then formatted the backup by mistake)

And then there's the time I put in my username and password to login and it wouldn't login. I tried three times before it dawned on me that it was not my laptop and the username/password was different! :P (favours for friends never go unpunished!)

273 07-05-2014 07:25 AM

I've done a similar thing. Had a 1TB ESATA drive plugged in and used for backups and ripped DVDs as overflow from the RAID I used as home. I plugged in a 1GB USB stick and proceeded to format it in gparted. 1TB and 1GB look very similar when you're tired and doing three things at once...
I'm not saying it won't happen again (I'm not that stupid) but I have learned to be a lot more careful and also try to label all my drives. That and I now only have 3 physical drives attached to my PC the majority of the time rather than 7.

maples 07-05-2014 09:47 AM

I had a similar issue to the OP. After a power outage, I could only SSH into my server from my internal LAN, but not anywhere else on the Internet. I had a tab open and almost clicked "Post new thread" when I remembered that we have a dynamic IP, and that the modem rebooting probably changed it. One visit to Google later, and it was confirmed.

frieza 07-05-2014 01:33 PM

you think that's bad, hehe, i remember once i had an old 100MHZ dell unit i was using as a server in my room
(nfs/nis/dhcp/apache/netatalk/samba)

i was trying to remove an old add-on card that was no-longer useful, and forgot that unlike AT units, this older ATK system didn't completely power down the motherboard when you issued the shutdown command to linux, it just halted the system and you had to physically flip the switch, well i went and issued the shutdown command, heard the hard drives click off (or at least park themselves), went to pull the card and was greeted with magic blue smoke, fortunately i didn't completely fry the motherboard but the card was needless to say, toast, not sure about the slot from which I removed the card from as i never tried putting a card in it after that.

either way i never forgot to flip the switch from then on.

another one i did was i had a matrix orbital character LCD, and accidentally plugged in the power cable backwards, the ribbon actually started to fry like a buring fuse on a firework device, as in from one end to the other. though i pulled the power almost immediately the damage was already done, the unit never woked properly again sadly it was junk.

jefro 07-05-2014 04:17 PM

Wow, I've never ever made a mistake, ever. Not one. Nopew!

maples 07-05-2014 06:33 PM

Quote:

Originally Posted by jefro (Post 5199209)
Wow, I've never ever made a mistake, ever. Not one. Nopew!

...never?

brianL 07-06-2014 06:20 AM

I have a tendency to skim through instructions and howtos, then do what I think I've read. I'm surprised things haven't gone badly wrong more often.

Sumguy 07-06-2014 10:45 AM

I used Windows for 11 years, because it came with the computers I bought...... :banghead::doh:

pan64 07-06-2014 01:34 PM

Quote:

Originally Posted by jefro (Post 5199209)
Wow, I've never ever made a mistake, ever. Not one. Nopew!

/bin/rm -rf /

Wasn't that a mistake, was it?

replica9000 07-06-2014 04:36 PM

Quote:

Originally Posted by frieza (Post 5199139)
you think that's bad, hehe, i remember once i had an old 100MHZ dell unit i was using as a server in my room
(nfs/nis/dhcp/apache/netatalk/samba)

i was trying to remove an old add-on card that was no-longer useful, and forgot that unlike AT units, this older ATK system didn't completely power down the motherboard when you issued the shutdown command to linux, it just halted the system and you had to physically flip the switch, well i went and issued the shutdown command, heard the hard drives click off (or at least park themselves), went to pull the card and was greeted with magic blue smoke, fortunately i didn't completely fry the motherboard but the card was needless to say, toast, not sure about the slot from which I removed the card from as i never tried putting a card in it after that.

either way i never forgot to flip the switch from then on.

another one i did was i had a matrix orbital character LCD, and accidentally plugged in the power cable backwards, the ribbon actually started to fry like a buring fuse on a firework device, as in from one end to the other. though i pulled the power almost immediately the damage was already done, the unit never woked properly again sadly it was junk.

Can't say I'm familiar with the ATK format, but my AT machines didn't completely shutdown unless I manually shut them off. Anyways, what you did with the add-on card, I did with a 386 CPU. I had been testing some components, and I ended up pulling the CPU while the system was powered up. There wasn't any smoke or sparks though. The board was still good, but the CPU was now a paperweight.

jefro 07-06-2014 08:02 PM

Nopew.

Any good person out there has made a bunch of mistakes. And they have made really dumb ones. The good techs learn and move on.

maples 07-06-2014 09:15 PM

Quote:

Originally Posted by jefro (Post 5199682)
Nopew.

Any good person out there has made a bunch of mistakes. And they have made really dumb ones. The good tech's learn and move on.

Fair point...

frieza 07-06-2014 10:45 PM

Quote:

Originally Posted by replica9000 (Post 5199612)
Can't say I'm familiar with the ATK format, but my AT machines didn't completely shutdown unless I manually shut them off. Anyways, what you did with the add-on card, I did with a 386 CPU. I had been testing some components, and I ended up pulling the CPU while the system was powered up. There wasn't any smoke or sparks though. The board was still good, but the CPU was now a paperweight.

er.. i meant unlike ATX units, older AT units didn't completely shut down.

salparadise 07-07-2014 01:06 AM

Accidentally wiped a 250Gig partition with my entire music and video collection on it and about 3 years worth of emails and ICQ logs.

frieza 07-07-2014 02:07 AM

Quote:

Originally Posted by salparadise (Post 5199766)
Accidentally wiped a 250Gig partition with my entire music and video collection on it and about 3 years worth of emails and ICQ logs.

done that too
did it to a friend of mine by accident with a 1TB hard drive with irreplaceable photos of friends of his that had passed on, not pretty.

onebuck 07-07-2014 08:31 AM

Member Response
 
Hi,

I told my students to always 'Measure twice & cut once'. Check & re-check are both good rules to use everyday if you do not want a 'gotcha moment'.

Have fun & enjoy!
:hattip:

brianL 07-07-2014 12:06 PM

Hey, Gary! You seem to have become obsessed with copyrighting everything.
:D

PrinceCruise 07-07-2014 12:33 PM

I once wiped Slackware 13.1 from my laptop just because I couldn't get the Broadcom wireless to work on that. It took me almost an year to come back to 13.37. I was an idiot.

Oh and once I logged in to one of my organization's production DB server using root and did some unspeakable things. :D

Regards.

Germany_chris 07-07-2014 12:36 PM

I tend to make myself feel like an idiot every day at least once.

Two fridays ago I was trying to get home (180km away) but I needed to print a 7' banner I'd made before going home and the f'ing thing would only print partially half to be exact. I futzed and futzed eventually I turned the banner into a poster figuring I'd just print 3 and it still would only print half the image. I finally said F'it and I went home about half way through the drive home I realized I was trying to print to my plotter at 600 dpi which it won't do ( thanks Ps for keeping the last setting) so the Sunday before my daughters birthday I got to make the 360km commute to print off that stupid banner. Needless to say my wife was less than pleased and there is nothing worse than a pissed off German woman.

Hungry ghost 07-07-2014 01:06 PM

Quote:

Originally Posted by onebuck (Post 5199921)
I told my students to always 'Measure twice & cut once'. Check & re-check are both good rules to use everyday if you do not want a 'gotcha moment'.

Yes, that's what I always do. Being mildly obsessive, I'm naturally a double-checker (and even triple-checker). But even so, I've had a few dumb moments :).

onebuck 07-07-2014 01:46 PM

Member Response
 
Hi,

Quote:

Originally Posted by brianL (Post 5200030)
Hey, Gary! You seem to have become obsessed with copyrighting everything.
:D

And the problem is.... :)

brianL 07-07-2014 01:58 PM

No problem...a bit strange, that's all.
:)

Habitual 07-08-2014 12:59 PM

I've pulled every bone head move there is.
It's what has made me the SysAdmin I am today.

Luckily for me, I fix way more than I break.

maples 07-10-2014 10:57 PM

Using --checksum with rsync...my server is slow to begin with, and that one little flag made it a whole lot worse.

replica9000 07-10-2014 11:32 PM

Quote:

Originally Posted by maples (Post 5202057)
Using --checksum with rsync...my server is slow to begin with, and that one little flag made it a whole lot worse.

I did the same thing a couple weeks ago. Tried to sync 3TB of data with the --checksum flag. Woke up 7 hours later to find only about 5 files had been synced.

maples 07-11-2014 10:16 AM

Quote:

Originally Posted by replica9000 (Post 5202071)
I did the same thing a couple weeks ago. Tried to sync 3TB of data with the --checksum flag. Woke up 7 hours later to find only about 5 files had been synced.

Before I looked at the usernames, I thought for sure that you were the one who started this thread: http://www.linuxquestions.org/questi...on-4175509597/

suicidaleggroll 07-11-2014 12:41 PM

Thought I was in ~/bin once, and wanted to clear it out, so I ran "rm -f *". Turns out I was in /bin, and was logged in as root.

I ctrl+c'd within about 5 seconds, but by then I had already lost basically the entire directory, including cp, mv, vi, etc.

Luckily I had another system with the same OS nearby and was able to scp the contents of /bin over, fixing the problem.




Another stupid issue that I've run into MANY times is a result of auto completion putting a space after the file when it matches it. I would want to remove all files with the same prefix, so I would type
Code:

rm -f prefix<tab>*
When there is more than one file matching that prefix, it's fine. The tab matches out to the end of the common prefix, then the * tells it to match all of the files with that prefix. When there is ONE file matching that prefix, the auto completion puts a space after it, and the command becomes
Code:

rm -f nameoffile *
Which, of course, means "remove nameoffile, as well as everything else in the cwd".

I probably made that mistake 4-5 times before I finally got fed up enough that I modified my bash auto-completion rules so that when I'm running rm, it doesn't put a space after the match.

goumba 07-13-2014 07:06 AM

Seems like the formatting drive thing is the common story, I'll add mine.

I had built a Debian Live image for a USB stick which I use at work. Usually I turn the laptop on, plug in the USB stick, and dd the image. All of my partitions are on the single laptop hard drive (sda)

This time, I threw the USB stick in first, and boot. Everything boots fine. Get to a terminal, and
Code:

dd if=binary.img of=/dev/sdb
Then I realize it's late, and will do this tomorrow instead. I Ctrl+C the dd process, and proceed to shutdown. First, I eject the USB stick.

Code:

$ eject /dev/sdb
umount: /home: device is busy.
        (In some cases useful info about processes that use
        the device is found by lsof(8) or fuser(1))
eject: unmount of `/home' failed

HUH??? WHAT??? That ain't right!!!

run dmesg, and it turns out for whatever reason, the USB stick was detected as /dev/sda. Insert expletive here. Since when???

Turns out I had written about half of a gig to the laptop's hard drive. Yup. That sucks.

Fortunately the EFI partitions were first, followed by the root partition. home, usr and etc were unharmed.

I learned a lot about successfully recovering a GPT the next few days. Reinstalled Debian and was back in business. No data recovery needed as I was able to put the partitions back in place.

sidzen 07-13-2014 01:03 PM

Generally speaking, I told my girlfriend the truth even though I wanted to keep her around!
Upshot: do I want to be right, or would I rather be happy? LOL

rtmistler 07-14-2014 08:13 AM

Older IBM bus architecture, I'm thinking it was an ISA card. I was tasked with testing various daughter cards which meant a lot of plugging and unplugging of cards. They asked me to show the differences in behavior with a few of the cards to one of the senior VPs. I ran through it 5 minutes before with my boss, they bring the VP in there; I plugged in the first card, something I'd done a hundred times before and the system totally wouldn't boot. We worked at it for a bit, even the VP gave it a try, then left shaking his head. The boss wasn't all that pleased and asked me to figure out what went wrong. Couldn't. Turned out one of the pins got misaligned and when the card went in, it got shoved over to the opposite side and crushed; shorting out the connector; but only in such a way that it happened when there was a card inserted in that slot to hold the bent pin right up against the opposing side. We had to send the PC out for repair to find that out, it took about 2 months to get resolved. So I was a real happy student intern that Summer.

I have done the rm -rf * in the wrong place too!

273 07-15-2014 01:48 PM

I was an idiot last night.
I ran "apt-get dist-upgrade" and entered "y" on my PC whilst paying attention to something I was doing on my Pi. It was only after the process completed that I realised I had just wiped out the NVIDIA drivers as those in Sid are not currently compatible with the version of X11 (or something along those lines, didn't check the details). The silly thing is I had been running dist-upgrade with my finger on the "n" key for a good few days waiting to see whether the situation would change so I knew what would happen.
Now I just have to work out how check when the NVIDIA drivers from the repository will install again and use the installer direct from NVIDIA in the mean time...
Still, I was toying with the idea of a new graphics card so if I do decide to do that at least I have drivers which would support it.

rokytnji 07-16-2014 08:35 PM

Buying a VGA to HDMI cable thinking it would work from laptop to TV without a anolog to digital converter box.

Should have searched 1st before buying. But was in a hurry.;

salparadise 07-16-2014 11:48 PM

Giving PCBSD a try, by attempting to add it to an existing Linux HD, without reading up on it first or doing any kind of study.
My annoyance over the predictably trashed partition table and lost home dir was only surpassed by my irritation at myself for not reading first.


"Measure twice, cut once" - meh. Judge it by eye, lay into it with the wrong saw, make an utter hash of it then retire to a safe distance muttering about "and that's why we invented plastic".

273 07-17-2014 02:07 AM

Quote:

Originally Posted by rokytnji (Post 5205039)
Buying a VGA to HDMI cable thinking it would work from laptop to TV without a anolog to digital converter box.

Should have searched 1st before buying. But was in a hurry.;

I think the cable sellers should take some of the blame here unless the packaging/website (depending where you bought it) had it in fairly big letters that one was required. I would even go so far as to say this was approaching a confidence trick.
Granted if you know a little about these things you could probably work out that something would be required to do analogue to digital conversion but I don't think an average consumer should be expected to know that.

descendant_command 07-17-2014 02:42 AM

@273
Maybe a good time to try out the nouveau project - it's improved a lot in the last year.

As for my own 'oopses' there is the usual collection of "bugger, wrong drive" and "oh crap, wrong dir".

Most recent facepalm moment was with a Dell laptop with one of those stupid slot-load DVD drives.
It swallowed a DVD, then failed to either read or eject it.
After searching in vain for a method of "encouraging it" embarked on the complete teardown of the machine and partial dismantle of the drive itself to extract said disk.
It was only after reassembling and powering on that I discovered the drive still thought it had a disc in it and proceeded to do the disk-read-fail cycle endlessly...

273 07-17-2014 02:47 AM

Quote:

Originally Posted by descendant_command (Post 5205166)
@273
Maybe a good time to try out the nouveau project - it's improved a lot in the last year.

Thanks, I did wonder about giving it a try but I think that Steam and another couple of things I use require the proprietary drivers still.

rokytnji 07-17-2014 02:41 PM

Arguing with a opinion on this forum.

http://imgs.xkcd.com/comics/sheeple.png

Snapped! 07-18-2014 08:15 PM

I once forgot to compile some modules like the scsi controller and some others in crux linux. Crux linux doesn't use an initrd image, so you must have certain modules compiled into the kernel. After I did rebuilding of the kernel it booted crux just fine.

rtmistler 08-08-2014 11:27 AM

One more for the list.

Making a SD card for booting a Beaglebone Black. Instead of formatting and making new file systems, I noticed that the partitions and file systems were all fine and I needed to erase whatever was on each partition, boot and root and then copy over the contents from my local archive. Boot went fine, it's small and takes few seconds to erase and copy over. Root was a different story. I don't know the details I was doing other stuff and my system went haywire. What I can gather is that a symbol, link, .... something caused the rm -rf to change off of my SD card mount directory and began removing stuff from my core system. It died because it killed enough of the system to not make it be able to work anymore! I was only able to see that the rm operation had encountered some form of unknown redirect and then couldn't do anymore except rebuild my system. Since the rm operation was done as root to resolve the BBB disk file ownership, it was a very, dangerously powerful command and lousy result.

Days like yesterday make me happy I store a ton of redundant stuff on and off system.

frieza 08-08-2014 01:19 PM

Quote:

Originally Posted by rtmistler (Post 5217585)
One more for the list.

Making a SD card for booting a Beaglebone Black. Instead of formatting and making new file systems, I noticed that the partitions and file systems were all fine and I needed to erase whatever was on each partition, boot and root and then copy over the contents from my local archive. Boot went fine, it's small and takes few seconds to erase and copy over. Root was a different story. I don't know the details I was doing other stuff and my system went haywire. What I can gather is that a symbol, link, .... something caused the rm -rf to change off of my SD card mount directory and began removing stuff from my core system. It died because it killed enough of the system to not make it be able to work anymore! I was only able to see that the rm operation had encountered some form of unknown redirect and then couldn't do anymore except rebuild my system. Since the rm operation was done as root to resolve the BBB disk file ownership, it was a very, dangerously powerful command and lousy result.

Days like yesterday make me happy I store a ton of redundant stuff on and off system.

i know how that goes, i did something like that the other day on a customer's machine, i was trying to erase the contents of a tarball manually by
Code:

for file in $(find .)
do
rm -rf /$file
done

except the process removed most of /lib and /usr/lib etc.. so i ended up with an unstable but semi functional system, i had to manually restore a couple library files and then run a
Code:

for pkg in $(dpkg -l | cut -f3 -d" ")
do
sudo apt-get install --reinstall $pkg
done

to reinstall all installed packages
and even that didn't fully work so ultimately it was quicker to copy the user's data off the machine and reformat

i also took a 2TB hard drive owned by a friend of mine (well more a friend of my boss than mine) and installed it in a machine, and reformatted it from NTFS to ext4 because i was puttint it into a Linux server, incorrectly thinking the drive was blank, but it not only wasn't blank it had irreplaceable pictures of friends of his who had since passed on and a lot of other irreplacable data of personal significance. was unable to recover the data. I was forgiven since it was an innocent mistake, and a miscommunication but I still feel bad about that one.

replica9000 08-09-2014 09:54 AM

I put my filesystems in lvm with dm-crypt. Booted up a live cd, backed up the filesystems, created the dm-crypt container, created the logical volumes, restored the filesystems, updated the initramfs. Went to reboot and was greeted with cryptsetup: lvm not available. Whoops, forgot to install lvm. Doh!

garpu 08-10-2014 12:23 AM

Oh boy.

When I was new to linux, I was trying to delete some csound library files. So in /lib, as root I did: "rm libc*" (Yeah I know it's installed to /usr/local.)

Another time I deleted bash. I don't remember how I did it. My best friend's brother was running the same distro, same version, so simlinked bash to another shell so I could function and ftped over a fresh copy of bash.

There's also the time I compiled a kernel without ext2 support. (And was using ext2 at the time.)

maples 10-26-2014 03:40 PM

Yesterday, I installed another hard drive in my home server. I went into gparted, opened sdd, (since I had just installed the 4th drive), and formatted. Little did I know that I had reversed SATA ports 3 and 4... so I essentially wiped a third of my software RAID-0. I first realized that something was worng when the boot screen started filling me with errors and dumped me into a rescue shell. And since the RAID had been setup during the Debian install and I hadn't touched a RAID since. I eventually fixed and reformatted the RAID thanks to the Arch wiki...
Fortunately, I constantly rsync everything with a 1TB external HDD (and everything is also on my laptop), so I didn't lose a thing. Thank God for backups!!

LinBox2013 10-26-2014 03:55 PM

I remember back around 1999 when I was new to linux. I was very ignorant.

I could not get X to work no matter what I did (limited knowledge). So, I hit up different places. I seen a signature, it read something like:

"When all else fails, rm -f / seems to always fix the problem"

So after beating the keyboard to death all night, I though all else is failing and tried it.

We all know how that went...

maples 10-26-2014 05:30 PM

On the aforementioned home server, trying to run 2 WinXP VMs at the same time with 3 GB of RAM. (Each VM is allocated 1GB RAM, but I apparently didn't think about any overhead.) One VM (the "experimental" one where I do stuff that might potentially infect something, like software i don't trust) was running just fine. Then I tried to start the other one (the "base" one that I just clone if I need an "experimental" one). And it's been about 10 minutes since then. The hard drive light has been solid on for that time, and I can't even SSh into it right now. Maybe when the second VM finishes booting it might calm down...

I'm sure it doesn't help that my swap and /home are on the same hard drive...

Keith Hedger 10-26-2014 08:13 PM

I once encrypted a 1TB drive and thought I'd secured all my data - until I forgot the password and spent a week trying to recover the data, I gave up in the end, luckily most of the data was replacable.

goumba 10-27-2014 12:37 PM

Quote:

Originally Posted by LinBox2013 (Post 5259938)
I remember back around 1999 when I was new to linux. I was very ignorant.

I could not get X to work no matter what I did (limited knowledge). So, I hit up different places. I seen a signature, it read something like:

"When all else fails, rm -f / seems to always fix the problem"

So after beating the keyboard to death all night, I though all else is failing and tried it.

We all know how that went...

LOL... listen, I've done it to a contractor at work. This guy worked for Seimens, on a multi-bullion dollar project for my employer to modernize a century old relay based system (the joke is all this multi-billion dollar project is, is a computer based, GUI overlay on top of the old relay based system... so both systems need to always be functional).

The OS was Solaris 8 (and this was in 2011, the system just starting to be used, and was supposed to be a state of the art system!).

The one guy was upgrading the software, using a projector in a meeting room so I saw everything he was doing.

Me: "I heard it's really cool if do run 'rm -fr /' at the shell prompt. Ever do that?"
Contractor dude: "Oh yeah?" in a heavy German accent;

and proceed to type 'rm -fr' when I stopped him. I told him it was bad, but never told him why.

My supervisor told me I would have lost my job. Me, who working in a civil service, non-IT or any computer related field, and only making like $60 grand a year. Not the dude who's company is being paid billions and their staff obviously don't know basic UNIX.

I'm not sure if the 'I'm an idiot' moment would come from me even playing such a joke, or for me expecting the contractor's employee who's running commands as root to know what he's doing.

rtmistler 10-27-2014 01:21 PM

Quote:

Originally Posted by goumba (Post 5260323)
LOL...
I'm not sure if the 'I'm an idiot' moment would come from me even playing such a joke, or for me expecting the contractor's employee who's running commands as root to know what he's doing.

I was close to replying to LinBox2013's post about someone having that in their signature, to say that it is a horrific thing for someone to have in their signature.

They were upgrading the system and didn't know basic commands! Lovely. And Solaris 8 was End of Life like two years ago. But I've seen weirder things. I think we've all been in a similar position where we could've handled that better but if your job function was totally unrelated to their actions, you'd be on the short end of the stick were you to just note to management that the contractor wasn't the sharpest tack.

Those with knowledge, please never make system destructive jokes like that. You never know how far they'll go.


All times are GMT -5. The time now is 03:23 AM.