樹莓派開發日記,2015,5,18,問題記錄

Apache2 Problems

1.Bad User Name

when you keydown #apache2 in the shell.Tips will be like this
apache2:bad user name ${APACHE_RUN_USER}
well,I believe this is because /etc/init.d is not in your command path.
Unlike windows,Linux does not look in the current directory for commands.So,if you are in the /etc/init.d ,you can type

sudo ./apache2 start

which will tell it to look in the current directionary with the’./’
The script in /etc/init.d/apache2 explicitly reads in the environment variables before calling /usr/sbin/apache2.
or you can just type in the whole path

sudo /etc/init.d/apache2 start

2.Could Not Reliably Determin

Sometimes we will greet with an error that:

*Restarting web server apache2
apache2 : Could not reliably determin the server’s fully qualified domain name,using 127.0.1.1 for ServerName.

well,I think the apache2 does not know who it is in the LAN.

solution to solve it:

sudo vi /etc/apache2/apache2.conf

add these lines after the apache2.conf

#Server Name
ServerName 127.0.0.1(or the host’s static address in LAN,something like 192.168.*)

VNC Server Problem

when you start a firewall like ufw.
em….even if you add the VNC rules,the ‘tightvncserver/Xvnc’
cannot work any more.
The only way I can find is disabling the fire wall.
Maybe there is another way to find.
(something wrong with the markdown,I cannot using Chinese,Opps……

發佈了40 篇原創文章 · 獲贊 6 · 訪問量 7萬+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章