Home > Backend Development > PHP Tutorial > Linux View the directory where nginx, apache, php, php-fpm, mysql and configuration items are located

Linux View the directory where nginx, apache, php, php-fpm, mysql and configuration items are located

不言
Release: 2023-03-23 18:38:01
Original
2445 people have browsed it

The content of this article is to view the directory where nginx, apache, php, php-fpm, mysql and configuration items are located in linux. Now I share it with you. Friends in need can refer to it

Many times it will Log in to an unfamiliar server;
When the environment needs to be adjusted;
There is really nothing to start with; all the equipment depends on it;
I am blind and looking for configuration items everywhere;
Fortunately, I There is a note for this;

You can summarize it first;
Most of the time, you use which to get the directory first;
and then get the configuration item location;

which  mysql
/usr/bin/mysql
/usr/bin/mysql --help | grep -A1 'Default options'
Copy after login


Bash

Copy

which php
/usr/local/apache2/php/bin/php
php -i | grep "Loaded Configuration File"
Copy after login


Bash

Copy

ps -ef | grep 'http'
/usr/local/apache2/bin/httpd -V | grep 'SERVER_CONFIG_FILE'
Copy after login


##Bash

Copy

The spelling is: /usr/local/apache2/conf/httpd.conf



##

ps -ef | grep 'nginx'
Copy after login


Bash

Copy

If not, execute it according to the nginx location in the picture above

/www/server/nginx/sbin/nginx -t
Copy after login


Bash

Copy

nginx and configuration item directories are all there;

ps -ef | grep 'php-fpm'
Copy after login


Bash

Copy

The configuration file path can be seen at a glance;

The above is the detailed content of Linux View the directory where nginx, apache, php, php-fpm, mysql and configuration items are located. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template