Bug#617796: [debian-mysql] Bug#617796: mysql-server-5.1: Upgrade of debian, stable silently ERASED my years old mysql database (no backup)

2011-03-24 Thread Olaf van der Spek
 maybe this bug should rather be closed. The submitter purged 
mysql-server and  that did what it's supposed to do...


I don't agree. Purging vi also doesn't remove all files you ever edited...

I assume the debconf question is asked at install time, which could be 
years before the purge is done.
IMO it's way easier and safer to drop the question and to drop the 
removal of the databases themselves.


Olaf



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#617796: [debian-mysql] Bug#617796: Bug#617796: mysql-server-5.1: Upgrade of debian, stable silently ERASED my years old mysql database (no backup)

2011-03-24 Thread Norbert Tretkowski

Am 24.03.11 11:26, schrieb Olaf van der Spek:
 I don't agree. Purging vi also doesn't remove all files you ever
 edited...

Uh, bad example.


I assume the debconf question is asked at install time, which could be
years before the purge is done.


No, the deconf question gets asked when the package gets purged.


Regards

Norbert



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#617796: mysql-server-5.1: Upgrade of debian stable silently ERASED my years old mysql database (no backup)

2011-03-11 Thread Carlo Wood
Package: mysql-server-5.1
Version: 5.1.49-3
Severity: critical
Justification: causes serious data loss

I have a head-less debian stable system that never requires attention
or maintenance.  It runs my firewall, a mail server with spam filters
and an apache webserver for a website based on php sripts that connect
to a mysql database. This website allows users to register and then
keeps track of where they are, comments, and their email address if
they wish to be informed upon updates. I had over 5000 registered
users.

A few weeks ago I decided to upgrade the server and ran,
apt-get update; apt-get dist-upgrade
That didn't go *entirely* flawless, but within an hour I had
everything updated... sorry, but I can't even remember if I
checked if the website still worked after that :/. The website
needs a manual nfs mount every reboot that I often forget too,
in the rare events that this box is ever rebooted (it's really
a just sits there box that I don't think about much).

Yesterday a user of the website mailed me, saying that he
hadn't been able to log into the website or use it for several
weeks and wondered if I was going to fix it.

To my surprise there wasn't a mysqld running... not even
the package was installed.  So, I installed the mysql-server-5.1
package. Website still didn't work, because I couldn't even
log in with myphpadmin. So, I reset the password for the root
user to what I normally use... and indeed myphpadmin could
now login and showed: nothing. An empty, fresly installed database.

Never - anywhere - ever - I got a single warning or question.
I searched high and low - but the old database is gone.
In /var/lib/mysql is only a new fresh install with no trace
of the old data.

I'm sure it's too late for me to recover anything, but really,
HOW THE HELL COULD THIS EVER HAPPEN???

-- System Information:
Debian Release: 6.0
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages mysql-server-5.1 depends on:
ii  adduser 3.112+nmu2   add and remove users and groups
ii  debconf [de 1.5.36.1 Debian configuration management sy
ii  libc6   2.11.2-10Embedded GNU C Library: Shared lib
ii  libdbi-perl 1.612-1  Perl Database Interface (DBI)
ii  libgcc1 1:4.4.5-8GCC support library
ii  libmysqlcli 5.1.49-3 MySQL database client library
ii  libstdc++6  4.4.5-8  The GNU Standard C++ Library v3
ii  lsb-base3.2-23.2squeeze1 Linux Standard Base 3.2 init scrip
ii  mysql-clien 5.1.49-3 MySQL database client binaries
ii  mysql-commo 5.1.49-3 MySQL database common files, e.g. 
ii  mysql-serve 5.1.49-3 MySQL database server binaries
ii  passwd  1:4.1.4.2+svn3283-2+squeeze1 change and administer password and
ii  perl5.10.1-17Larry Wall's Practical Extraction 
ii  psmisc  22.11-1  utilities that use the proc file s
ii  zlib1g  1:1.2.3.4.dfsg-3 compression library - runtime

Versions of packages mysql-server-5.1 recommends:
ii  bsd-mailx [mailx]  8.1.2-0.20100314cvs-1 simple mail user agent
ii  libhtml-template-p 2.9-2 module for using HTML Templates wi
ii  mailx  1:20071201-3  Transitional package for mailx ren

Versions of packages mysql-server-5.1 suggests:
pn  tinycanone (no description available)

-- debconf information:
  mysql-server-5.1/postrm_remove_databases: false
  mysql-server-5.1/really_downgrade: false
  mysql-server/error_setting_password:
  mysql-server-5.1/start_on_boot: true
  mysql-server-5.1/nis_warning:
  mysql-server/password_mismatch:
  mysql-server/no_upgrade_when_using_ndb:



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#617796: [debian-mysql] Bug#617796: mysql-server-5.1: Upgrade of debian stable silently ERASED my years old mysql database (no backup)

2011-03-11 Thread Norbert Tretkowski
Am Freitag, den 11.03.2011, 14:48 +0100 schrieb Carlo Wood:
 That didn't go *entirely* flawless, but within an hour I had
 everything updated...

Could you please send me your /var/log/dpkg.log from the day when you
upgraded your machine?


Regards

Norbert




-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#617796: [debian-mysql] Bug#617796: mysql-server-5.1: Upgrade of debian stable silently ERASED my years old mysql database (no backup)

2011-03-11 Thread Norbert Tretkowski
Am Freitag, den 11.03.2011, 16:22 +0100 schrieb Carlo Wood:
 Hi, the upgrade was done on Feb 2, 2011. The logs
 of that are attached as dpkg.log.2.gz

If you mean Feb 7, then mysql-server-5.0 was purged at that day:

2011-02-07 21:03:29 purge mysql-server-5.0 5.0.51a-24+lenny4 5.0.51a-24+lenny4

According to your debconf settings, you will see a question asking you
if you want to purge the databases as well, but it only removes the
database files if you explicitly tell debconf to do so, the default is
to keep the database files.

I just purged the mysql-server* packages from one of my systems, but
after that it still has the /var/lib/mysql/ directory containing the
databases.


Regards

Norbert




-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#617796: [debian-mysql] Bug#617796: mysql-server-5.1: Upgrade of debian stable silently ERASED my years old mysql database (no backup)

2011-03-11 Thread Carlo Wood
On Fri, 11 Mar 2011 16:55:51 +0100
Norbert Tretkowski norb...@tretkowski.de wrote:

Well... I guess I did that -- at the moment not
thinking / remembering what I needed a sql database
for... But I feel still pissed that it didn't warn
me a little bit more clear before actually deleting
database files :/... I mean... It should be possible
to ask for confirmation in a way that I would have
hesitated right? Like when you try to format a
harddisk: *** ALL DATA WILL BE LOST *** kind of thing?

Nevertheless, you say you just purged a package
and the database is still there? It definitely isn't
here :/ So, when did it get deleted? And by what?

If reinstalling the package simply overwrote the old
database then that is bug: it should never do that.

Also, I looked with ext3grep if I could see anything
(although I wasn't, and still am, not even sure what
file to look for) and I could find any trace of anything
deleted in /var/lib/mysql.

 Am Freitag, den 11.03.2011, 16:22 +0100 schrieb Carlo Wood:
  Hi, the upgrade was done on Feb 2, 2011. The logs
  of that are attached as dpkg.log.2.gz
 
 If you mean Feb 7, then mysql-server-5.0 was purged at that day:
 
 2011-02-07 21:03:29 purge mysql-server-5.0 5.0.51a-24+lenny4
 5.0.51a-24+lenny4
 
 According to your debconf settings, you will see a question asking you
 if you want to purge the databases as well, but it only removes the
 database files if you explicitly tell debconf to do so, the default is
 to keep the database files.
 
 I just purged the mysql-server* packages from one of my systems, but
 after that it still has the /var/lib/mysql/ directory containing the
 databases.
 
 
 Regards
 
 Norbert
 



-- 
Carlo Wood ca...@alinoe.com



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#617796: [debian-mysql] Bug#617796: mysql-server-5.1: Upgrade of debian stable silently ERASED my years old mysql database (no backup)

2011-03-11 Thread Norbert Tretkowski
Am Freitag, den 11.03.2011, 17:28 +0100 schrieb Carlo Wood:
 Nevertheless, you say you just purged a package
 and the database is still there? It definitely isn't
 here :/ So, when did it get deleted? And by what?

I don't know.

 If reinstalling the package simply overwrote the old
 database then that is bug: it should never do that.

The database files are still there after reinstalling the mysql-server
package.

Purging and reinstalling mysql-server doesn't overwrite your existing
databases:

mysql create database bug617796;
Query OK, 1 row affected (0.00 sec)

mysql show databases;
++
| Database   |
++
| information_schema |
| bug617796  |
| mysql  |
++
3 rows in set (0.00 sec)

# dpkg --purge mysql-server-core-5.1 mysql-server-5.1
(Lese Datenbank ... 35080 Dateien und Verzeichnisse sind derzeit
installiert.)
Entfernen von mysql-server-5.1 ...
Stopping MySQL database server: mysqld.
Löschen der Konfigurationsdateien von mysql-server-5.1 ...
Entfernen von mysql-server-core-5.1 ...
Trigger für man-db werden verarbeitet ...

v80178.ddc-ipx.de:~# apt-get --no-install-recommends install mysql-server-5.1
Paketlisten werden gelesen... Fertig
Abhängigkeitsbaum wird aufgebaut   
Statusinformationen werden eingelesen... Fertig
Die folgenden zusätzlichen Pakete werden installiert:
  mysql-server-core-5.1
Vorgeschlagene Pakete:
  tinyca
Empfohlene Pakete:
  libhtml-template-perl
Die folgenden NEUEN Pakete werden installiert:
  mysql-server-5.1 mysql-server-core-5.1
0 aktualisiert, 2 neu installiert, 0 zu entfernen und 0 nicht
aktualisiert.
Es müssen noch 0 B von 10,9 MB an Archiven heruntergeladen werden.
Nach dieser Operation werden 26,7 MB Plattenplatz zusätzlich benutzt.
Möchten Sie fortfahren [J/n]? 
Vorkonfiguration der Pakete ...
Vormals abgewähltes Paket mysql-server-core-5.1 wird gewählt.
(Lese Datenbank ... 34914 Dateien und Verzeichnisse sind derzeit
installiert.)
Entpacken von mysql-server-core-5.1
(aus .../mysql-server-core-5.1_5.1.56-1_amd64.deb) ...
Vormals abgewähltes Paket mysql-server-5.1 wird gewählt.
Entpacken von mysql-server-5.1
(aus .../mysql-server-5.1_5.1.56-1_amd64.deb) ...
Trigger für man-db werden verarbeitet ...
mysql-server-core-5.1 (5.1.56-1) wird eingerichtet ...
mysql-server-5.1 (5.1.56-1) wird eingerichtet ...
Stopping MySQL database server: mysqld.
Starting MySQL database server: mysqld.

# mysql -p -e show databases;
Enter password: 
++
| Database   |
++
| information_schema |
| bug617796  |
| mysql  |
++


Regards

Norbert




--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org