

How Ubuntu startup script deletes everything - mrud
https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/557177

======
jacquesm
I find the response of the maintainer to be typical of the kind of detached
attitude that you come across every now and then with issues reported.

I've had bugs converted to 'wontfix' and 'unconfirmed' in spite of giving
detailed info and / or situations where it clearly is a bug.

It shouldn't take a 'thinking over a cup of tea' to recognize this is highly
undesirable behaviour, a fix is practically free and very easy, the results of
executing that script are potentially very expensive.

It's a bug. Not a feature for the wishlist.

And I never did get why there has to be yet another way to start stuff up in
the first place. /etc/inittab, /etc/init.d/ and now 'upstart'...

It doesn't seem to be a great improvement over the previous system but
requires a bunch of new stuff to be learned and old stuff to be unlearned.
That should come with a clear advantage of sorts and I can't seem to find any.

~~~
krainboltgreene
Yay open source! Yay linux!

This is why I'm slowly backing away from anything to do with linux.

~~~
caffeine
Indeed, this is the sort of fiasco Microsoft _wishes_ that money could buy.
"I'm a PC ... because Windows DOESN'T wipe all your data without asking first.
"

But I think your comment is still vast overkill. The fact is, I get really,
really worried every time I see a BSOD'd airline departures board or worse, an
ATM booting up Windows (usually Win 2000). Don't these people _know_?! That
there's another OS out there called (GNU/)Linux and it's fast and free and
doesn't have a long tradition of crap engineering?

And then I see this and remember that while Linux is (mostly) well-engineered,
it has all sorts of equally well-engineered, completely unmarked "self-
destruct" buttons. And if there's anything scarier than Windows near
airplanes, it has to be Windows users near Linux near airplanes.

~~~
dhimes
_if there's anything scarier than Windows near airplanes, it has to be Windows
users near Linux near airplanes_

... an all-time great quote

------
moe

      On Wed, 2010-04-07 at 14:12 +0000, Thomas Krause wrote:
      > The problem is, that you don't know this script is
      > dangerous before you executed it.
    
      Then you should not execute it.
    
      Scott
      --
      Scott James Remnant
      <email address hidden>
    

Brilliant. Exactly what you want to hear when a seemingly innocent vendor
init-script just erased your harddrive.

~~~
noonespecial
A few comments down is a particularly rich response to this:

So, just to clarify that:

What you are basically saying is that the manpage stating

> start JOB... > Requests that the named jobs be started. The status of the
> jobs will be output to standard output until > they are succesfully running,
> or in the case of tasks, until they have completed.

should in fact be read as: "might either start the job or delete all your
data, and we neither check, warn or document regarding this issue anywhere
visibly"? Seriously?

------
SwellJoe
Ubuntu has a cultural problem at times, wherein sane bug reports from
experienced UNIX users are dismissed as "not getting it", or similar. There
seems to be a certain smugness when they make decisions that are obviously
wrong, and certitude where there shouldn't be. I don't know why this is so;
Debian has a somewhat argumentative culture, and occasionally makes dumb
decisions, but folks usually try to argue their way to a consensus rather than
just say "This is the way it is". Ubuntu has diverged from that seemingly
entirely, and maintainers sometimes make bizarre proclamations and stick to
them against all reason.

I think it's an interesting aspect of the different Linux distributions.
Someone else mentioned Gentoo being similar to Ubuntu in this regard, and I
would agree...though it takes it to such an extreme that it's hard for me to
even take it seriously as an OS. At least the end result of Ubuntu's
obstinance is pretty solid, even if every new release has some weird quirks
that I just can't figure out how they made it through QC (and more often than
I'm comfortable with, those quirks are intentional).

------
snorkel
I have a patch

    
    
       if [ -z $MOUNTPOINT ]; then 
        echo "MOUNTPOINT not defined.  Not deleting your file system.";
        exit(1); 
       fi
    

This patch will be included in Zippy Zebra due out in 2018

~~~
ableal
Those in a hurry please check this reply first:
[https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/55717...](https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/557177/comments/24)

------
viraptor
To add insult to insult to injury (the first insult was "Don't do that then"),
the person handling the bug is a member of the "Canonical User Experience and
Design team". It's like they're annoying people on purpose sometimes...

~~~
nas
Seriously, add a "set -e -u" to the top of the script and close the bug
already. He wasted more time arguing about it then it would take to fix it.

~~~
viraptor
This could be a default one day really... Like php disabling register_globals.
It would stop so many silly mistakes.

------
varikin
Reminds me of why I finally left Gentoo. Some maintainers started believing
that their default configurations where the only correct configurations. For
example, the Apache maintainer believed the virtual hosts was the correct way
to run Apache. I felt that my simple static html webpage didn't need that, so
I just used /etc/apache2/httpd.conf and /var/www/htdocs/index.html plus a
handfull of other static files.

Then around 2005 or so, an update to Apache replaced my httpd.conf with the
default and deleted everything in htdocs and added a default index.html. Lots
of people complained and the Gentoo maintainers said anyone not using virtual
hosts was wrong, so it was not their fault the user's lost all their data and
configuration on an upgrade.

After that, I started noticing more and more arguments from maintainers and
users. Frankly, I am glad I am no longer using Gentoo and fighting their
system. And I am glad I don't use Ubuntu and fighting their system either.

~~~
kgroll
What operating system are you currently using? I just transitioned from Ubuntu
to Gentoo, but now you've got me wondering if I have overlooked a better
alternative.

~~~
jrockway
Uh, Debian? It's like Ubuntu but the packages don't break your system as
often.

~~~
pyre
It's too bad that the last time I tried to install Debian the installer only
supported WEP for wireless installation.

~~~
jrockway
One thing that's nice about being a long-time Linux user is that you don't
even consider the possibility of installing over WiFi ;)

(Though to be fair, good luck installing Windows or OS X with a 256M memory
stick and a wireless router.)

------
DrJokepu
I think that this is a perfect illustration of software developers not being
real engineers as they don't think as engineers. My first degree is in
Mechanical Engineering and I can assure you that proper engineer would never
consider anything like that short of being an "absolutely critical flaw".
Real-life machines such as elevators or various industrial equipments have all
sorts of fail-safe mechanisms built in. These people aren't born with safety
always being the first thing they consider, it's something they are taught at
university.

Simply telling people to "don't do that" is not an adequate approach because
people make mistakes, it is part of human nature.

------
thingie
Such a lack of any failsafe behavior in a script that can potentially erase
whole disk should have been against all reasonable policies that
distribution's init scripts should have. I'm not a fan of Ubuntu, and I have
very, very low opinion about it, but still, there must be such guidelines and
policies. If there aren't, it's the primary bug.

~~~
nearestneighbor
Are you saying that other Linux distributions are better? It used to be that
Debian was more solid, but I don't think this is the case any more.

~~~
ismarc
Debian is still considerably more solid. However, improvements and software
development has outpaced the Debian release cycle. In order to be
"competitive" for what a large number of people want on the desktop side,
unstable or testing are the repo's they should be pulling from rather than
stable. However, unstable and testing are exactly that, unstable and testing,
and it can be pretty frustrating for unfamiliar users to have to deal with
kinks that haven't been worked out yet.

~~~
nearestneighbor
I didn't do any statistical survey of thousands of users, but I am using
Debian5 and Ubuntu8.04. The former feels and acts considerably more broken, in
my experience. This is in addition to being more pain to install. Just my
$0.02.

~~~
ismarc
The way Debian manages it, only bugfixes are added once something hit's
"stable" (current Debian 5). This means that drivers and new versions of
applications are typically frozen except for bug patches only. Debian 5 was
released a little over a year ago, leading to the software being outdated by
standard desktop/consumer use compared to the number of improvements and bugs
fixed in the mean time (most applications provide feature+bug releases which
are not added to Debian once it hits stable). For servers, this is reliable
and actually wonderful to deal with. For desktop/laptop systems, it can be
frustrating because the code exists, and it should be nice, easy and non-
broken for applications and drivers, but in reality it's not, because the
release is behind. Ubuntu's goal is to have a much quicker release cycle to
keep this from happening, but in the mean time never get a system that's
really 100% stable and usable. Ubuntu also does some weird crazy hacks to get
things to appear smooth to the user, when in reality they have pre-programmed
guesses you can't override. So if it doesn't work, the only recovery is
seasoned Linux experience. Debian, on the other hand, gives a large number of
options making the installation not seem as smooth, but is recoverable with
quick Google searches or reading of the explanations.

~~~
nearestneighbor
I know all this, as I've been using Debian/Ubuntu for years, but I think that
far fewer people are using Debian now than Ubuntu, resulting in less testing.
Developers probably migrated as well. People vote with their feet.

------
w00pla
This crap is the embodiment of everything that is wrong with Linux.

Another non-serious example. I used a dual-boot Linux&Vista laptop. Innocently
tried to update Ubuntu. This changed the boot loader to Ubuntu only (removed
the Windows menu).

This may be fine for me, but it fails the grandmother test (or any other test
of a normal casual computer user). Aren't updates tested before they are
added?

~~~
DrJokepu
To be fair, Windows would have overwritten the MBR (so that it boots Windows
only) without asking too many questions either.

~~~
youngian
I've actually taken to installing Windows on a separate hard drive, and
disconnecting my primary drive before I even begin the installation, because
I've had Windows screw so many things up.

------
ErrantX
If you check the recent update from the maintainer [1] this was just a
misunderstanding - it was fixed yesterday and the bug report was wishlisted as
an idea for a broader fix.

1\.
[https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/55717...](https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/557177/comments/24)

~~~
KC8ZKF
_In which he calls his detractors "flaming idiots" and tells them to pick up
their toys..._

~~~
ErrantX
yep, but not nastily. And in this instance I don't really blame him :)

------
jrockway
Quite the anti-Linux group of people here. I wonder how much data is silently
corrupted every day by OS X's lack of an atomic rename syscall...

~~~
pyre
Stories like this just become lightning rods for people with similar
grievances against the group in question. If there was a story about OS X
deleting all of your data, we would have threads full of people complaining
about how poorly Apple manages their operating system, and how they delete
threads on their forums about issues that don't want to address.

~~~
whatusername
Didn't that come out with Snow Leopard and Guest Accounts?
<http://www.appleinsider.com/article.php?id=12031>

------
jsz0
Sometimes I do wonder if these older established Linux distributions aren't
doomed to implode on themselves. There's just so much complexity and legacy
stuff all over the place that it's unsettling to me. I've been using Debian
based Linux distros for more than a decade and I'm still confused trigger shy
about doing certain things because I can't mentally calculate the outcome with
confidence or have a clear back-out plan if something goes wrong. This is
actually why I run Linux in a VM whenever possible. Snapshots have saved me so
many times.

------
lurkerperpetual
Actually: How an Ubuntu script which is not meant to be run manually,
temporarily had a bug that deleted the file system when using the _development
version_ of Ubuntu.

------
mmaunder
Added my 2c to the bug thread. Reposted here:

From: <http://www.ubuntu.com/education>

"Above all, Ubuntu is set apart from other operating systems by its unwavering
focus on simplicity and ease of use. Ubuntu's motto is "Linux for Human
Beings" and every development decision and application has that goal in mind."

------
unperson
Similar posting regarding the state of the community at Ubuntu:

[http://www.fewt.com/2010/03/bye-ubuntu-it-could-have-been-
fu...](http://www.fewt.com/2010/03/bye-ubuntu-it-could-have-been-fun-but.html)

------
sswam
what a lousy maintainer

~~~
davidw
I think he made a bad choice and didn't like his responses either, but from
that, on one bug report, to 'lousy maintainer' is pretty harsh.

------
sswam
I added a complaint to the bug report

~~~
gcr
No, that's not where complaints go.

Bug reports should hold information that explains how to fix the bug or how to
reproduce it. A complaint that says "me too! hurry up and fix it!" adds
nothing useful and pollutes the rest of the helpful posts there.

Post your "me too!" comments on the Ubuntu forums. That's the place for them.
Failing that, the "This bug affects me too [change]" button is more than
willing to listen.

------
xenophanes
This must be why the iPad doesn't have user runnable scripts.

------
nnutter
Uh, Seriously? Why would you run any command without knowing its purpose?
Should they also disable 'rm' because idiots wipe their system with that as
well?

Sure the maintainer is being a bit lazy about the issue but everyone always
thinks their problems are the most important in the world. Everyone
criticizing him is failing to question whether he may have more critical bugs,
ones where a stupid user isn't involved.

~~~
pak
Name any commonly used Linux executable that deletes the server root when run
without any arguments, with no confirmation or warning.

It's a little unexpected.

Even after reading the script, you may not catch the fact that not setting the
right environment variable causes massive damage--it's not documented
anywhere.

~~~
duskwuff
This isn't on Linux, granted, but killall will ignore its arguments and kill
_ALL_ accessible processes on a number of other UNIX-like OSes (such as
Solaris).

~~~
viraptor
I'd consider the name _killall_ to be both an explanation and a warning. But
yeah - I made that mistake once on Solaris. That's why you should never have
applications like that. Even _shutdown_ needs some option for scheduling when
it should work.

~~~
TallGuyShort
Even then - neither killall or shutdown is as serious as deleting the root
partition. It's the difference between a reboot and a complete
reinstall/restore from backup.

