我試圖讓我的網站設置,每當我試圖用我的域名連接我得到「404未找到」404與Apache服務器未找到
當我試圖達成我的IP站點它工作正常。
我在Debian x64上。
有人可以幫助我解決這個問題。
如果您需要更多信息,請查詢。
我試圖讓我的網站設置,每當我試圖用我的域名連接我得到「404未找到」404與Apache服務器未找到
當我試圖達成我的IP站點它工作正常。
我在Debian x64上。
有人可以幫助我解決這個問題。
如果您需要更多信息,請查詢。
虛擬主機應該是這樣的:
<VirtualHost *:80>
ServerAdmin [email protected]
DocumentRoot /home/web/websites/special-faces.net
ServerName special-faces.net
ServerAlias www.special-faces.net
ErrorLog /home/web/website_logs/errorlog.txt
CustomLog /home/web/website_logs/accesslog.txt common
<Directory "/home/web/websites/special-faces.net">
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
如果你想使用.htaccess文件,該行 「從所有允許」 後補充一點:
Allowoverride all
現在就開始工作吧。 –
@Nicholas Brown你看過DNS設置嗎? – Kenzo
對於服務器版本:阿帕奇/ 2.4.16及更高版本,
<VirtualHost localhost.com:80>
ServerName localhost.com
ServerAlias localhost.com
ServerAdmin [email protected]
RewriteEngine On
DocumentRoot /var/www/html
DocumentRoot /home/<user name where code will be placed>/public_html/html
<Directory /var/www/html>
AllowOverride All
Order allow,deny
allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combinedtimezone
</VirtualHost>
@Arnestig:你不知道的問題實際上是Debian的特定與否。 –
@StefanSteinegger:我們不知道這個問題是由硬件問題,軟件問題還是其他問題引起的。 Nicholas Brown告訴我們他正在使用Debian x64,這很好,但問題本身與Debian無關。他並沒有問一個關於Debian如何工作/行爲的問題。這個問題完全是爲了讓Apache運行起來。因此標籤「apache」。 – Arnestig
@Arnestig:好點。 –