Google Certified Professional Data Engineer

Sign Up Free or Log In to participate!

I am not able to install mysql-client from VM Instance

I am not able to install mysql-client from VM Instance, getting below error.

cloud[email protected]:~$ sudo apt-get install mysql-client

Reading package lists… Done

Building dependency tree

Reading state information… Done

Package mysql-client is not available, but is referred to by another package.

This may mean that the package is missing, has been obsoleted, or

is only available from another source

E: Package ‘mysql-client’ has no installation candidate

[email protected]:~$

3 Answers

Looks like mysql-client is not the name of the package on your distribution.  I’d try apt search mysql to find the client’s name.  A possible name might be default-mysql-client

Solution : change mysql-client by default-mysql-client

Additional steps in Feb/2021:

• Install wget and unzip using apt-get install

• The installation of mysql-clinet is now called default-mysql-client

• Enable the API in the Cloud SQL Admin API otherwise, it will not connect.

• The SQL database forumdb.sql that comes from the LAB is zipped -> use:  unzip  

• When in doubt, always use the "file" command in linux to see if the file is really zipped

Ramzi Al-Aruri

Thanks Everton! these all helped

Sign In
Welcome Back!

Psst…this one if you’ve been moved to ACG!

Get Started
Who’s going to be learning?