1、查看pid
ps -C nginx -o pid
2、查找指定pid正在运行服务的启动路径
[root@wskh xpe]# ll /proc/2320/exe
lrwxrwxrwx 1 root root 0 11月 16 11:29 /proc/2320/exe -> /usr/local/nginx/sbin/nginx
3.查找nginx启动使用的配置文件
[root@wskh xpe]# /usr/local/nginx/sbin/nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful