Como parar o dist-upgrade de remover o MariaDB?

4

Uma pergunta semelhante foi feita em Atualização parcial - por que remover o MariaDB? . A resposta para essa pergunta foi basicamente afirmar que dist-upgrade é o problema. Esta questão está perguntando se existe alguma solução alternativa (ou correção).

Às vezes, é necessário fazer uma atualização distalizada e não apenas uma atualização.

Podemos mudar alguma coisa na nossa sources.list (ou em outro lugar) para dizer ao Ubuntu para NÃO remover o MariaDB?

marc@db01:~$ dpkg --get-selections | grep mysql
libdbd-mysql-perl    install
libmysqlclient18     install
mysql-common     install

marc@db01:~$ dpkg --get-selections | grep maria
libmariadbclient18 install
mariadb-client-10.0 deinstall
mariadb-client-5.5 install
mariadb-client-core-5.5 install
mariadb-common install
mariadb-server install
mariadb-server-10.0 deinstall
mariadb-server-5.5 install
mariadb-server-core-5.5 install

marc@db01:~$ sudo apt-get check
Reading package lists... Done
Building dependency tree
Reading state information... Done

marc@db01:~$ dpkg --list | grep mysql
ii libdbd-mysql-perl 4.020-1build2 Perl5 database interface to the MySQL database
ii libmysqlclient18 5.5.34+maria-1~precise Virtual package to satisfy external depends
ii mariadb-common 5.5.34+maria-1~precise MariaDB database common files (e.g. /etc/mysql/conf.d/mariadb.cnf)
ii mysql-common 5.5.34+maria-1~precise MariaDB database common files (e.g. /etc/mysql/my.cnf)

marc@db01:~$ sudo apt-get dist-upgrade -o Debug::pkgProblemResolver=true -o Debug::pkgProblemResolver::ShowScores=true 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Starting
Settings used to calculate pkgProblemResolver::Scores::
  Important => 3
  Required => 2
  Standard => 1
  Optional => -1
  Extra => -2
  Essentials => 100
  InstalledAndNotObsolete => 1
  Depends => 1
  Recommends => 1
  AddProtected => 10000
  AddEssential => 5000
Show Scores
10000 linux-image-3.8.0-29-generic [ amd64 ] < 3.8.0-29.42~precise1 > ( kernel )
6306 dpkg [ amd64 ] < 1.16.1.2ubuntu7.2 > ( admin )
5409 libc-bin [ amd64 ] < 2.15-0ubuntu10.5 > ( libs )
5371 debianutils [ amd64 ] < 4.2.1ubuntu2 > ( utils )
53 libsqlite3-0 [ amd64 ] < 3.7.9-2ubuntu1.1 > ( libs )
10 mariadb-common [ amd64 ] < 5.5.34+maria-1~precise > ( database )
8 mysql-common [ amd64 ] < 5.5.34+maria-1~precise -> 5.5.35-0ubuntu0.12.04.1 > (database )
6 libmariadbclient18 [ amd64 ] < 5.5.34+maria-1~precise > ( libs )
6 libmysqlclient18 [ amd64 ] < 5.5.34+maria-1~precise -> 5.5.35-0ubuntu0.12.04.1 > ( libs )
2 mariadb-client-5.5 [ amd64 ] < 5.5.34+maria-1~precise > ( misc )
2 mariadb-server-core-5.5 [ amd64 ] < 5.5.34+maria-1~precise > ( misc )
2 mariadb-client-core-5.5 [ amd64 ] < 5.5.34+maria-1~precise > ( misc )
1 mariadb-server-5.5 [ amd64 ] < 5.5.34+maria-1~precise > ( misc )
Starting 2
Investigating (0) mysql-common [ amd64 ] < 5.5.34+maria-1~precise -> 5.5.35-0ubuntu0.12.04.1 > ( database )
Broken mysql-common:amd64 Breaks on mysql-client-5.1 [ amd64 ] < none > ( none )
  Conflicts//Breaks against version 10.0.7+maria-1~precise for mariadb-client-10.0 but that is not InstVer, ignoring
  Considering mariadb-client-5.5:amd64 2 as a solution to mysql-common:amd64 8
  Added mariadb-client-5.5:amd64 to the remove list
Broken mysql-common:amd64 Breaks on mysql-client-core-5.1 [ amd64 ] < none > ( none )
  Considering mariadb-client-core-5.5:amd64 2 as a solution to mysql-common:amd64 8
  Added mariadb-client-core-5.5:amd64 to the remove list
Broken mysql-common:amd64 Breaks on mysql-server-core-5.1 [ amd64 ] < none > ( none )
  Considering mariadb-server-core-5.5:amd64 2 as a solution to mysql-common:amd64 8
  Added mariadb-server-core-5.5:amd64 to the remove list
  Conflicts//Breaks against version 5.5.34+maria-1~precise for mariadb-galera-server-5.5 but that is not InstVer, ignoring
  Fixing mysql-common:amd64 via remove of mariadb-client-5.5:amd64
  Fixing mysql-common:amd64 via remove of mariadb-client-core-5.5:amd64
  Fixing mysql-common:amd64 via remove of mariadb-server-core-5.5:amd64
Investigating (0) libmariadbclient18 [ amd64 ] < 5.5.34+maria-1~precise > ( libs )
Broken libmariadbclient18:amd64 Depends on libmysqlclient18 [ amd64 ] < 5.5.34+maria-1~precise -> 5.5.35-0ubuntu0.12.04.1 > ( libs ) (= 5.5.34+maria-1~precise)
  Considering libmysqlclient18:amd64 6 as a solution to libmariadbclient18:amd64 6
  Removing libmariadbclient18:amd64 rather than change libmysqlclient18:amd64
Investigating (0) mariadb-server-5.5 [ amd64 ] < 5.5.34+maria-1~precise > ( misc )
Broken mariadb-server-5.5:amd64 Depends on mariadb-client-5.5 [ amd64 ] < 5.5.34+maria-1~precise > ( misc ) (>= 5.5.34+maria-1~precise)
  Considering mariadb-client-5.5:amd64 2 as a solution to mariadb-server-5.5:amd64 1
  Removing mariadb-server-5.5:amd64 rather than change mariadb-client-5.5:amd64
Investigating (0) mariadb-server [ amd64 ] < 5.5.34+maria-1~precise > ( database )
Broken mariadb-server:amd64 Depends on mariadb-server-5.5 [ amd64 ] < 5.5.34+maria-1~precise > ( misc ) (= 5.5.34+maria-1~precise)
  Considering mariadb-server-5.5:amd64 1 as a solution to mariadb-server:amd64 0
  Removing mariadb-server:amd64 rather than change mariadb-server-5.5:amd64
Done
Done
The following packages will be REMOVED:
  libmariadbclient18 mariadb-client-5.5 mariadb-client-core-5.5 mariadb-server
  mariadb-server-5.5 mariadb-server-core-5.5
The following packages will be upgraded:
  libmysqlclient18 mysql-common
2 upgraded, 0 newly installed, 6 to remove and 0 not upgraded.
Need to get 957 kB of archives.
After this operation, 107 MB disk space will be freed.
Do you want to continue [Y/n]? n
Abort.
marc@db01:~$

Agora que o MariaDB atualizou o PPA:

marc@db01:~$ apt-cache show mysql-common | grep Version
Version: 5.5.35+maria-1~precise
Version: 5.5.35-0ubuntu0.12.04.2
Version: 5.5.35-0ubuntu0.12.04.1
Version: 5.5.22-0ubuntu1
marc@db01:~$ apt-cache show libmysqlclient18 | grep Version
Version: 5.5.35+maria-1~precise
Version: 5.5.35-0ubuntu0.12.04.2
Version: 5.5.35-0ubuntu0.12.04.1
Version: 5.5.22-0ubuntu1

marc@db01:~$ sudo apt-get dist-upgrade
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    
por vegantriathlete 22.01.2014 / 19:44

2 respostas

0
Broken mysql-common:amd64 Breaks on mysql-client-5.1 [ amd64 ]  ( none )
  Conflicts//Breaks against version 10.0.7+maria-1~precise for mariadb-client-10.0 but that is not InstVer, ignoring
  Considering mariadb-client-5.5:amd64 2 as a solution to mysql-common:amd64 8
  Added mariadb-client-5.5:amd64 to the remove list

Como pode ser visto, MariaDB quebra se você tentar atualizar o mysql. Você deve confiar apenas no sudo apt-get upgrade para evitar a remoção do MariaDB.

    
por Braiam 26.01.2014 / 22:50
0

MariaDB cobre isso em seu artigo sobre a instalação de pacotes deb, a melhor maneira de corrigi-lo é fixando o repositório MariaDB. O que você pode fazer seguindo estas instruções: link (se você rolar para cima, eles também explicam por que isso acontece)

    
por y3kdaniel 26.01.2014 / 22:17

Tags