Not logged in. · Lost password · Register
Forum: General Help and Support Server Setup RSS
Apachectl status is broken with dokuwiki
damascene #1
Member since Dec 2010 · 35 posts
Group memberships: Members
Show profile · Link to this post
Subject: Apachectl status is broken with dokuwiki
I've setup dokuwiki with 404 for non existent pages, when I call server-status with this command:

apachectl status

I get some wired characters the last few lines from it are:


[ a+e+r+dd m+c+d+r+ a+l+c+f+hktm ]
   [ n+s+x+ q+d+y+m+tm ]
   [ Media Manager ]
   [ l+g+ ]
   [ x+r+y+tjtm m+w+q+e+ ]
   [ a+r+g+e+ l+l+aHe+l+j+ ] 
   m+a+l+m+ y+snr+ l+x+l+a+f+ dkl+k+,+ f+ahn+ a+l+m+hkt+w+j+ f+y+ h+dkh+
   a+l+w+y+k+y+ m+r+x+c+ w+f+q+ a+l+r+x+c+tm a+l+t+a+l+y+tm: CC
   Attribution-Share Alike 3.0 Unported
   Recent changes RSS feed [IMG] Donate Powered by PHP Valid XHTML 1.0 Valid
   CSS Driven by DokuWiki


it seems it's getting Dokuwiki page does not exist. here how it looks in server log:

localhost - - [30/May/2012:05:22:14 +0300] "GET /server-status HTTP/1.1" 404 3524 "-" "Links (2.2; Linux 2.6.****)"

How do I fix that?
A guide for life http://i-g.org
Avatar
schplurtz #2
Member since Nov 2009 · 87 posts · Location: France, Finistère
Group memberships: Members
Show profile · Link to this post
Hi,
Quote by damascene:
it seems it's getting Dokuwiki page does not exist. here how it looks in server log:

localhost - - [30/May/2012:05:22:14 +0300] "GET /server-status HTTP/1.1" 404 3524 "-" "Links (2.2; Linux 2.6.****)"
Hum, /server-status goes into DW... You must have activated some rewriterules in apache. Does it help if you add RewriteCond %{REQUEST_URI} !^/server-status$ below the other rewriteconds in your apache config file as is suggested on http://www.dokuwiki.org/rewrite ?

...
RewriteCond %{REQUEST_FILENAME}       !-f
RewriteCond %{REQUEST_FILENAME}       !-d
RewriteCond %{REQUEST_URI} !^/server-status$
...

/Schplurtz
http://schplurtz.free.fr/wiki/
damascene #3
Member since Dec 2010 · 35 posts
Group memberships: Members
Show profile · Link to this post
no it does not. rules are like this in .htaccess

RewriteRule ^_media/(.*)              lib/exe/fetch.php?media=$1  [QSA,L]
RewriteRule ^_detail/(.*)             lib/exe/detail.php?media=$1  [QSA,L]
RewriteRule ^_export/([^/]+)/(.*)     doku.php?do=export_$1&id=$2  [QSA,L]
RewriteRule ^$                        doku.php  [L]
RewriteCond %{REQUEST_FILENAME}       !-f
RewriteCond %{REQUEST_FILENAME}       !-d
RewriteCond %{REQUEST_URI} !^/server-status$
RewriteRule (.*)                      doku.php?id=$1  [QSA,L]
RewriteRule ^index.php$               doku.php
A guide for life http://i-g.org
Avatar
schplurtz #4
Member since Nov 2009 · 87 posts · Location: France, Finistère
Group memberships: Members
Show profile · Link to this post
Hello,

That's strange. I made a quick tests with a copy/paste of your post in a .htaccess. apachectl status is broken without the rewritecond and is working when the rewritecond is there...

Anyway, during the tests, while playing with wget, I managed to create a file called server-status in the same directory as doku.php. This, prevented the rewrite mecanism and made apachectl status work, even without the rewritecond. So, you may try this hack : create an empty file named server-status in the directory that contains doku.php. That's ugly, but may work for you too.

/Schplurtz.
http://schplurtz.free.fr/wiki/
damascene #5
Member since Dec 2010 · 35 posts
Group memberships: Members
Show profile · Link to this post
Creating an empty file worked for me. Thanks
Any way, I wonder if I should report this as a bug, should I?
A guide for life http://i-g.org
Avatar
schplurtz #6
Member since Nov 2009 · 87 posts · Location: France, Finistère
Group memberships: Members
Show profile · Link to this post
Glad it worked.

i think you should not report a bug. It's an apache problem, not a DW problem. perhaps, you can enhance the doc at http://www.dokuwiki.org/rewrite#some_notes .

/Schplurtz
http://schplurtz.free.fr/wiki/
damascene #7
Member since Dec 2010 · 35 posts
Group memberships: Members
Show profile · Link to this post
done
http://www.dokuwiki.org/rewrite#apachectl_status_broken

though I'm still not convinced that this is an apache problem.
A guide for life http://i-g.org
Avatar
Andreas (Moderator) #8
Member since Dec 2009 · 264 posts · Location: Karlsruhe, Germany
Group memberships: Global Moderators, Members, Super Mods
Show profile · Link to this post
In reply to post #3
Quote by damascene on 2012-06-01, 09:36:
RewriteCond %{REQUEST_URI} !^/server-status$

I'm pretty sure the leading slash must not be there, has anyone tried RewriteCond %{REQUEST_URI} !^server-status$ ?
I'm so electronic I shit bits
damascene #9
Member since Dec 2010 · 35 posts
Group memberships: Members
Show profile · Link to this post
Sorry for this, the rewrite condition works, I've put it in another wiki instance by mistake which prevented it from working. no need for the empty file.
RewriteCond %{REQUEST_URI} !^/server-status$
A guide for life http://i-g.org
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum
Imprint
This board is powered by the Unclassified NewsBoard software, 20120620-dev, © 2003-2011 by Yves Goergen
Current time: 2014-04-18, 07:56:38 (UTC +02:00)