lsapi+ruby+rails=some errors in error.log

#1
Hi,

nice work - I mean LSHTTP. Anyway works great with lsapi. Only I'm wondering, why in HTTP server error log I have lines like below:

2009-11-20 18:42:20.779 [INFO] [95.49.180.126:48829-0#offshoregate.pl] File not found [/opt/offshoregate.pl/html/public/site

Need to mention, that Ruby application works ok, and of course I have controler site. Enough to see offshoregte.pl/site - works ok , so why errors occurs ? Will look forward some input from you guys.

Regards from Poland,
Darek
 
#3
cd..

hello mistwang,

thanks for a quick reply. the problem is not only with site contoller. it is also for all other ruby controllers ie forum, topics, categories as per ruby app.
controlers created and works fine. server is on debian 5 openvz slice.
our lshttpd vhost config is like:

<?xml version="1.0" encoding="UTF-8"?>
<virtualHostConfig>
<docRoot>/opt/offshoregate.pl/html/public</docRoot>
<adminEmails>postmaster@offshoregate.pl</adminEmails>
<enableGzip>1</enableGzip>
<enableIpGeo></enableIpGeo>
<logging>
<log>
<useServer>0</useServer>
<fileName>$VH_ROOT/logs/error.log</fileName>
<logLevel>DEBUG</logLevel>
<rollingSize></rollingSize>
</log>
<accessLog>
<useServer>0</useServer>
<fileName>$VH_ROOT/logs/access.log</fileName>
<pipedLogger></pipedLogger>
<logFormat></logFormat>
<logHeaders>7</logHeaders>
<rollingSize></rollingSize>
<keepDays></keepDays>
<bytesLog></bytesLog>
<compressArchive>0</compressArchive>
</accessLog>
</logging>
<customErrorPages>
<errorPage>
<errCode>404</errCode>
<rem_for_forum>/dispatch.lsapi</rem_for_forum>
<note></note>
</errorPage>
</customErrorPages>
<htAccess>
<allowOverride>0</allowOverride>
<accessFileName></accessFileName>
</htAccess>
<extProcessorList>
<extProcessor>
<type>lsapi</type>
<name>offshoregate.pl</name>
<address>uds://tmp/lshttpd/offshoregate.pl.sock</address>
<note></note>
<maxConns>100</maxConns>
<env>RAILS_ENV=production</env>
<env>LSAPI_CHILDREN=100</env>
<initTimeout>10</initTimeout>
<retryTimeout>30</retryTimeout>
<persistConn></persistConn>
<pcKeepAliveTimeout></pcKeepAliveTimeout>
<respBuffer>0</respBuffer>
<autoStart>1</autoStart>
<path>/opt/offshoregate.pl/html/public/dispatch.lsapi</path>
<backlog></backlog>
<instances></instances>
<extUser></extUser>
<extGroup></extGroup>
<runOnStartUp>1</runOnStartUp>
<extMaxIdleTime></extMaxIdleTime>
<priority></priority>
<memSoftLimit></memSoftLimit>
<memHardLimit></memHardLimit>
<procSoftLimit></procSoftLimit>
<procHardLimit></procHardLimit>
</extProcessor>
</extProcessorList>
<contextList>
<context>
<type>lsapi</type>
<uri>/dispatch.lsapi</uri>
<handler>offshoregate.pl</handler>
<note></note>
<extraHeaders></extraHeaders>
<allowOverride></allowOverride>
<realm></realm>
<authName></authName>
<required></required>
<accessControl>
<allow></allow>
<deny></deny>
</accessControl>
<authorizer></authorizer>
<addDefaultCharset>off</addDefaultCharset>
<defaultCharsetCustomized></defaultCharsetCustomized>
<cachePolicy>
<enableCache></enableCache>
<expireInSeconds></expireInSeconds>
<reqCookieCache></reqCookieCache>
<respCookieCache></respCookieCache>
<ignoreReqCacheCtrl></ignoreReqCacheCtrl>
<ignoreRespCacheCtrl></ignoreRespCacheCtrl>
</cachePolicy>
<enableIpGeo></enableIpGeo>
</context>
</contextList>
</virtualHostConfig>


i don't understand why errors occurs, because dispatch.lsapi taking over and
in public folder no such files like site or topics - they inside ../app/controllers. any help much appreciated.
before i sent you a extract from error.log - below line from access.log refereing to word site:

83.4.47.115 - - [19/Jan/2010:07:58:58 +0000] "GET /images/border2.png HTTP/1.1" 200 183 "offshoregate.pl/site" "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/532.0 (KHTML, like Gecko) Chrome/3.0.195.38 Safari/532.0" "offshoregate.pl"



regards,
darek
 

mistwang

LiteSpeed Staff
#4
Are you using a old version of LSWS? should upgrade to the latest.
And, you are not using the easy rails context configure, but configured the rails dispatcher app manually, that's the reason you get 404 error in log file, but it does not hurt anything, you are using a 404 handler to dispatch request to Rails.
switch to easy rails context will suppress that message.
 
#5
...

hello,

i'm using v4.0.12
with rails tried to configure in many ways, but only present works fine.
i understand no harm in 404 in logs, but like to keep my system tidy.
do you have a pointer to install lsws+ruby+rails in other way to migrate vhost in order to make a better installation ? what you mean: "switch to easy rails context" ??

regards
darek
 
#7
..

hi,

i tried this way but with no luck. will try later on again to create another vhost and start from scratch. thanks for all answers. case closed.

regards,
dariusz
 
Top