es gibt im Forum zwar einige Einträge dazu, keiner hat aber weitergeholfen, daher schildere ich hier mal mein Problem und hoffe, dass ein Experte den vermutlich kleinen Denkfehler erkennt und mir weiterhelfen kann
Ich habe in der Windows-Host-Datei folgende EInträge:
- Code: Select all
127.0.0.1 rentaflat
127.0.0.1 localhost
Mit ping rentaflat bekomme ich eine gültige Antwort.
in httpd.conf habe ich die Listen-Zeile geändert, alles andere ist wie in der Neu-Installation:
- Code: Select all
#Listen 12.34.56.78:80
Listen 8080
In extra\httpd-vhost.conf steht:
- Code: Select all
# konfiguration für netbeans / rentaflat
# Be sure to only have this line once in your configuration
NameVirtualHost 127.0.0.1:8080
<VirtualHost *:8080>
DocumentRoot "C:\xampp\htdocs"
ServerName localhost
<directory "C:\xampp\htdocs">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Require all granted
</directory>
</VirtualHost>
<VirtualHost *:8080>
DocumentRoot "C:\Users\sgl\Documents\NetBeansProjects\RentAFlat-Zend\public"
ServerName rentaflat
## ErrorLog "C:\Zend\ZendServer\logs\RentAFlat.local.log"
<directory "C:\Users\sgl\Documents\NetBeansProjects\RentAFlat-Zend">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Require all granted
</directory>
</VirtualHost>
# ende konfiguration für netbeans / rentaflat
Rufe ich im Browser http://localhost:8080 auf, kommt die XAMPP-Dashboard-Seite.
Rufe ich http://rentaflat:8080 auf, kommt "kein Zugriff auf die Seite". Im DocumentRoot-Ordner des VHOST liegt eine simple Hello-World-Seite als index.html.
Ausgabe von httpd -S:
- Code: Select all
AH00548: NameVirtualHost has no effect and will be removed in the next release C:/xampp/apache/conf/extra/httpd-vhosts.conf:46
VirtualHost configuration:
*:8080 is a NameVirtualHost
default server localhost (C:/xampp/apache/conf/extra/httpd-vhosts.conf:48)
port 8080 namevhost localhost (C:/xampp/apache/conf/extra/httpd-vhosts.conf:48)
port 8080 namevhost rentaflat (C:/xampp/apache/conf/extra/httpd-vhosts.conf:59)
*:443 www.example.com (C:/xampp/apache/conf/extra/httpd-ssl.conf:121)
ServerRoot: "C:/xampp/apache"
Main DocumentRoot: "C:/xampp/htdocs"
Main ErrorLog: "C:/xampp/apache/logs/error.log"
Mutex ssl-cache: using_defaults
Mutex default: dir="C:/xampp/apache/logs/" mechanism=default
Mutex ssl-stapling-refresh: using_defaults
Mutex rewrite-map: using_defaults
Mutex ssl-stapling: using_defaults
Mutex proxy: using_defaults
PidFile: "C:/xampp/apache/logs/httpd.pid"
Define: DUMP_VHOSTS
Define: DUMP_RUN_CFG
Im Errorlog steht nichts, was meiner Ansicht nach Bezug zu diesem Fehler hat, trotzdem hier mal wiedergegeben:
- Code: Select all
[Wed Sep 07 09:44:02.194608 2016] [ssl:warn] [pid 9504:tid 532] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Wed Sep 07 09:44:02.234479 2016] [core:warn] [pid 9504:tid 532] AH00098: pid file C:/xampp/apache/logs/httpd.pid overwritten -- Unclean shutdown of previous Apache run?
[Wed Sep 07 09:44:02.299054 2016] [ssl:warn] [pid 9504:tid 532] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Wed Sep 07 09:44:02.326376 2016] [mpm_winnt:notice] [pid 9504:tid 532] AH00455: Apache/2.4.23 (Win32) OpenSSL/1.0.2h PHP/5.6.24 configured -- resuming normal operations
[Wed Sep 07 09:44:02.326376 2016] [mpm_winnt:notice] [pid 9504:tid 532] AH00456: Apache Lounge VC11 Server built: Jul 7 2016 11:13:22
[Wed Sep 07 09:44:02.326376 2016] [core:notice] [pid 9504:tid 532] AH00094: Command line: 'c:\\xampp\\apache\\bin\\httpd.exe -d C:/xampp/apache'
[Wed Sep 07 09:44:02.330282 2016] [mpm_winnt:notice] [pid 9504:tid 532] AH00418: Parent: Created child process 4584
AH00548: NameVirtualHost has no effect and will be removed in the next release C:/xampp/apache/conf/extra/httpd-vhosts.conf:46
[Wed Sep 07 09:44:02.701953 2016] [ssl:warn] [pid 4584:tid 532] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Wed Sep 07 09:44:02.800720 2016] [ssl:warn] [pid 4584:tid 532] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Wed Sep 07 09:44:02.830171 2016] [mpm_winnt:notice] [pid 4584:tid 532] AH00354: Child: Starting 150 worker threads.
Trage ich bei localhost als DocumentRoot den Ordner ein, der im V-Host "rentaflat" verwendet wird, wird die index.html angezeigt.
Ich bin leider völlig verwirrt, weil aus meiner Sicht (fast) alles funktioniert:
- localhost:8080 kann aufgerufen werden
- mit dem DocumentRoot des gewünschten V-Host in localhost wird die Testseite angezeigt
- ping auf den gewünschten V-Host rentaflat funktioniert
- im Errrrlog steht nichts auffälliges
- httpd -S zeigt, dass eigentlich alles richtig funktionieren sollte
Wer findet den Fehler???
Vielen Dank schon mal im Voraus...