In Ubuntu 16.04
You aren't using an appropriate method to check if a package is installed.
In your case one of the easy ways would be apt -qq list php-mysql
which if installed will output
php-mysql/xenial-updates,xenial-updates,now 1:7.0+35ubuntu6.1 all [installed]
and if not you'll get the same output without the [installed]
php-mysql isn't much of a package as it contains only:
/usr/share/doc/php-mysql/changelog.gz
/usr/share/doc/php-mysql/copyright
It however depends on php-common which contains:
/etc/cron.d/php
/usr/lib/php/php-helper
/usr/lib/php/php-maintscript-helper
/usr/lib/php/sessionclean
/usr/sbin/phpdismod
/usr/sbin/phpenmod
/usr/sbin/phpquery
/usr/share/doc/php-common/changelog.gz
/usr/share/doc/php-common/copyright
and php7.0-mysql which contains
/usr/lib/php/20151012/mysqli.so
/usr/lib/php/20151012/mysqlnd.so
/usr/lib/php/20151012/pdo_mysql.so
/usr/share/bug/php7.0-mysql/control
/usr/share/bug/php7.0-mysql/script
/usr/share/doc/php7.0-mysql
/usr/share/lintian/overrides/php7.0-mysql
/usr/share/php7.0-mysql/mysql/mysqli.ini
/usr/share/php7.0-mysql/mysql/mysqlnd.ini
/usr/share/php7.0-mysql/mysql/pdo_mysql.ini
Since:
whereis locates the binary, source and manual files for the specified command names. The supplied names are first
stripped of leading pathname components and any (single) trailing extension of the form .ext (for example: .c) Prefixes
of s. resulting from use of source code control are also dealt with. whereis then attempts to locate the desired pro‐
gram in the standard Linux places, and in the places specified by $PATH and $MANPATH.
and php-mysql
is not a command your output is as expected. If you were to try an actual command such as phpquery
that is installed when you install php-mysql
You would get:
$ whereis phpquery
phpquery: /usr/sbin/phpquery
TL;DR
What should have happened when you installed php-mysql is
all of these packages should have been installed.
If as you say it's not installed you can
sudo apt-get install php-common php7.0-common php7.0-mysql
to install all the packages that the php-mysql meta package installs.
Sources:
https://packages.ubuntu.com
man whereis