Connecting to 192.168.2.201:4011...
Connection established.
To escape to local shell, press 'Ctrl+Alt+]'.
Last login: Thu Jun 18 11:18:07 2015 from dongchao-pc
[root@2637780b539e ~]# nginx
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
nginx: [emerg] still could not bind()
[root@2637780b539e ~]# whereis nginx
nginx: /usr/sbin/nginx /etc/nginx /usr/local/nginx /usr/share/nginx
[root@2637780b539e ~]# wget localhost
--2015-06-18 14:12:03-- http://localhost/
Resolving localhost (localhost)... ::1, 127.0.0.1
Connecting to localhost (localhost)|::1|:80... failed: Connection refused.
Connecting to localhost (localhost)|127.0.0.1|:80... connected.
HTTP request sent, awaiting response... 500 Internal Server Error
2015-06-18 14:12:03 ERROR 500: Internal Server Error.
[root@2637780b539e ~]# ls
init.sh test.php wushuu_basis.sql wushuu_safecity.sql
[root@2637780b539e ~]# ss -nat
State Recv-Q Send-Q Local Address:Port Peer Address:Port
LISTEN 0 128 *:22 *:*
LISTEN 0 50 *:3306 *:*
LISTEN 0 128 *:80 *:*
ESTAB 0 0 172.17.0.42:22 192.168.2.145:61752
TIME-WAIT 0 0 127.0.0.1:57270 127.0.0.1:80
TIME-WAIT 0 0 172.17.0.42:80 192.168.2.145:60482
ESTAB 0 0 172.17.0.42:22 192.168.2.145:60455
ESTAB 0 0 172.17.0.42:22 192.168.2.145:64578
LISTEN 0 128 :::22 :::*
[root@2637780b539e ~]# wget localhost
--2015-06-18 14:12:17-- http://localhost/
Resolving localhost (localhost)... ::1, 127.0.0.1
Connecting to localhost (localhost)|::1|:80... failed: Connection refused.
Connecting to localhost (localhost)|127.0.0.1|:80... connected.
HTTP request sent, awaiting response... 500 Internal Server Error
2015-06-18 14:12:17 ERROR 500: Internal Server Error.
[root@2637780b539e ~]# ls
init.sh test.php wushuu_basis.sql wushuu_safecity.sql
[root@2637780b539e ~]# ps -ef
UID PID PPID C STIME TTY TIME CMD
root 1 0 0 Jun10 ? 00:23:34 /usr/bin/python /usr/bin/supervisord
root 16 1 0 Jun10 ? 00:00:00 /usr/sbin/sshd -D
root 17 1 0 Jun10 ? 00:00:25 php-fpm: master process (/etc/php-fpm.conf)
apache 77 17 0 Jun10 ? 00:00:00 php-fpm: pool www
apache 78 17 0 Jun10 ? 00:00:00 php-fpm: pool www
apache 79 17 0 Jun10 ? 00:00:00 php-fpm: pool www
apache 81 17 0 Jun10 ? 00:00:00 php-fpm: pool www
apache 82 17 0 Jun10 ? 00:00:00 php-fpm: pool www
mysql 170 1 0 Jun10 ? 00:08:02 /usr/libexec/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib64/mysql/plugin --user=mysql --log-error
root 15975 1 0 Jun16 ? 00:00:00 nginx: master process nginx
root 24623 16 0 09:39 ? 00:00:01 sshd: root@pts/0
root 24630 24623 0 09:40 pts/0 00:00:00 -bash
root 25555 24630 0 10:25 pts/0 00:00:00 vi nginx.conf
root 26441 16 0 11:17 ? 00:00:00 sshd: root@pts/1
root 26445 26441 0 11:18 pts/1 00:00:00 -bash
www 27066 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27067 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27068 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27069 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27070 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27071 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27072 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27073 15975 0 11:51 ? 00:00:00 nginx: worker process
root 27185 26445 0 11:57 pts/1 00:00:00 vi nginx.conf
root 29416 16 0 14:09 ? 00:00:00 sshd: root@pts/2
root 29421 29416 0 14:09 pts/2 00:00:00 -bash
root 29490 1 2 14:12 ? 00:00:00 /usr/sbin/nginx
root 29491 29421 0 14:12 pts/2 00:00:00 ps -ef
[root@2637780b539e ~]# ps -ef | grep nginx
root 15975 1 0 Jun16 ? 00:00:00 nginx: master process nginx
root 25555 24630 0 10:25 pts/0 00:00:00 vi nginx.conf
www 27066 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27067 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27068 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27069 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27070 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27071 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27072 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27073 15975 0 11:51 ? 00:00:00 nginx: worker process
root 27185 26445 0 11:57 pts/1 00:00:00 vi nginx.conf
root 29494 1 1 14:12 ? 00:00:00 /usr/sbin/nginx
root 29496 29421 0 14:12 pts/2 00:00:00 grep --color=auto nginx
[root@2637780b539e ~]# ps -ef | grep ^www
www 27066 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27067 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27068 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27069 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27070 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27071 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27072 15975 0 11:51 ? 00:00:00 nginx: worker process
www 27073 15975 0 11:51 ? 00:00:00 nginx: worker process
[root@2637780b539e ~]# ps -ef | grep ^www | wc -n
wc: invalid option -- 'n'
Try 'wc --help' for more information.
[root@2637780b539e ~]# ps -ef | grep ^www | wc -l
8
[root@2637780b539e ~]# wget localhost
--2015-06-18 14:13:14-- http://localhost/
Resolving localhost (localhost)... ::1, 127.0.0.1
Connecting to localhost (localhost)|::1|:80... failed: Connection refused.
Connecting to localhost (localhost)|127.0.0.1|:80... connected.
HTTP request sent, awaiting response... 500 Internal Server Error
2015-06-18 14:13:14 ERROR 500: Internal Server Error.
[root@2637780b539e ~]# ps -ef | grep ^www | wc -l
8
[root@2637780b539e ~]# cd /var/www/
[root@2637780b539e www]# ls
cgi-bin html wushuu_jiaotong
[root@2637780b539e www]# cd wushuu_jiaotong/
[root@2637780b539e wushuu_jiaotong]# ls
admin.wushuu.com batch include jiaotong.wushuu.com script
[root@2637780b539e wushuu_jiaotong]# cd jiaotong.wushuu.com/
[root@2637780b539e jiaotong.wushuu.com]# ls
public
[root@2637780b539e jiaotong.wushuu.com]# cd public/
[root@2637780b539e public]# ls
camera.php classes.cfg.php demo.php image-dst index.php kaoqingRequery.php monitor_iframe.php public test.php timeSet.php
cameraImg css entry.php images js login.php mp3 rooms test.php.bak upimg
cameraSearch.php dayDetail.php faceSearch.php img kaoQing.php monitor.php overloop.php systemState.php testone.php vlc.exe
[root@2637780b539e public]# cd ..
[root@2637780b539e jiaotong.wushuu.com]# ls
public
[root@2637780b539e jiaotong.wushuu.com]# ls
public
[root@2637780b539e jiaotong.wushuu.com]# cd ..
[root@2637780b539e wushuu_jiaotong]# ls
admin.wushuu.com batch include jiaotong.wushuu.com script
[root@2637780b539e wushuu_jiaotong]# cd jiaotong.wushuu.com/
[root@2637780b539e jiaotong.wushuu.com]# ls
public
[root@2637780b539e jiaotong.wushuu.com]# cd public/
[root@2637780b539e public]# ls
camera.php classes.cfg.php demo.php image-dst index.php kaoqingRequery.php monitor_iframe.php public test.php timeSet.php
cameraImg css entry.php images js login.php mp3 rooms test.php.bak upimg
cameraSearch.php dayDetail.php faceSearch.php img kaoQing.php monitor.php overloop.php systemState.php testone.php vlc.exe
[root@2637780b539e public]# cd public/
[root@2637780b539e public]# ls
1210.asf-1700-Traffic.jpg dayDetail.php images index.php monitor.php systemState.php test.php.bak timeSet.php
css faceSearch.php img kaoqingRequery.php mp3 test.php testone.php upimg
[root@2637780b539e public]# cd ..
[root@2637780b539e public]# ls
camera.php classes.cfg.php demo.php image-dst index.php kaoqingRequery.php monitor_iframe.php public test.php timeSet.php
cameraImg css entry.php images js login.php mp3 rooms test.php.bak upimg
cameraSearch.php dayDetail.php faceSearch.php img kaoQing.php monitor.php overloop.php systemState.php testone.php vlc.exe
[root@2637780b539e public]# cd ..
[root@2637780b539e jiaotong.wushuu.com]# mkdir template
[root@2637780b539e jiaotong.wushuu.com]# ls
public template
[root@2637780b539e jiaotong.wushuu.com]# cd public/
[root@2637780b539e public]# ls
camera.php classes.cfg.php demo.php image-dst index.php kaoqingRequery.php monitor_iframe.php public test.php timeSet.php
cameraImg css entry.php images js login.php mp3 rooms test.php.bak upimg
cameraSearch.php dayDetail.php faceSearch.php img kaoQing.php monitor.php overloop.php systemState.php testone.php vlc.exe
[root@2637780b539e public]# vi login.php
[root@2637780b539e public]# grep tpl *
camera.php:$this->display ('camera/terminal_index.tpl' );
camera.php:$this->display ('camera/terminal_index.tpl' );
camera.php:$this->display ('camera/terminal_index.tpl' );
grep: cameraImg: Is a directory
cameraSearch.php:$this->display('cameraSearch.tpl');
cameraSearch.php:$this->display('index.tpl' );
grep: css: Is a directory
dayDetail.php:$this->display('dayDetail.tpl');
dayDetail.php:$this->display('dayDetail.tpl' );
dayDetail.php:$this->display('faceSearch_collect.tpl');
dayDetail.php:$this->display('index.tpl' );
demo.php:$this->display ( 'demo2.tpl' );
demo.php:$this->display ( 'demo3.tpl' );
demo.php:$this->display ( 'demo4.tpl' );
demo.php:$this->display ( 'demo2.tpl' );
faceSearch.php:$this->display('faceSearch.tpl');
faceSearch.php:$this->display('index.tpl' );
faceSearch.php:$this->display('faceSearch_collect.tpl');
faceSearch.php:$this->display('index.tpl' );
grep: image-dst: Is a directory
grep: images: Is a directory
grep: img: Is a directory
index.php:$this->display ( 'index.tpl' );
index.php:$this->display ( 'index.tpl' );
grep: js: Is a directory
kaoQing.php:$this->display('kaoQing.tpl');
kaoQing.php:$this->display('index.tpl' );
kaoqingRequery.php:$this->display('kaoqingRequery.tpl');
kaoqingRequery.php:$this->display('index.tpl' );
kaoqingRequery.php:$this->display ('timeSet.tpl' );
monitor.php:$this->display ( 'monitor.tpl' );
monitor.php:$this->display ( 'monitor.tpl' );
monitor.php: $this->display ( 'alermList.tpl' );
monitor.php:$this->display ( 'alermList.tpl' );
monitor_iframe.php:$this->display ( 'monitor_iframe.tpl' );
monitor_iframe.php:$this->display ( 'monitor_iframe.tpl' );
grep: mp3: Is a directory
overloop.php:$this->display('overloop.tpl');
overloop.php:$this->display('index.tpl' );
grep: public: Is a directory
grep: rooms: Is a directory
systemState.php:$this->display ( 'systemState.tpl' );
systemState.php:$this->display ( 'index.tpl' );
systemState.php:$this->display ( 'systemState.tpl' );
systemState.php:$this->display ( 'index.tpl' );
test.php:$this->display ( 'test.tpl' );
test.php:$this->display ( 'test.tpl' );
test.php.bak:$this->display ( 'test.tpl' );
test.php.bak:$this->display ( 'test.tpl' );
timeSet.php:$this->display('timeSet.tpl');
timeSet.php:$this->display('index.tpl' );
timeSet.php:$this->display('timeList.tpl');
timeSet.php://$this->display ('timeSet.tpl' );
grep: upimg: Is a directory
Binary file vlc.exe matches
[root@2637780b539e public]# cd ..
[root@2637780b539e jiaotong.wushuu.com]# ls
public template
[root@2637780b539e jiaotong.wushuu.com]# rm template/
rm: cannot remove 'template/': Is a directory
[root@2637780b539e jiaotong.wushuu.com]# rm template/ -rf
[root@2637780b539e jiaotong.wushuu.com]# ls
主要得出结论是:由于没有从远程服务器将templates下载到本地。nginx起不起来。