3

I looked around the several answer but none solved my problem. First, I tried sudo apt install mysql-workbench -f.

It shows

The following packages have unmet dependencies:  mysql-workbench :
Depends: libgdal.so.1-1.11.3
                   Depends: libgdal1i (>= 1.8.0) but it is not going to be installed
                   Recommends: mysql-utilities but it is not going to be installed 
E: Unable to correct problems, you have held broken
packages.

If I tried to install libgdal1i, it will show

The following packages have unmet dependencies:  libgdal1i : Depends:
libarmadillo6 but it is not going to be installed
             Depends: libhdf5-10 but it is not going to be installed
             Depends: libnetcdf11 (>= 4.0.1) but it is not going to be installed 
E: Unable to correct problems, you have held broken packages.

There is no end of this story. I tried to install a dep but it always tell me another dep is lack and need to be installed. Besides, I don't know why it says E: Unable to correct problems, you have held broken. I checked in synaptic->custom filters->broken, nothing is there.

Also, I tried sudo aptitude install mysql-workbench -f since other posts said aptitude is better.

The following packages have unmet dependencies:  libgfortran3 :
Depends: gcc-5-base (= 5.3.1-14ubuntu2) but 5.4.0-6ubuntu1~16.04.1 is
installed.  mysql-connector-python : Conflicts: python-mysql.connector
but 2.0.4-1 is to be installed. The following actions will resolve
these dependencies:

      Keep the following packages at their current version: 
1)      libarmadillo6 [Not Installed]   
2)      libarpack2> [Not Installed]   
3)      libgdal1i [Not Installed]
4)      libgfortran3 [Not Installed] 
5)      libhdf5-10 [Not Installed]  
6)      liblapack3 [Not Installed]                        
7)      libnetcdf11 [Not Installed]
8)      mysql-connector-python [Not Installed]
9)      mysql-utilities [Not Installed]
10)     mysql-workbench [Not Installed]                    



Accept this solution? [Y/n/q/?]  No packages will be installed,
upgraded, or removed. 0 packages upgraded, 0 newly installed, 0 to
remove and 0 not to upgrade. Need to get 0 B of archives. After
unpacking 0 B will be used.

I accepted the solution by type enter, as you can see the issue is not solved.

In the last, I tried to download .deb from official site and install. No luck and the similar errors are prompted.

By inputting apt-cache policy mysql-workbench libgdal1i gcc-5-base libhdf5-10, it displays:

mysql-workbench:   
   Installed: (none)
   Candidate: 6.3.6+dfsg-0ubuntu1  Version table:
         6.3.6+dfsg-0ubuntu1 500
            500 http://au.archive.ubuntu.com/ubuntu xenial/universe amd64 Packages 

libgdal1i:   
   Installed: (none)
   Candidate:    1.11.3+dfsg-3build2
   Version table:
         1.11.3+dfsg-3build2 500
            500 http://au.archive.ubuntu.com/ubuntu xenial/universe amd64 Packages 

gcc-5-base:
   Installed: 5.4.0-6ubuntu1~16.04.1
   Candidate: 5.4.0-6ubuntu1~16.04.1
   Version table:
  *** 5.4.0-6ubuntu1~16.04.1 100
            100 /var/lib/dpkg/status
         5.3.1-14ubuntu2 500
            500 http://au.archive.ubuntu.com/ubuntu xenial/main amd64 Packages 

libhdf5-10:
   Installed: (none)
   Candidate:  1.8.16+docs-4ubuntu1
   Version table:
         1.8.16+docs-4ubuntu1 500
            500 http://au.archive.ubuntu.com/ubuntu xenial/universe amd64 Packages

The result of apt-cache policy libgfortran3 libarmadillo6 libnetcdf11 python-mysql.connector is

libgfortran3: Installed: 5.3.1-14ubuntu2 Candidate: 5.3.1-14ubuntu2 Version table: *** 5.3.1-14ubuntu2 500 500 http://au.archive.ubuntu.com/ubuntu xenial/main amd64 Packages 100 /var/lib/dpkg/status libarmadillo6: Installed: 1:6.500.5+dfsg-1 Candidate: 1:6.500.5+dfsg-1 Version table: *** 1:6.500.5+dfsg-1 500 500 http://au.archive.ubuntu.com/ubuntu xenial/universe amd64 Packages 100 /var/lib/dpkg/status libnetcdf11: Installed: 1:4.4.0-2 Candidate: 1:4.4.0-2 Version table: *** 1:4.4.0-2 500 500 http://au.archive.ubuntu.com/ubuntu xenial/universe amd64 Packages 100 /var/lib/dpkg/status python-mysql.connector: Installed: 2.0.4-1 Candidate: 2.0.4-1 Version table: *** 2.0.4-1 500 500 http://au.archive.ubuntu.com/ubuntu xenial/universe amd64 Packages 500 http://au.archive.ubuntu.com/ubuntu xenial/universe i386 Packages 100 /var/lib/dpkg/status

The result of grep -v ^# -r /etc/apt/sources.list etc/apt/sources.list.d/*.list is:

/etc/apt/sources.list: /etc/apt/sources.list:deb http://au.archive.ubuntu.com/ubuntu/ xenial main restricted /etc/apt/sources.list: /etc/apt/sources.list: /etc/apt/sources.list:deb http://au.archive.ubuntu.com/ubuntu/ xenial universe /etc/apt/sources.list: /etc/apt/sources.list:deb http://au.archive.ubuntu.com/ubuntu/ xenial multiverse /etc/apt/sources.list: /etc/apt/sources.list: /etc/apt/sources.list: /etc/apt/sources.list:deb http://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main /etc/apt/sources.list.d/google-chrome.list:deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main /etc/apt/sources.list.d/mysql.list:deb http://repo.mysql.com/apt/ubuntu/ xenial mysql-apt-config /etc/apt/sources.list.d/mysql.list:deb http://repo.mysql.com/apt/ubuntu/ xenial mysql-5.7 /etc/apt/sources.list.d/mysql.list:deb http://repo.mysql.com/apt/ubuntu/ xenial mysql-tools /etc/apt/sources.list.d/mysql.list:deb-src http://repo.mysql.com/apt/ubuntu/ xenial mysql-5.7 /etc/apt/sources.list.d/slack.list:deb https://packagecloud.io/slacktechnologies/slack/debian/ jessie main /etc/apt/sources.list.d/sublime-text.list:deb https://download.sublimetext.com/ apt/stable/

  • On clean xenial it installs normally. Do you have PPA or third-party repositories? Please add to your question the following: output of apt-cache policy mysql-workbench libgdal1i gcc-5-base libhdf5-10. – N0rbert Feb 11 '18 at 16:07
  • @N0rbert, thanks for your response. I've updated the result. – new2cpp Feb 11 '18 at 16:16
  • Please add output of apt-cache policy libgfortran3 libarmadillo6 libnetcdf11 python-mysql.connector and grep -v ^# -r /etc/apt/sources.list /etc/apt/sources.list.d/*.list (to show enabled sources). – N0rbert Feb 12 '18 at 9:40
  • 1
    It seems that you missed xenial-updates and xenial-security sections. I'll update my answer. – N0rbert Feb 13 '18 at 0:17
  • 1
    True. I suspect the problem is caused because I untick all the checkboxes in Updates tab of Software & Updates. However, I reinstall the OS with a clean Ubuntu. Everything works great. I cannot retry the solution. Sorry. – new2cpp Feb 13 '18 at 16:30
3

It seems that you forgot to run sudo apt-get update before installing MySQL Workbench (Australian mirror is synced normally, it has correct version of gcc-5-base in pool).

If it does not help, try to switch to Main server (Software & Updates or software-properties-gtk, Ubuntu Software tab, set Download from to Main server).

For sure add all official repositories with:

sudo add-apt-repository main
sudo add-apt-repository universe
sudo add-apt-repository multiverse

Make sure you have enabled xenial-updates and xenial-security sections:

  1. open software-properties-gtk
  2. go to Updates tab
  3. check first two checkboxes - (xenial-updates) and (xenial-security)
  4. enter password, click Authenticate
  5. click Close, then Reload and wait it to finish.

Then run

sudo apt-get update   
sudo apt-get install -f
sudo apt-get upgrade
sudo apt-get dist-upgrade
sudo apt-get install mysql-workbench
  • I switched to main server as you suggested, and do everything as you said. It still said libgdal.so.1-1.11.3 and libgdal1i (>= 1.8.0) depends are lacking. Exactly as before. Actually, I always do sudo apt-get update first. – new2cpp Feb 11 '18 at 17:01
  • Very strange. Try to install all updates with sudo apt-get dist-upgrade and retry. – N0rbert Feb 11 '18 at 17:03
  • I have tried this before. And no diff. – new2cpp Feb 11 '18 at 21:58
1

Thanks for aptitude. Finally I worked it out after referring to octave installed error - Depends: gcc-5-base (= 5.3.1-14ubuntu2) . aptitude will propose multiple solutions after you continuously input n. Choose the one with the downgrade packages. Everything works as charming.

The following packages have unmet dependencies: libgfortran3 : Depends: gcc-5-base (= 5.3.1-14ubuntu2) but 5.4.0-6ubuntu1~16.04.1 is installed. mysql-connector-python : Conflicts: python-mysql.connector but 2.0.4-1 is to be installed. The following actions will resolve these dependencies:

  Keep the following packages at their current version:

1) libarmadillo6 [Not Installed]
2) libarpack2 [Not Installed]
3) libgdal1i [Not Installed]
4) libgfortran3 [Not Installed]
5) libhdf5-10 [Not Installed]
6) liblapack3 [Not Installed]
7) libnetcdf11 [Not Installed]
8) mysql-connector-python [Not Installed]
9) mysql-utilities [Not Installed]
10) mysql-workbench [Not Installed]

Accept this solution? [Y/n/q/?] n The following actions will resolve these dependencies:

 Keep the following packages at their current version:

1) libarmadillo6 [Not Installed]
2) libarpack2 [Not Installed]
3) libgdal1i [Not Installed]
4) libgfortran3 [Not Installed]
5) libhdf5-10 [Not Installed]
6) liblapack3 [Not Installed]
7) libnetcdf11 [Not Installed]
8) mysql-workbench [Not Installed]
9) python-mysql.connector [Not Installed]

Accept this solution? [Y/n/q/?] n The following actions will resolve these dependencies:

  Remove the following packages:                                           

1) build-essential
2) g++
3) g++-5
4) gcc
5) gcc-5
6) libasan2
7) libatomic1
8) libcilkrts5
9) libgcc-5-dev
10) libitm1
11) liblsan0
12) libmpx0
13) libstdc++-5-dev
14) libtsan0
15) libubsan0

  Install the following packages:                                          

16) mysql-utilities [1.6.1-2 (xenial)]
17) tcc [0.9.27~git20151227.933c223-1 (xenial)]

  Keep the following packages at their current version:                    

18) mysql-connector-python [Not Installed]

  Downgrade the following packages:                                        

19) cpp-5 [5.4.0-6ubuntu1~16.04.1 (now) -> 5.3.1-14ubuntu2 (xenial)]
20) gcc-5-base [5.4.0-6ubuntu1~16.04.1 (now) -> 5.3.1-14ubuntu2 (xenial)]
21) libcc1-0 [5.4.0-6ubuntu1~16.04.1 (now) -> 5.3.1-14ubuntu2 (xenial)]
22) libgomp1 [5.4.0-6ubuntu1~16.04.1 (now) -> 5.3.1-14ubuntu2 (xenial)]
23) libquadmath0 [5.4.0-6ubuntu1~16.04.1 (now) -> 5.3.1-14ubuntu2 (xenial)] 24) libstdc++6 [5.4.0-6ubuntu1~16.04.1 (now) -> 5.3.1-14ubuntu2 (xenial)]

  Leave the following dependencies unresolved:                             

25) dpkg-dev recommends build-essential

Accept this solution? [Y/n/q/?] The following packages will be DOWNGRADED: cpp-5 gcc-5-base libcc1-0 libgomp1 libquadmath0 libstdc++6

0

on Ubuntu 19

1)I had to preceding it on Ubuntu 19 also install manually a library libzip https://ubuntu.pkgs.org/18.10/ubuntu-universe-amd64/libzip4_1.1.2-1.1_amd64.deb.html

2) then manually selecting on download page deb package for mysql workbench https://dev.mysql.com/downloads/workbench/

then install deb packages via standard apt installer in Downloads dir

sudo apt install ./libzip4_1.1.2-1.1_amd64.deb

and downloaded workbench deb package

sudo apt install ./mysql-workbench-community_8.0.16-1ubuntu18.04_amd64.deb

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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