Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a server running on Debian wheezy with MaraiDB and OwnCloud. Few days ago, I wanted to update the packages because of the OwnCloud updates but something went wrong.

Usually in this case I'd probably try to remove and again install the problematic packages, but on a server which is used by different people it doesn't seem like a valid solution anymore.

Here you can see my console output:

user@server:~$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
 libmariadbclient18 : Depends: libmysqlclient18 (= 10.0.4+maria-1~wheezy) but 10.0.5+maria-1~wheezy is installed
 libmysqlclient18 : Depends: libmariadbclient18 (= 10.0.5+maria-1~wheezy) but 10.0.4+maria-1~wheezy is installed
 mariadb-client-10.0 : Depends: libmariadbclient18 (>= 10.0.5+maria-1~wheezy) but 10.0.4+maria-1~wheezy is installed
 mariadb-client-core-10.0 : Depends: libmariadbclient18 (>= 10.0.5+maria-1~wheezy) but 10.0.4+maria-1~wheezy is installed
 mariadb-server : Depends: mariadb-server-10.0 (= 10.0.5+maria-1~wheezy) but 10.0.4+maria-1~wheezy is installed
 mariadb-server-core-10.0 : Depends: libmariadbclient18 (>= 10.0.5+maria-1~wheezy) but 10.0.4+maria-1~wheezy is installed
E: Unmet dependencies. Try using -f.

user@server:~$ sudo apt-get upgrade -f
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following packages will be upgraded:
  libmariadbclient18 mariadb-server-10.0 owncloud
3 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
7 not fully installed or removed.
Need to get 0 B/37.2 MB of archives.
After this operation, 3,565 kB of additional disk space will be used.
Do you want to continue [Y/n]? Y
Preconfiguring packages ...
(Reading database ... 35901 files and directories currently installed.)
Preparing to replace libmariadbclient18 10.0.4+maria-1~wheezy (using .../libmariadbclient18_10.0.5+maria-1~wheezy_amd64.deb) ...
Unpacking replacement libmariadbclient18 ...
dpkg: error processing /var/cache/apt/archives/libmariadbclient18_10.0.5+maria-1~wheezy_amd64.deb (--unpack):
 trying to overwrite '/usr/lib/mysql/plugin/dialog.so', which is also in package mariadb-server-10.0 10.0.4+maria-1~wheezy
Errors were encountered while processing:
 /var/cache/apt/archives/libmariadbclient18_10.0.5+maria-1~wheezy_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

I tried removing the 10.0.4 package version of libmariadbclient18 but I wasn't really successful in doing that.

So my last hope is here, do you have any ideas how exactly I could fix this issue?

Thx very much

share|improve this question

1 Answer 1

up vote 1 down vote accepted

I ran into this problem on two of my VPSes this morning. The only way I "fixed" it was to use dpkg to roll back the 10.0.5 packages with the 10.0.4 packages. Not really a fix, but it was the best I could figure out because the usual apt-get install -f did nothing.

dpkg -i /path/to/old/10.0.4 debs

share|improve this answer
    
awesome worked great, the command I used was dpkg -i /var/cache/apt/archives/mysql-common_10.0.4+maria-1~wheezy_all.deb and everything else worked afterwards again –  peter Nov 8 '13 at 10:50

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.