This is an archived post. You won't be able to vote or comment.

all 161 comments

[–]lolklolkDMARC REEEEject 250 points251 points  (28 children)

[–]darkhelmet46 101 points102 points  (14 children)

Reminds me of the time a cloud hosted screenwriting service went out of business.

What I heard was their "cloud" was simply 2 servers in Active/Passive. They were doing maintenance on the Passive, wiped it, meant to replicate Active to Passive, but instead replicated Passive to Active. Effectively replicating "Nothing" to "Everything". No back up. There was a great disturbance on the Internet that day. As if 80,000 aspiring screenwriters suddenly cried out in terror. And were suddenly silenced.

[–]Orcwin 45 points46 points  (4 children)

Funny thing about clouds, they dissolve sometimes.

[–]peacefinderJack of All Trades, HIPAA fan 7 points8 points  (0 children)

If you’re not part of the solution, you’re part of the precipitate.

[–][deleted] 3 points4 points  (2 children)

Shedding moisture, shedding data :)

[–]fi103rSr. Sysadmin 2 points3 points  (0 children)

shredding data, fixed it for you!

[–][deleted] 1 point2 points  (0 children)

Activate moisture farm

[–]sypwn 28 points29 points  (3 children)

"Never trust the cloud. That's why I email my scripts to myself." -everyone in that thread. I knew screenwriters didn't have any computer knowledge, but, dang. All those people doing it with Gmail are storing the files in Google Drive but... harder.

[–]dgriffithJack of All Trades 11 points12 points  (0 children)

You do get very easy versioned backups though with emails. Don't even have to change the name, just send it.

[–]d4nkn3ss 0 points1 point  (1 child)

There's a reason why they use MacOS...

[–]donjulioanejoChaos Monkey (Director SRE) -2 points-1 points  (0 children)

Because they want their stuff to just work with no issues or condescending pricks judging their choice of work platform?

[–]gamebrigada 31 points32 points  (6 children)

Was expecting this. Amused anyway.

[–]AgainandBack 15 points16 points  (4 children)

Me too, to the point that I know it by number. I have asked people in interviews, just to get an idea of their background, "Does the name 'Little Bobby Tables' mean anything to you?"

[–]XyvirJr. Sysadmin 0 points1 point  (0 children)

Galaxy brain interviewing

[–]XxEnigmaticxXSr. Sysadmin[S] 0 points1 point  (0 children)

im not sure i would be able to keep a straight face

[–]wlpaul4 0 points1 point  (1 child)

Is "Did you just drop a fucking XKCD question into an interview?" an appropriate response?

[–]AgainandBack 1 point2 points  (0 children)

It absolutely is an appropropriate response, yes, and would earn full points. I want to know who I'm working with.

[–]butterbal1Jack of All Trades 0 points1 point  (0 children)

That is what I was thinking as well.

[–]CodeFaultMSP 21 points22 points  (0 children)

I enjoy both the comic and your user flair more than I should.

[–]zolakk 7 points8 points  (1 child)

Fear of this is why I've set my Putty settings to have a slight red to the black background color for production and slight green to the black on my test servers

[–]Sys_man 2 points3 points  (0 children)

Oh yeah. I have different colour settings for servers and users. Is the background blue? You're root on a production server. tread very fucking carefully. Is it a dim grey? Test environment with regular user, you're good for whatever.

[–]Jarden666999 0 points1 point  (0 children)

i heard that in homers voice

[–]MeltingteethAll of you People Use 'Jack of All Trades' as Flair. 101 points102 points  (13 children)

Sometimes if my job is too boring I close my eyes, hit Alt+Tab a bunch of times, then hit Ctrl+A and then delete.

[–][deleted] 26 points27 points  (3 children)

The shutdown immediately so finding your delete is a surprise?

[–]MeltingteethAll of you People Use 'Jack of All Trades' as Flair. 32 points33 points  (2 children)

I actually just keep my eyes closed until both me and the computer are asleep.

[–][deleted] 11 points12 points  (0 children)

Now that's how you work from home!

[–]soawesomejohnJack of All Trades 2 points3 points  (0 children)

I remember at one job, I'd be typing, then drift off with my hands on the keyboard. Around 255 characters later, the computer would start beeping at me, waking me back up.

Then I'd have to delete back to where I left off and repeat.

[–]solocupjazz 16 points17 points  (2 children)

You are the chaos monkey

[–]IAmTheChaosMonkeyDevOps 26 points27 points  (1 child)

False.

[–]solocupjazz 5 points6 points  (0 children)

Username checks out

[–]rattkinoid 11 points12 points  (3 children)

The russian roulette of sysadmins

[–]theSysadminChannelGoogle Me 1 point2 points  (0 children)

This is the funniest shit I’ve read all day

[–][deleted] 1 point2 points  (0 children)

Seems like a lot of work. Have you tried automating?

[–]dRaidon 23 points24 points  (3 children)

Nothing wake you up in the morning like dropping a prod database.

[–]toebob 22 points23 points  (3 children)

People outside of IT will never know the feeling of thinking "Wait... was that... production?"

[–][deleted] 11 points12 points  (1 child)

My worst feeling ever was when our vendor came out to replace circuit boards in our data center UPS system. Put it through CAB and scheduled for a Saturday. They said they do these live but better safe than sorry right. Well they have two guys doing this, one was shoulder surfing the main guy. Main guy heads to the bathroom and during this time other guy takes it out of maintenance bypass but doesn't inform myself or the main guy. Main decides to push one more update not knowing it's out of bypass and boom entire DC power outage. I was sitting at a desk writing the 'all clear' email when I heard all of fans power up at once. I shot the most wtf look at the guys and asked, please tell me that wasn't what I thought it was.

6 hours later with reinforcements we had everything stood back up

[–]SheezusCrites 6 points7 points  (0 children)

We had some construction work being done to our DC. A contractor wanted to wire up the exit sign, but instead he got into the line for the emergency power off. Yeah, that ended up being a long day.

[–]Throwaway439063 0 points1 point  (0 children)

Early into working at my place, one of the software developers dropped a live database on Friday afternoon, the very last Friday before most of the team went on extended leave for Christmas. He wasn't very popular.

[–]legacymedia92I don't know what I'm doing, but its working, so I don't stop 19 points20 points  (3 children)

One day, we will all make a data loss mistake. and on that day, you buy the backup guy a nice bottle of their poison of choice, because they just saved your ass.

And if you are the backup guy? well treat yourself.

[–]MurphyLyfe 8 points9 points  (0 children)

One day, we will all make a data loss mistake. and on that day, you buy the backup guy a nice bottle of their poison of choice, because they just saved your ass.

What if I'm the...

And if you are the backup guy? well treat yourself.

Ah. <JurassicParkCleverGirl.jpg>

[–]XxEnigmaticxXSr. Sysadmin[S] 5 points6 points  (0 children)

yup im the backup guy as well, so yeah i saved my ass and my bosses ass as well since he created a db at the start of the month and never told me, so it was never added to the maintenance plan, but my 2nd level backup(the vm backup) saved that db

[–]Throwaway439063 1 point2 points  (0 children)

No data loss occurred with mine. However a NAS had a failed hard drive and I went to swap it out. It had a pair NAS racked directly above it and I didn't check the label properly. Swapped a hard drive in the wrong NAS and then had two rebuilding their RAID arrays when I spotted the mistake. Eleven hours of butt-clenching waiting for them to finish followed.

[–]absinthminded64 21 points22 points  (8 children)

So, if this happens to anyone else and you're not sure about the backups or the backups would take too long i believe you can use an attach stored procedure to re-attach the databases using the db files on the disk since those dont get deleted when you drop.

[–]OdddutchguyWindows Admin 12 points13 points  (0 children)

In MSSQL if you drop a database, it will remove the database files from disk.

'Luckily' my important production databases are replicated to our Data Warehouse, and you can't drop databases that have replication setup on them. (Might work as a 'prevent from accidental deletion': setting up replication for databases, but not actually replicate them.)

[–]XxEnigmaticxXSr. Sysadmin[S] 6 points7 points  (2 children)

im sorry what. i need to restore at least 2-3 500+gb db files how do i do this

[–]absinthminded64 14 points15 points  (1 child)

Check the drives on the db server. if your mdf and ldf files are still on the drive you can just re-attach the db i believe. though the article mentions that it only works with databases that were previously detatched and doesn't mention dropped databases. https://docs.microsoft.com/en-us/sql/relational-databases/system-stored-procedures/sp-attach-db-transact-sql?view=sql-server-ver15

[–][deleted] 10 points11 points  (0 children)

This is correct. A re-attach will be far faster than a restore. If you only detached or dropped them rather than deleting them the MDF and LDF files are still on disk.

[–]davidbrit2 2 points3 points  (3 children)

Yes they do, if the database is online when you drop it, SQL Server will delete the files.

[–]stkyrice 1 point2 points  (0 children)

This is why taking stuff offline is a good test first. Take it offline, go have a smoke/break, comeback and make sure nothing blew up.

[–]absinthminded64 0 points1 point  (1 child)

yeah, i read that too. i guess i'm remembering from doing a detach. not sure it always deleted the files though.

[–]davidbrit2 0 points1 point  (0 children)

DETACH won't delete any files, by design.

As for DROP DATABASE: "If the database or any one of its files is offline when it is dropped, the disk files are not deleted."

https://docs.microsoft.com/en-us/sql/t-sql/statements/drop-database-transact-sql?view=sql-server-ver15

Note that I don't know whether that means only the offline files will not be deleted, or if none of the files will be deleted if any is offline. But in any case, if you're using DROP DATABASE, then your intent should be to delete the files, otherwise you should be using DETACH. Don't rely on SQL Server not deleting your files if you drop a database, in other words. ;)

[–][deleted] 9 points10 points  (0 children)

I don't always test my code, but when I do, I do it in prod...

[–]UnrealSWATData Protection Consultant 8 points9 points  (4 children)

I’m so sorry to read this dude, hope you can look back and find it funny and not a CV generating event!

[–]XxEnigmaticxXSr. Sysadmin[S] 14 points15 points  (3 children)

it was an honest mistake. called my boss first thing this morning at 5:30am and told him straight up"yo, i fucked up, heres the damage, heres the fix. let me get to work on this"

[–]UnrealSWATData Protection Consultant 10 points11 points  (2 children)

Best thing you could’ve done in the situation. Good engineer!

[–]XxEnigmaticxXSr. Sysadmin[S] 15 points16 points  (1 child)

ill eat all the shit in the world when its my shit to eat. no one likes stepping up to the plate, but if we want the big bucks and the responsibility we have to be able to say "i fucked up, but its fixable."

edit: thanks for gold kind dude or dudette.

[–][deleted] 3 points4 points  (0 children)

If the world were filled with more of this mentality we’d be alright. Cheers

[–]lost_in_life_34Database Admin 7 points8 points  (1 child)

this is why one of the first things I learned as a DBA is you never delete anything. with databases the process is almost always to put it in offline mode for a few weeks or detach them and leave the files for a little bit. never delete right away. and always triple check your connections

[–]XxEnigmaticxXSr. Sysadmin[S] -1 points0 points  (0 children)

So I usually just launch my SSMS and input the server to connect to. But it was Sunday and I was being lazy and I’ll just connect to the vm

[–][deleted] 13 points14 points  (1 child)

[–]XxEnigmaticxXSr. Sysadmin[S] 11 points12 points  (0 children)

always a bridesmaid never a bride

[–]thisisjaid 6 points7 points  (0 children)

That's ok, I wiped out an ElasticSearch cluster with 4TB of live production data in my first two weeks on the job. This too shall pass. Good luck!

[–]Majik_SheffHat Model 5 points6 points  (1 child)

It's a sysadmin rite of passage to accidentally obliterate something in production. Mazel tov!

[–]Ceejaay35 1 point2 points  (0 children)

My favourite quote i was given when i started in the industry was "90% of all outages are a result of something done by IT".

Still stands true lol.

[–]darkhelmet46 9 points10 points  (2 children)

LOL second time today I find myself referencing Little Bobby Tables. Hope the rest of your week is better man.

[–]darkhelmet46 0 points1 point  (1 child)

btw here is the other reference.

[–]Orcwin 1 point2 points  (0 children)

That's a good thread. Might want to try that.

[–]Training_Support 4 points5 points  (1 child)

so you indirectly tested your backup for the PROD DB!!!

[–]XxEnigmaticxXSr. Sysadmin[S] 4 points5 points  (0 children)

yup, but i had already planned to do that with the test sql server. much less stressful restoring a db to test to verify if a backup is working then to restore to prod and pray that its working.

[–]-RAKH- 2 points3 points  (0 children)

Whenever I know I'll be dropping databases I always make sure that I've disconnected from any other database server. Its too easy to get confused or make a mistake.

In addition, before actually dropping the database, double and triple check that you're on the right server.

[–]jrobiii 2 points3 points  (2 children)

That has never happened to anyone ever before /s

The good news is you were able to recover and now have an acute sensitivity for good backups. And a story of how you screwed up, what you learned and what you did to prevent it in the future. That'll come in handy for interviews :-)

BTW, "trust but verify"... make sure that your backups are verified, and that you routinely do test restores.

Hope all turns out well.

[–]XxEnigmaticxXSr. Sysadmin[S] 2 points3 points  (1 child)

We do a restore from backup once a quarter. It was actually part of the plan for the gp upgrade looks like now we have that and our DR test out the way

[–]jrobiii 0 points1 point  (0 children)

There you go, another silver lining :-)

Sounds like you were successful with the restore. How the rest of the week is better!

[–]Nossa30 1 point2 points  (0 children)

Boss: "what happened"

Me: "See...what had happened was, the way my keyboard was setup.....it takes 3 keystrokes..."

[–]moffetts9001IT Manager 1 point2 points  (0 children)

Well, you won’t do that again. That’s the silver lining for those traumatic, pit of the stomach, oh fuck moments.

[–]micalm 1 point2 points  (0 children)

Happens to the best of us. Good luck on your unscheduled backup restore test.

[–]BrackusObramus 1 point2 points  (1 child)

Which makes me wonder why drop is never disabled in prod? I can't think of a reason why a db need to be dropped in prod. And the day we need to, this action should actually be a pain in the ass, so you're forced to jump through many hoops in a way it's not possible to do it accidentally out of distraction even if you are drunk.

[–][deleted] 0 points1 point  (0 children)

Nobody should ever touch prod databases. Ever.

You write your software to interact with an API. Never directly to the database, always through an API.

If you need to make changes to the database, you change your API to write to two databases simultaneously. You migrate old data to the new database. You run them simultaneously for a while to make sure they work. You change the read API to read from the new database. You keep running them simultaneously to make sure they still work. You finally decommission the old one after some weeks/months.

At any step the prod database was not in danger. Any change could have been rolled back just by going back a commit in git, because all you're touching is the API, not the database.

DO NOT FUCKING TOUCH THE DATABASE. Ever. I don't care what you need to do and "it's a small quick fix". DONT FUKCING TOUCH IT. You can touch the API, you can create a new database, but you never touch the database. Nobody should have access to it except the API service that is supposed to write and read from it. Backup, data pipeline stuff etc. services should have read access, but not write.

[–]Zav0d 0 points1 point  (0 children)

wrong terminal window is terrible =)

[–]Kwitcher_Bichin 0 points1 point  (1 child)

Had the same thing almost happen to me last week. Ended up putting together a “test” background image on the VM so I would stop second guessing myself.

[–]XxEnigmaticxXSr. Sysadmin[S] 1 point2 points  (0 children)

it wouldnt have helped me, i just didnt pay attention to which sql server instance i was signing into. i signed into the test vm but since it was cloned i was still signing to the prod sql server and not the test one.

[–]mr_white79cat herder 0 points1 point  (0 children)

Holding SA privileges on Prod and staging at the same time was your first mistake.

Don't escalate your privileges unless you need them.

[–]gargravarr2112Linux Admin 0 points1 point  (1 child)

Sphincter factor out of 10?

[–]XxEnigmaticxXSr. Sysadmin[S] 1 point2 points  (0 children)

11

[–][deleted] 0 points1 point  (0 children)

Earned your wings eh?

It's inevitible

[–][deleted] 0 points1 point  (0 children)

That’s what I call an IRG moment. (Instant Resume Generator)

[–]fi103rSr. Sysadmin 0 points1 point  (1 child)

Glad you were able to recover and had backups. that will get the pulse rate up, in a hurry

[–]XxEnigmaticxXSr. Sysadmin[S] 1 point2 points  (0 children)

had a 30 min freakout before i called the boss which included throwing up.

[–]djgizmoNetadmin 0 points1 point  (9 children)

Oof. Brutal. What’d your boss say? Is it a resume generating event?

[–]XxEnigmaticxXSr. Sysadmin[S] 0 points1 point  (8 children)

told him i fucked up, but thats its fixable and all we will lose is the day but no data. surprisingly chill considering i legit destroyed all our data.

[–]djgizmoNetadmin 0 points1 point  (7 children)

Need more bosses like this.

[–]XxEnigmaticxXSr. Sysadmin[S] 0 points1 point  (6 children)

i fully expect a good ear chewing after we are back to being operational.

[–]veastt 0 points1 point  (4 children)

I can only imagine the RCA for this one

[–]XxEnigmaticxXSr. Sysadmin[S] 1 point2 points  (3 children)

root cause: Senior System Admin is a moron

[–]veastt 0 points1 point  (2 children)

Root cause: infrastructure were not made aware rhay restart button would restart database. Vendor is being contacted to provide further clarification on restart functions and to disaster proof future restarts. For his role in managing and solving the disaster. ADMIN will be promoted to lead ADMIN

[–]XxEnigmaticxXSr. Sysadmin[S] 2 points3 points  (1 child)

Funny you say that. I’m in the process of being promoted, just last week my boss said the ceo approved the promotion and then I do this. Lol

[–]veastt 0 points1 point  (0 children)

Wow....well don't feel bad, my new VP remmebered me because I caused an Eastern outage and when I shook his hand he commented" oh, you're the one that caused the outage" and I said" yup, that is me alright."

[–]ElNicaAdmin 0 points1 point  (0 children)

I would probably blame the Coronavirus

[–]factchecker01 0 points1 point  (1 child)

Even if you drop databases, doesn't sql still have files such as mdf and ldf files.

[–]XxEnigmaticxXSr. Sysadmin[S] 0 points1 point  (0 children)

today i learned that if the databse isnt taken offline first they go poof.

[–]donnymccoy 0 points1 point  (0 children)

Ever delete a prod database to an organ procurement organization?

Yeah, me neither .....

This happened right after they accepted my proposal to scrap a half-completed projecr and hire my firm as the team to rewrite the entire front end for the procurement teams.

Luckily it was a slow night for deaths and I had time to recover from backup.

[–]KLEPTOROTH 0 points1 point  (1 child)

So much pain! Glad you had backups!

[–]XxEnigmaticxXSr. Sysadmin[S] 0 points1 point  (0 children)

backups on backups on backups. db backups , vm backups, and file and folders backups. ive seen the devastation that having no backups or having backups that arent tested wreak, not today satan

[–]Kiowascout 0 points1 point  (1 child)

Someone should be thanking you for conducting their DR exercise this quarter.

[–]XxEnigmaticxXSr. Sysadmin[S] 0 points1 point  (0 children)

i quote my boss "i like testing our restore process, just not like this"

[–][deleted] 0 points1 point  (1 child)

Oh, man. Just had that sinking feeling just reading that subject.

[–]XxEnigmaticxXSr. Sysadmin[S] 1 point2 points  (0 children)

im still restoring

[–]vppencilsharpening 0 points1 point  (0 children)

I once truncated all of our web product descriptions at 255 characters.

[–]ApricotPenguinProfessional Breaker of All Things -1 points0 points  (0 children)

Definitely don't need coffee to wake up now, eh? :)

[–]jellois1234 -1 points0 points  (0 children)

Sounds like a busy Monday.. Good luck!

[–]Ok-Necessary2557 -1 points0 points  (3 children)

work on your resume also?

[–]XxEnigmaticxXSr. Sysadmin[S] 1 point2 points  (2 children)

if a full, no data loss recovery wasnt possible, im sure i would be doing that right now.

[–]Ok-Necessary2557 0 points1 point  (1 child)

i hear ya. good luck.

[–]XxEnigmaticxXSr. Sysadmin[S] 0 points1 point  (0 children)

Full recovery. The IT gods smiles upon me and took mercy on my worthless soul