Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #11  
Old 5th February 2007, 13:42
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,747 Times in 2,578 Posts
Default

Quote:
Originally Posted by gabrix
And i keep on getting this error:

root@www:~# apache2ctl restart
[Sun Feb 04 15:02:00 2007] [warn] NameVirtualHost 192.168.1.4:0 has no VirtualHosts
That warning is ok, it just means that there is no virtual host on the IP address 192.168.1.4.
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
Sponsored Links
  #12  
Old 5th February 2007, 21:16
gabrix gabrix is offline
Senior Member
 
Join Date: Sep 2006
Location: Napoli
Posts: 186
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via MSN to gabrix Send a message via Yahoo to gabrix Send a message via Skype™ to gabrix
Default

My virtual hosts are configured just like as you see in my first post and instead of fqdn there are ips as you sayd so it's not ok !!!
Quote:
root@www:~# httpd -V
bash: httpd: command not found
__________________
http://www.gabrix.ath.cx

Last edited by gabrix; 5th February 2007 at 21:19.
Reply With Quote
  #13  
Old 5th February 2007, 22:35
martinfst martinfst is offline
Senior Member
 
Join Date: Dec 2006
Location: Hilversum, The Netherlands
Posts: 880
Thanks: 1
Thanked 18 Times in 17 Posts
Send a message via MSN to martinfst Send a message via Skype™ to martinfst
Default

So what's the output of
Code:
apache2ctl -V
then?
Reply With Quote
  #14  
Old 6th February 2007, 11:29
gabrix gabrix is offline
Senior Member
 
Join Date: Sep 2006
Location: Napoli
Posts: 186
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via MSN to gabrix Send a message via Yahoo to gabrix Send a message via Skype™ to gabrix
Default

This has worked :
Quote:
root@www:~# apache2ctl -V
Server version: Apache/2.0.54
Server built: Jul 28 2006 09:04:55
Server's Module Magic Number: 20020903:9
Architecture: 32-bit
Server compiled with....
-D APACHE_MPM_DIR="server/mpm/prefork"
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
-D APR_USE_SYSVSEM_SERIALIZE
-D APR_USE_PTHREAD_SERIALIZE
-D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D HTTPD_ROOT=""
-D SUEXEC_BIN="/usr/lib/apache2/suexec2"
-D DEFAULT_PIDLOG="/var/run/httpd.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_LOCKFILE="/var/run/accept.lock"
-D DEFAULT_ERRORLOG="logs/error_log"
-D AP_TYPES_CONFIG_FILE="/etc/apache2/mime.types"
-D SERVER_CONFIG_FILE="/etc/apache2/apache2.conf"
__________________
http://www.gabrix.ath.cx
Reply With Quote
  #15  
Old 6th February 2007, 12:12
martinfst martinfst is offline
Senior Member
 
Join Date: Dec 2006
Location: Hilversum, The Netherlands
Posts: 880
Thanks: 1
Thanked 18 Times in 17 Posts
Send a message via MSN to martinfst Send a message via Skype™ to martinfst
Default

So you use
Quote:
-D SERVER_CONFIG_FILE="/etc/apache2/apache2.conf"
for you config file. Good. In your 1st post you showed us (part of?) this file. Can you check if you have a line reading
Code:
Include /etc/apache2/sites-enabled/[^.#]*
in this apache2.conf file?
Reply With Quote
  #16  
Old 6th February 2007, 15:32
gabrix gabrix is offline
Senior Member
 
Join Date: Sep 2006
Location: Napoli
Posts: 186
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via MSN to gabrix Send a message via Yahoo to gabrix Send a message via Skype™ to gabrix
Default

Here it is:
Quote:
Include /etc/apache2/sites-enabled/[^.#]*
And this is the virtualhost file:
Quote:
NameVirtualHost 192.168.1.4
<VirtualHost 192.168.1.4>
ServerAdmin webmaster@gabrix.ath.cx

DocumentRoot /var/www/ics
<Directory />
Options FollowSymLinks
AllowOverride None
Order allow,deny
allow from 127.0.0.1/8
allow from 192.168.1.0/29
deny from all
</Directory>
<Directory /var/www/ics/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
# This directive allows us to have apache2's default start page
# in /apache2-default/, but still have / go to the right place
#RedirectMatch ^/$ /apache2-default/
</Directory>

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>

ErrorLog /var/log/apache2/x_error.log
__________________
http://www.gabrix.ath.cx
Reply With Quote
  #17  
Old 7th February 2007, 19:32
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,747 Times in 2,578 Posts
Default

What exactly is the problem right now? Don't your sites work now?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #18  
Old 21st February 2007, 16:37
frgomes frgomes is offline
Junior Member
 
Join Date: Feb 2007
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Try updating /etc/hosts

If you are behind a NAT/firewall, probably your webserver has a local IP address (probably 192.168.xxx.xxx) and your router/firewall is responsible for forwarding incoming requests to your webserver.

In this situation, you have a public IP address for your www.yourdomain.com but, in fact, Apache has to accept requests in your local interface instead of your public IP address (assigned to your router/firewall in fact).

Try something like this in your /etc/hosts:


Code:
127.0.0.1 localhost

# these lines MUST be kept otherwise Apache2 fail serving these addresses
192.168.1.2 subdomain11.yourdomain1.com
192.168.1.2 subdomain12.yourdomain1.com
192.168.1.2 subdomain13.yourdomain1.com
192.168.1.2 subdomain21.yourdomain2.com
192.168.1.2 subdomain22.yourdomain2.com
192.168.1.2 subdomain23.yourdomain2.com


# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts
Enjoy :-)
Reply With Quote
  #19  
Old 8th March 2007, 20:49
gabrix gabrix is offline
Senior Member
 
Join Date: Sep 2006
Location: Napoli
Posts: 186
Thanks: 2
Thanked 0 Times in 0 Posts
Send a message via MSN to gabrix Send a message via Yahoo to gabrix Send a message via Skype™ to gabrix
Default

I have done this the problem remains !!!!
__________________
http://www.gabrix.ath.cx
Reply With Quote
  #20  
Old 23rd March 2007, 01:11
tftd tftd is offline
Junior Member
 
Join Date: Mar 2007
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
 
Post

Hello there ..
I have the same problem. I'm reading almost everything in the network about it and still under apache 1.3.37 it doesn't work.

My NameVirtualHost is the IP of the machine. For example

NameVirtualHost 123.123.123.123:80

<VirtualHost 123.123.123.123:80>
Documen Root /somewhere/subdomain
ServerName www.subdomain.mydomain.com
ErrorLog logs/bla.error_log
</VirtualHost>


And I get the error:

[Fri Mar 23 02:25:42 2007] [warn] NameVirtualHost 123.123.123.123:80 has no VirtualHosts
/usr/local/apache/bin/apachectl start: httpd started
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP doesn't work! JimmiJames Server Operation 1 30th January 2007 13:30
apache virtualhosts permission deneid rolamento Installation/Configuration 3 23rd July 2006 02:36
Apache/Mailman/Postfix VirtualHosts Problem kisong Server Operation 1 15th July 2006 15:09
apache2 not really running blackflag Installation/Configuration 4 9th May 2006 08:50
Domain added multiple times to config adamluz Installation/Configuration 3 11th October 2005 22:52


All times are GMT +2. The time now is 16:12.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.