我正在爲我的項目使用laravel 5,一切工作正常,但最近我遇到了這個我已經理解的問題。無法在Linux上啓動laravel開發服務器
[email protected] ~/sonel_ims_project/ims_eneo $ php artisan serve
Laravel development server started on http://localhost:8000/
[Fri Nov 13 12:00:56 2015] Failed to listen on localhost:8000 (reason: Address already in use)
我已經試過[email protected] ~ $ sudo netstat -plnt
並獲得
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 192.168.122.1:53 0.0.0.0:* LISTEN 1840/dnsmasq
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 1985/cupsd
tcp 0 0 127.0.0.1:8888 0.0.0.0:* LISTEN 7563/php-5.6.3
tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 1656/master
tcp 0 0 0.0.0.0:443 0.0.0.0:* LISTEN 6966/httpd
tcp 0 0 0.0.0.0:445 0.0.0.0:* LISTEN 740/smbd
tcp 0 0 127.0.0.1:6942 0.0.0.0:* LISTEN 7442/java
tcp 0 0 127.0.0.1:8000 0.0.0.0:* LISTEN 6931/php-5.6.3
tcp 0 0 0.0.0.0:6667 0.0.0.0:* LISTEN 1539/ircd
tcp 0 0 0.0.0.0:139 0.0.0.0:* LISTEN 740/smbd
tcp 0 0 127.0.0.1:63342 0.0.0.0:* LISTEN 7442/java
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 6966/httpd
tcp6 0 0 :::21 :::* LISTEN 7337/proftpd: (acce
tcp6 0 0 ::1:631 :::* LISTEN 1985/cupsd
tcp6 0 0 :::3128 :::* LISTEN 1416/squid3
tcp6 0 0 :::25 :::* LISTEN 1656/master
tcp6 0 0 :::445 :::* LISTEN 740/smbd
tcp6 0 0 :::3306 :::* LISTEN 7343/mysqld
tcp6 0 0 :::139 :::* LISTEN 740/smbd
然後我改變端口,像這樣php artisan serve --port="8888"
但經過一段時間得到類似的錯誤象下面這樣:
Laravel development server started on http://localhost:8888/
[Fri Nov 13 12:01:02 2015] Failed to listen on localhost:8888 (reason: Address already in use)
第一次發生,它是使用8000端口的java,所以我殺死了這個進程並啓動了服務器並且工作。在停止並重新啓動後,我得到相同的錯誤。可能是什麼問題(正如我所說的,現在除了現在一切正常,我還沒有做過任何重大更新)?