If you have ever found yourself wondering what PHP packages are installed on a Debian or Ubuntu server you can run the following from the command line.
dave@darkmetal:~$ dpkg –get-selections | grep php
In my example I am piping the output through grep to only show packages with PHP in their names.
If PEAR is installed you can get a list of packages installed with the following command:
dave@darkmetal:~$ pear list
Installed packages, channel pear.php.net:
Package Version State
Archive_Tar 1.3.7 stable
Console_Getopt 1.3.0 stable
PEAR 1.9.4 stable
Structures_Graph 1.0.4 stable
XML_Util 1.2.1 stable