Re: Bug#253203: apache will not start due to syntax error

2004-06-10 Thread Fabio Massimo Di Nitto
On Thu, 10 Jun 2004 [EMAIL PROTECTED] wrote:

> On Thu, Jun 10, 2004 at 10:16:34AM -0400, William R. McDonough wrote:
> > I have removed the following lines from my httpd.conf
> >
> > I have no idea why they were in there... but everything works fine without
> > them.
>
> Do  you have mod_perl installed (dpkg --status libapache-mod-perl) ?
>
> > # If the perl module is installed, this will be enabled.
> > ##
> > ##  Alias /perl/ /var/www/perl/
> > ##  
> > ##SetHandler perl-script
> > ##PerlHandler Apache::Registry
> > ##Options +ExecCGI
> > ##  
> > ##
> >
> > Lets close this bug then.
>
> Why close it? Iff these configuration options alone cause a startup problem
> there shure _is_ a bug. Maybe reasign it to  libapache-mod-perl.
>
>

I did test an apache + libapache-mod-perl installation. It works here. It
was the first step i did after your mail about perl.

Fabio

-- 
 fajita: step one
 Whatever the problem, step one is always to look in the error log.
 fajita: step two
 When in danger or in doubt, step two is to scream and shout.




Re: Bug#253203: apache will not start due to syntax error

2004-06-10 Thread rm
On Thu, Jun 10, 2004 at 10:16:34AM -0400, William R. McDonough wrote:
> I have removed the following lines from my httpd.conf
> 
> I have no idea why they were in there... but everything works fine without
> them.

Do  you have mod_perl installed (dpkg --status libapache-mod-perl) ?

> # If the perl module is installed, this will be enabled.
> ##
> ##  Alias /perl/ /var/www/perl/
> ##  
> ##SetHandler perl-script
> ##PerlHandler Apache::Registry
> ##Options +ExecCGI
> ##  
> ##
> 
> Lets close this bug then.

Why close it? Iff these configuration options alone cause a startup problem
there shure _is_ a bug. Maybe reasign it to  libapache-mod-perl.


 Just my 0.02 $ 


   Ralf Mattes

> Thanks to everyone for helping me findout it was perl in my config files.
> 
> 
> 
> 
> -- 
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]




Re: Bug#253203: apache will not start due to syntax error

2004-06-08 Thread rm
On Tue, Jun 08, 2004 at 10:37:45AM -0400, William R. McDonough wrote:
> > Try "bash -x /usr/sbin/apachectl start"
> >
> > --
> 
> + PIDFILE=/var/run/apache.pid
> + HTTPD=/usr/sbin/apache
> + LYNX=lynx -dump
> + STATUSURL=http://localhost/server-status
> + ERROR=0
> + ARGV=start
> + '[' xstart = x ']'
> + '[' -f /var/run/apache.pid ']'
> ++ cat /var/run/apache.pid
> + PID=14803
> + '[' x14803 '!=' x ']'
> + kill -0 14803
> + STATUS=httpd (pid 14803?) not running
> + RUNNING=0
> + '[' 0 -eq 1 ']'

Ok, we're in 67 of apachectl 
The next thing is: 'if /usr/sbin/apache'


> + /usr/sbin/apache
> Bareword found where operator expected at /dev/null line 1, near

Hmm, this looks more like a message from apache starting up.

> "/usr/sbin"
> (Missing operator before bin?)
> Number found where operator expected at /dev/null line 1, near "line 68"
> (Do you need to predeclare line?)
> syntax error at /dev/null line 1, near "/usr/sbin"
> Execution of /dev/null aborted due to compilation errors.
> parse: Success

Haven't done perl in a while, but this looks _awfully_ close to a 
perl error message :-/ Let's test.
 
 $ perl -e '/usr/sbin'
  Bareword found where operator expected at -e line 1, near "/usr/sbin"
(Missing operator before bin?)

Hmm, something seems to feed '/usr/sbin' to a perl interpreter. Do you
by any chance have mod_perl installed and maybe a 'PerlRequire' that loads
the wrong file?


> + echo '/usr/sbin/apachectl start: httpd could not be started'
> + ERROR=3
> + exit 3
> 


 HTH Ralf Mattes
> 
> -- 
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]




Re: Bug#253203: apache will not start due to syntax error

2004-06-08 Thread Matthew Wilcox
On Tue, Jun 08, 2004 at 09:53:49AM -0400, William R. McDonough wrote:
> [EMAIL PROTECTED]: /bin]$ ls -aFl sh
> lrwxrwxrwx1 root root4 May 10 09:42 sh -> bash*
> 
> [EMAIL PROTECTED]: /usr/sbin]$ head -1 /usr/sbin/apachectl
> #!/bin/bash
> 
> [EMAIL PROTECTED]: /usr/sbin]$ apachectl start
> Bareword found where operator expected at /dev/null line 1, near
> "/usr/sbin"
> (Missing operator before bin?)

Try "bash -x /usr/sbin/apachectl start"

-- 
"Next the statesmen will invent cheap lies, putting the blame upon 
the nation that is attacked, and every man will be glad of those
conscience-soothing falsities, and will diligently study them, and refuse
to examine any refutations of them; and thus he will by and by convince 
himself that the war is just, and will thank God for the better sleep 
he enjoys after this process of grotesque self-deception." -- Mark Twain




Re: Bug#253203: apache will not start due to syntax error

2004-06-08 Thread Fabio Massimo Di Nitto
On Tue, 8 Jun 2004, William R. McDonough wrote:

> 34d0b1e7407e3f169028cf0f9cc871b7  /usr/sbin/apache
> 8a5ac7ab4a335b8629e846eb578b86d6  /usr/sbin/apache-modconf
> cf518d10df69144b16f10665bba39348  /usr/sbin/apache-perl
> 8a5ac7ab4a335b8629e846eb578b86d6  /usr/sbin/apache-perlconfig
> e55eebf2281f2398fbdec3568dd242de  /usr/sbin/apache-perlctl
> ef2b2fd1f37114183ca11bd64bea4d36  /usr/sbin/apache-ssl
> 8a5ac7ab4a335b8629e846eb578b86d6  /usr/sbin/apache-sslconfig
> b521ff1a981e7cacf543443128352c51  /usr/sbin/apache-sslctl
> 8a5ac7ab4a335b8629e846eb578b86d6  /usr/sbin/apacheconfig
> a0e409b4d3e70f3a8d7e5b72f1ebe9bd  /usr/sbin/apachectl

They look fine

> > it looks to me like your filesystem is corrupted and something is
> > pointing where it shouldn't. I can't find any better explanation.
>
> That's exactly what I thought too!  That I have some sort of file
> corruption somewhere... but I can't figure out which file Apache is
> complaining about.

hmmm apacheclt is a shell script and uses /bin/sh
Which shell is linked to /bin/sh ? If it is not bash can you try to change
it to /bin/bash?

I think it could be that /bin/sh is a broken symlink or something...

Fabio

-- 
 fajita: step one
 Whatever the problem, step one is always to look in the error log.
 fajita: step two
 When in danger or in doubt, step two is to scream and shout.




Re: Bug#253203: apache will not start due to syntax error

2004-06-08 Thread Fabio Massimo Di Nitto
On Tue, 8 Jun 2004, William R. McDonough wrote:

>
> I've already tried all this... but here's the output for your benefit.
> I was hoping for some sort of gdb or extended debugging ideas to tell me
> what file apache is choaking on.

Can you compare the md5sum?

md5sum /usr/sbin/apache*
34d0b1e7407e3f169028cf0f9cc871b7  /usr/sbin/apache
8a5ac7ab4a335b8629e846eb578b86d6  /usr/sbin/apacheconfig
a0e409b4d3e70f3a8d7e5b72f1ebe9bd  /usr/sbin/apachectl
8a5ac7ab4a335b8629e846eb578b86d6  /usr/sbin/apache-modconf

it looks to me like your filesystem is corrupted and something is
pointing where it shouldn't. I can't find any better explanation.

Fabio

-- 
 fajita: step one
 Whatever the problem, step one is always to look in the error log.
 fajita: step two
 When in danger or in doubt, step two is to scream and shout.




Re: Bug#253203: apache will not start due to syntax error

2004-06-08 Thread Fabio Massimo Di Nitto
On Tue, 8 Jun 2004, Fabio Massimo Di Nitto wrote:

> try to start apache again and keep an eye on /var/log/error.log.

oops /var/log/apache/error.log

Fabio

-- 
 fajita: step one
 Whatever the problem, step one is always to look in the error log.
 fajita: step two
 When in danger or in doubt, step two is to scream and shout.




Re: Bug#253203: apache will not start due to syntax error

2004-06-08 Thread Fabio Massimo Di Nitto
On Mon, 7 Jun 2004, William R. McDonough wrote:

> Package:  apache
> Version:  1.3.31-1
>
> Sometime in the last 24 hours, probably after an upgrade... not sure...
> Apache died and will not restart.
> The error given is not enough information for me to find which file apache
> is complaining about:
>
> [EMAIL PROTECTED]: ~]$ apachectl start
> Bareword found where operator expected at /dev/null line 1, near "/usr/sbin"
> (Missing operator before bin?)
> Number found where operator expected at /dev/null line 1, near "line 68"
> (Do you need to predeclare line?)
> syntax error at /dev/null line 1, near "/usr/sbin"
> Execution of /dev/null aborted due to compilation errors.
> parse: Success
> /usr/sbin/apachectl start: httpd could not be started
>
>
> I'm looking for help to findout which file Apache is complaining about so
> I can fix the syntax.

Uhao... never seen an error like this. I guess i will need your help to
track this problem down.

Please run the following commands for me:

/etc/init.d/apache stop

to be sure nothing is running.

apachectl configtest

that will check if there are obviuos errors in the config files
and repeat the same test executing:

apache -t

If there are errors in the config file please indicate which ones
otherwise you will see a "Sintax OK", but remember that it does not mean
that the config is 100% valid, only the sintax.

try to start apache again and keep an eye on /var/log/error.log.

Try first with /etc/init.d/apache start (and see if it starts) stop it
again and try apachectl start.

Thanks
Fabio

PS I would really appreciate if you can provide me info back asap.

-- 
 fajita: step one
 Whatever the problem, step one is always to look in the error log.
 fajita: step two
 When in danger or in doubt, step two is to scream and shout.