{"id":20924,"date":"2016-04-14T12:26:17","date_gmt":"2016-04-14T16:26:17","guid":{"rendered":"http:\/\/angry.net\/blog2\/?p=20924"},"modified":"2016-04-14T12:26:17","modified_gmt":"2016-04-14T16:26:17","slug":"how-to-destroy-your-company-with-one-line-of-code","status":"publish","type":"post","link":"https:\/\/angry.net\/blog2\/?p=20924","title":{"rendered":"How to destroy your company with one line of code"},"content":{"rendered":"<p>Good day all, this the Angry Systems Administrator. I\u2019ve bludgeoned the Angry Webmaster and tied him to a chair so I can write for a change. I just read a story about a man who wiped out his entire company with one single line of code.<\/p>\n<p><a href=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/09\/Macaque-Selfie.jpg\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-19152\" src=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/09\/Macaque-Selfie-264x300.jpg?resize=264%2C300\" alt=\"Macaque-Selfie\" width=\"264\" height=\"300\" srcset=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/09\/Macaque-Selfie.jpg?resize=264%2C300&amp;ssl=1 264w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/09\/Macaque-Selfie.jpg?resize=500%2C569&amp;ssl=1 500w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/09\/Macaque-Selfie.jpg?w=640&amp;ssl=1 640w\" sizes=\"auto, (max-width: 264px) 100vw, 264px\" \/><\/a><\/p>\n<p><!--more--><\/p>\n<p>As a Systems Administrator\/Engineer, when I read this story I just had to shake my head at how stupid this guy was. He apparently was deleting some data on a UNIX system and he carelessly used the \u201cDestroy everything from here on down!\u201d command, rm -rf *. This command, if run from the wrong location, will irretrievably delete everything in and below the directory you start in, and the -rf switch forces this to happen and not ask \u201cDo you really want to wreck your business? Y\/N\u201d Here are the details of the death of a company from <a href=\"http:\/\/www.independent.co.uk\/life-style\/gadgets-and-tech\/news\/man-accidentally-deletes-his-entire-company-with-one-line-of-bad-code-a6984256.html\" target=\"_blank\">The Independent<\/a>:<\/p>\n<p style=\"padding-left: 30px;\"><b>A man appears to have deleted his entire company with one mistaken piece of code.<\/b><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/08\/triple-facepalm.jpg\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-18887\" src=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/08\/triple-facepalm-300x161.jpg?resize=300%2C161\" alt=\"triple facepalm\" width=\"300\" height=\"161\" srcset=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/08\/triple-facepalm.jpg?resize=300%2C161&amp;ssl=1 300w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/08\/triple-facepalm.jpg?resize=500%2C268&amp;ssl=1 500w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/08\/triple-facepalm.jpg?w=665&amp;ssl=1 665w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p style=\"padding-left: 30px;\"><b>By accidentally telling his computer to delete everything in his servers, hosting provider Marco Marsala has seemingly removed all trace of his company and the websites that he looks after for his customers.<\/b><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/09\/Epic_Facepalm_by_RJTH.jpg\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-15907\" src=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/09\/Epic_Facepalm_by_RJTH-300x225.jpg?resize=300%2C225\" alt=\"Epic_Facepalm_by_RJTH\" width=\"300\" height=\"225\" srcset=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/09\/Epic_Facepalm_by_RJTH.jpg?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/09\/Epic_Facepalm_by_RJTH.jpg?resize=500%2C375&amp;ssl=1 500w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/09\/Epic_Facepalm_by_RJTH.jpg?w=900&amp;ssl=1 900w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>Marco went on some forums asking for advice and assistance. What he got was \u201cYou\u2019re Screwed Dude!\u201d instead.<\/p>\n<p style=\"padding-left: 30px;\"><b>Far from advising them how to fix it, most experts informed him that he had just accidentally deleted the data of his company and its clients, and in so doing had probably destroyed his entire company with just one line of code.<\/b><\/p>\n<p>As I mentioned above, Marsala wrote a script and used the rm -rf command, and ran it without verifying what was going to happen. Going on the forums for help in such a circumstance is a good way to be utterly humiliated.<\/p>\n<p style=\"padding-left: 30px;\"><strong>That piece of code is so famously destructive that it has become a joke within some computing circles.<\/strong><\/p>\n<p>It is a joke, but also no laughing matter when you accidentally run it from either the wrong location, or in this case, from a script that he didn\u2019t bother to double check. Normally, when you do something this stupid, you find out just how good your back up strategy is. In Marco Marsala\u2019s case, not very good would be an understatement.<\/p>\n<p style=\"text-align: left; padding-left: 30px;\"><b>Mr Marsala confirmed that the code had even deleted all of the backups that he had taken in case of catastrophe. Because the drives that were backing up the computers were mounted to it, the computer managed to wipe all of those, too. \u201cAll servers got deleted and the offsite backups too because the remote storage was mounted just before by the same script (that is a backup maintenance script).\u201d<\/b><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/03\/headdesk.jpg\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-17445\" src=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/03\/headdesk-300x225.jpg?resize=300%2C225\" alt=\"headdesk\" width=\"300\" height=\"225\" srcset=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/03\/headdesk.jpg?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/03\/headdesk.jpg?w=449&amp;ssl=1 449w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>Do I even need to go into how many things this guy did wrong? Why not? I\u2019m feeling really nasty right now. First, he didn\u2019t double check his script. Second, he didn\u2019t make sure his offsite backups were isolated and actually secure. I suspect he had a mounted share on his system and his backup tool pushed the archives to it. Finally, he didn\u2019t have his backups on separate media such as tape. Yes, that is expensive, but not as expensive as this fiasco is going to be for him.<\/p>\n<p style=\"padding-left: 30px;\">\u201c<b>I feel sorry to say that your company is now essentially dead,\u201d wrote a user called Sven. \u201cYou might have an extremely slim chance to recover from this if you turn off everything right now and hand your disks over to a reputable data recovery company. <\/b><\/p>\n<p style=\"padding-left: 30px;\">\u201c<b>This will be extremely expensive and still extremely unlikely to really rescue you, and it will take a lot of time.\u201d <\/b><\/p>\n<p>That would be an understatement. Not to bring up Hillary Clinton\u2019s mail server, but, as I understand it, that was a Windows based mail system and when she ordered it erased, the hosting service simply formatted the drive. Since this isn\u2019t a true erasure, the FBI was able to restore the data. Considering the time involved, you can bet this cost a lot of money and manpower with their computer forensics people.<\/p>\n<p style=\"padding-left: 30px;\"><b>Others agreed that perhaps Mr Marsala was on the wrong forum. <\/b><\/p>\n<p style=\"padding-left: 30px;\">\u201c<b>You&#8217;re going out of business,\u201d wrote Michael Hampton. \u201cYou don&#8217;t need technical advice, you need to call your lawyer.\u201d <\/b><\/p>\n<p>Actually, I think he should have gone to the Suicide Prevention and Intervention forums instead. Once his clients figure out they are screwed, they\u2019re going to obliterate him financially. The ever helpful forums were quick to pile on and berate Marsala.<\/p>\n<p style=\"padding-left: 30px;\"><b>Many of the responses to Mr Marsala\u2019s problem weren\u2019t especially helpful \u2013 pointing out that he could have taken steps to stop it happening before it did. <\/b><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2016\/03\/shocked-face.png\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-20636\" src=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2016\/03\/shocked-face-300x225.png?resize=300%2C225\" alt=\"shocked-face\" width=\"300\" height=\"225\" srcset=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2016\/03\/shocked-face.png?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2016\/03\/shocked-face.png?w=400&amp;ssl=1 400w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p style=\"padding-left: 30px;\">\u201c<b>Well, you should have been thinking about how to protect your customers&#8217; data before nuking them,\u201d wrote one person calling himself Massimo. \u201cI won&#8217;t even begin enumerating how many errors are simultaneously required in order to be able to completely erase all your servers and all your backups in a single strike. <\/b><\/p>\n<p style=\"padding-left: 30px;\">\u201c<b>This is not bad luck: it&#8217;s astonishingly bad design reinforced by complete carelessness. <\/b><\/p>\n<p><a href=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/02\/captain_obvious.jpg\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-17187\" src=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/02\/captain_obvious-300x182.jpg?resize=300%2C182\" alt=\"captain_obvious\" width=\"300\" height=\"182\" srcset=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/02\/captain_obvious.jpg?resize=300%2C182&amp;ssl=1 300w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/02\/captain_obvious.jpg?w=370&amp;ssl=1 370w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p>You would be amazed how often something like this happens. I\u2019ve had it happen to me, although not to this level of failure. I worked for a company that lost a 1.5TB database and spent a wonderful 36 hours restoring it from multiple backup tapes, and then restoring the incremental backups to bring the database back to the most recent version.<\/p>\n<p>When that happened, it wasn\u2019t something I did, it was something the DBA didn\u2019t do. We upgraded the firmware on our storage array, and he had forgotten to secure a critical configuration file. (He had implemented it between the final backup and the upgrade and didn\u2019t tell anyone)<\/p>\n<p>I feel sorry for Marco Marsala, but I\u2019m sure he will do very well in his new career in the food service industry.<\/p>\n<p>Thank you<\/p>\n<p><a href=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2013\/12\/dr_strangelove_1ed07.jpg\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-medium wp-image-13627\" src=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2013\/12\/dr_strangelove_1ed07-300x225.jpg?resize=300%2C225\" alt=\"The Angry Systems Administrator\" width=\"300\" height=\"225\" srcset=\"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2013\/12\/dr_strangelove_1ed07.jpg?resize=300%2C225&amp;ssl=1 300w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2013\/12\/dr_strangelove_1ed07.jpg?resize=150%2C112&amp;ssl=1 150w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2013\/12\/dr_strangelove_1ed07.jpg?resize=400%2C300&amp;ssl=1 400w, https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2013\/12\/dr_strangelove_1ed07.jpg?w=1024&amp;ssl=1 1024w\" sizes=\"auto, (max-width: 300px) 100vw, 300px\" \/><\/a><\/p>\n<p><i><b>~The Angry Systems Administrator~<\/b><\/i><\/p>\n<p>[yasr_visitor_votes size=&#8221;medium&#8221;]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Good day all, this the Angry Systems Administrator. I\u2019ve bludgeoned the Angry Webmaster and tied him to a chair so I can write for a change. I just read a story about a man who wiped out his entire company &hellip; <a href=\"https:\/\/angry.net\/blog2\/?p=20924\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"advanced_seo_description":"","jetpack_seo_html_title":"","jetpack_seo_noindex":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[176,141,135,71,115,57,219],"tags":[94,222,15,101,110,34,57],"class_list":["post-20924","post","type-post","status-publish","format-standard","hentry","category-economy","category-jobs","category-just-desserts","category-news-of-the-day","category-stupidity-crime","category-technology","category-the-good-idea-fairy","tag-chump-of-the-week","tag-good-idea-fairy","tag-incompetence","tag-news","tag-scoamf","tag-stupidity","tag-technology"],"views":814,"jetpack_featured_media_url":"","jetpack-related-posts":[{"id":18700,"url":"https:\/\/angry.net\/blog2\/?p=18700","url_meta":{"origin":20924,"position":0},"title":"Anger Central under DDOS attack","author":"Angry Systems Administrator","date":"August 9, 2015","format":false,"excerpt":"Good day all, this is the Angry Systems Administrator. Yesterday I started getting alerts that our web site, both the main site and the blog, were going up and down like a yoyo.","rel":"","context":"In &quot;Crime&quot;","block_context":{"text":"Crime","link":"https:\/\/angry.net\/blog2\/?cat=3"},"img":{"alt_text":"Clippy","src":"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2015\/02\/Clippy-294x300.jpg?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":20666,"url":"https:\/\/angry.net\/blog2\/?p=20666","url_meta":{"origin":20924,"position":1},"title":"Daylight Savings Time","author":"Angry Systems Administrator","date":"March 13, 2016","format":false,"excerpt":"Hello all, this is the Angry Systems Administrator coming to you with a Public Service Announcement. Daylight Savings Time has begun. If you haven't done so, turn your clocks ahead one hour. Unless, of course, you are in a country that doesn't bother with such foolishness. Personally, I think this\u2026","rel":"","context":"In &quot;General&quot;","block_context":{"text":"General","link":"https:\/\/angry.net\/blog2\/?cat=32"},"img":{"alt_text":"The Angry Systems Administrator","src":"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2013\/12\/dr_strangelove_1ed07-300x225.jpg?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":17086,"url":"https:\/\/angry.net\/blog2\/?p=17086","url_meta":{"origin":20924,"position":2},"title":"Review: The Interview","author":"Angry Systems Administrator","date":"January 24, 2015","format":false,"excerpt":"Good day all. This is the Angry Systems Administrator. the Seth Rogen movie, The Interview, was released today on Netflix. Since it's snowing out and I'm stuck in the Data Center, I logged in to watch it.","rel":"","context":"In &quot;Economy&quot;","block_context":{"text":"Economy","link":"https:\/\/angry.net\/blog2\/?cat=176"},"img":{"alt_text":"canceled","src":"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/12\/canceled-300x126.jpeg?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":25338,"url":"https:\/\/angry.net\/blog2\/?p=25338","url_meta":{"origin":20924,"position":3},"title":"That incompetent IDIOT!","author":"Angry Systems Administrator","date":"November 26, 2017","format":false,"excerpt":"Good day all. This is the Angry Systems Administrator. You may have noticed that the site was down for about an 40 minutes, a little over an hour ago. The reason is simple. I made the mistake of letting that inept, incompetent moron, also known as the Angry Webmaster, have\u2026","rel":"","context":"In &quot;General&quot;","block_context":{"text":"General","link":"https:\/\/angry.net\/blog2\/?cat=32"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/10\/recovering-dumbass-300x219.jpg?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":19095,"url":"https:\/\/angry.net\/blog2\/?p=19095","url_meta":{"origin":20924,"position":4},"title":"Facebook \u201cDislike\u201d button, coming soon!","author":"Angry Systems Administrator","date":"September 20, 2015","format":false,"excerpt":"Good day all, this is the Angry Systems Administrator. It's been a while, but a new \u201cthing\u201d is apparently coming to Facebook. They are finally going to bow to the inevitable and create a \u201cDislike\u201d button.","rel":"","context":"In &quot;News of the Day&quot;","block_context":{"text":"News of the Day","link":"https:\/\/angry.net\/blog2\/?cat=71"},"img":{"alt_text":"The-Good-Idea-Fairy-3","src":"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2014\/07\/The-Good-Idea-Fairy-3-268x300.jpg?resize=350%2C200","width":350,"height":200},"classes":[]},{"id":25721,"url":"https:\/\/angry.net\/blog2\/?p=25721","url_meta":{"origin":20924,"position":5},"title":"Yet another broken plugin","author":"Angry Systems Administrator","date":"February 8, 2018","format":false,"excerpt":"Good day all, this is the Angry Systems Administrator. I just tried running an update for the Disqus plugin we use for comments on this site. It's safe to say that the update was \"Not Ready for Prime Time.\" The update ran normally, and when completed, broke the Blog. Fortunately,\u2026","rel":"","context":"In &quot;General&quot;","block_context":{"text":"General","link":"https:\/\/angry.net\/blog2\/?cat=32"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/angry.net\/blog2\/wp-content\/uploads\/2016\/11\/totally-shocked-300x200.jpg?resize=350%2C200","width":350,"height":200},"classes":[]}],"_links":{"self":[{"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=\/wp\/v2\/posts\/20924","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=20924"}],"version-history":[{"count":3,"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=\/wp\/v2\/posts\/20924\/revisions"}],"predecessor-version":[{"id":20927,"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=\/wp\/v2\/posts\/20924\/revisions\/20927"}],"wp:attachment":[{"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=20924"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=20924"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/angry.net\/blog2\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=20924"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}