以postgresql为例,我已经安装了9.6版本。如果想知道软件被安装在哪个目录,先查出其对应的rpm包名。 ``` rpm -qa|grep postgresql ``` 得到如下结果: ``` [root@cdh01 hive]# rpm -qa |grep postgresql postgresql96-9.6.20-1PGDG.rhel7.x86_64 postgresql96-libs-9.6.20-1PGDG.rhel7.x86_64 postgresql96-server-9.6.20-1PGDG.rhel7.x86_64 ``` 然后执行: ``` rpm -ql php71-php-fpm-7.1.2-1.el6.remi.x86_64 ``` 得到: ``` [root@cdh01 hive]# rpm -ql postgresql96-9.6.20-1PGDG.rhel7.x86_64 /usr/pgsql-9.6/bin/clusterdb /usr/pgsql-9.6/bin/createdb /usr/pgsql-9.6/bin/createlang /usr/pgsql-9.6/bin/createuser /usr/pgsql-9.6/bin/dropdb /usr/pgsql-9.6/bin/droplang /usr/pgsql-9.6/bin/dropuser /usr/pgsql-9.6/bin/pg_archivecleanup /usr/pgsql-9.6/bin/pg_basebackup /usr/pgsql-9.6/bin/pg_config /usr/pgsql-9.6/bin/pg_dump /usr/pgsql-9.6/bin/pg_dumpall /usr/pgsql-9.6/bin/pg_isready /usr/pgsql-9.6/bin/pg_receivexlog /usr/pgsql-9.6/bin/pg_restore /usr/pgsql-9.6/bin/pg_rewind ``` 当然我只截取了部分结果,明白了吗? Loading... 以postgresql为例,我已经安装了9.6版本。如果想知道软件被安装在哪个目录,先查出其对应的rpm包名。 ``` rpm -qa|grep postgresql ``` 得到如下结果: ``` [root@cdh01 hive]# rpm -qa |grep postgresql postgresql96-9.6.20-1PGDG.rhel7.x86_64 postgresql96-libs-9.6.20-1PGDG.rhel7.x86_64 postgresql96-server-9.6.20-1PGDG.rhel7.x86_64 ``` 然后执行: ``` rpm -ql php71-php-fpm-7.1.2-1.el6.remi.x86_64 ``` 得到: ``` [root@cdh01 hive]# rpm -ql postgresql96-9.6.20-1PGDG.rhel7.x86_64 /usr/pgsql-9.6/bin/clusterdb /usr/pgsql-9.6/bin/createdb /usr/pgsql-9.6/bin/createlang /usr/pgsql-9.6/bin/createuser /usr/pgsql-9.6/bin/dropdb /usr/pgsql-9.6/bin/droplang /usr/pgsql-9.6/bin/dropuser /usr/pgsql-9.6/bin/pg_archivecleanup /usr/pgsql-9.6/bin/pg_basebackup /usr/pgsql-9.6/bin/pg_config /usr/pgsql-9.6/bin/pg_dump /usr/pgsql-9.6/bin/pg_dumpall /usr/pgsql-9.6/bin/pg_isready /usr/pgsql-9.6/bin/pg_receivexlog /usr/pgsql-9.6/bin/pg_restore /usr/pgsql-9.6/bin/pg_rewind ``` 当然我只截取了部分结果,明白了吗? 最后修改:2021 年 01 月 19 日 © 允许规范转载 打赏 赞赏作者 支付宝微信 赞 如果觉得我的文章对你有用,请随意赞赏