On Mon, 2004-04-05 at 12:14 -0500, Will Trillich wrote: > okay. we're trying to use <perl> to configure virtual hosts -- here's > Data::Dumper showing the %VirtualHost hash:
At a quick glance, you most certainly must have meant: %VirtualHost = ( [...] ); instead of %VirtualHost = { [...] ); > %VirtualHost = { > '*:80' => [ > { > 'PerlSetVar' => [ > 'SiteName', > 'one' > ], > 'Directory' => { > '/var/www/one' => { > 'Options' => [ > '+Indexes', > ], > 'FilesMatch' => { > '^[A-Z]|\\.mc$' => { > 'SetHandler' => 'perl-script', > 'PerlResponseHandler' => 'Apache::NOT_FOUND' > }, > '\\.(html|css)$' => { > 'SetHandler' => 'defaulthandler' > } > } > } > }, > 'ServerName' => 'one', > 'DocumentRoot' => '/var/www/one', > 'ServerAlias' => [ > 'five', > 'seven' > ] > }, > { > 'PerlSetVar' => [ > 'SiteName', > 'three' > ], > 'Directory' => { > '/var/www/three' => { > 'Options' => [ > '+Indexes', > ], > 'FilesMatch' => { > '^[A-Z]' => { > 'SetHandler' => 'perl-script', > 'PerlHandler' => 'Apache::NOT_FOUND' > }, > '\\.(html|css)$' => { > 'SetHandler' => 'defaulthandler' > } > } > } > }, > 'ServerName' => 'three', > 'DocumentRoot' => '/var/www/three' > } > ] > }; > > site "one" has aliases "five" and "seven"; site "three" is on > its own. (we're testing, see -- /etc/hosts has all these names > as aliases for "localhost".) > > when trying to use this config, apache2 belches > > NameVirtualHost *:80 has no VirtualHosts > > we'd love to know why. pointers are very welcome! > > === > > what search terms could we use at google to get pertinent > results? we've tried > > apache2 'has no virtualhosts' > > and see lots of questions similar to ours, but no definitive > answer has crossed our radar just yet... > > we also found the source code to "vhost.c" -- and the error > message comes from function "remove_unused_name_vhosts()" which > heavily implies that when the error message shows up, the vhost > goes away... except when we browse to > > http://three/ > > or > > http://five/ > > we get the site we originally expect; when we visit one of the > two aliases, tho, we get the uber-root (/var/www instead of > /var/www/one). so now we're more confused than ever. :) > > ==== hey! > > not knowing even enough to dig a deep hole, looking at > remove_unused_name_vhosts() we see > > *pic = ic->next; > > and later > > *pic = &ic->next; > > is the ampersand superfluous? is this a typo? > > -- > will trillich > mayhugh services > 812 423 6314 voice > 812 423 6303 fax > > > > -- > Report problems: http://perl.apache.org/bugs/ > Mail list info: http://perl.apache.org/maillist/modperl.html > List etiquette: http://perl.apache.org/maillist/email-etiquette.html -- -------------------------------------------------------------------------------- Philippe M. Chiasson m/gozer\@(apache|cpan|ectoplasm)\.org/ GPG KeyID : 88C3A5A5 http://gozer.ectoplasm.org/ F9BF E0C2 480E 7680 1AE5 3631 CB32 A107 88C3A5A5
signature.asc
Description: This is a digitally signed message part