ini file is being read, but nothing is being rewritten or redirected?!

Topics: User Forum
Aug 2, 2010 at 9:25 PM
Edited Aug 3, 2010 at 1:25 PM

Hi,

I wonder if anyone can shed some light on this for me. After quite a bit of testing and playing about IIRF seems to be installed :)
The iirfstatus page says all is working and the ini file is there.
I have added the following to the ini

RewriteLog C:\Inetpub\iirfLogs\iirf
RewriteLogLevel 5

RewriteEngine ON
StatusUrl /iirfStatus

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^/(.*)$ /index.php?/$1 [L]

With the intention of redirecting http://www.mydomain.co.uk/content/test-article/12 --> http://www.mydomain.co.uk/index.php?/content/test-article/12

This worked fine in Apache, and the rules seem pretty simple and when I test it using TestDriver all seems to do what it should...but when its live it just comes back with a 404 :(

Here is the log file from the last attempt.

Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: actual log file 'C:\Inetpub\iirfLogs\iirf.4392.log'
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: ini file: 'C:\Inetpub\vhosts\dickwalsh.co.uk\httpdocs\Iirf.ini'
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: ini file timestamp: 2010/08/02 22:19:44 GMT Daylight Time
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: line   2: LogLevel = 5
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: pass 1
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: line   5: StatusUrl /iirfStatus
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: line   5: StatusUrl is enabled for local requests only.
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: line   7: RewriteCond   %{REQUEST_FILENAME}  !-f
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: line   8: RewriteCond   %{REQUEST_FILENAME}  !-d
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: line   9: RewriteCond   %{REQUEST_FILENAME}  !-l
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: line  10: RewriteRule (rule 1)  '^/(.*)$'  '/index.php?/$1'      [L]
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: not a duplicate rule...
Mon Aug 02 22:19:57 -  6188 - ParseRuleModifierFlags: '[L]'
Mon Aug 02 22:19:57 -  6188 - ParseRuleModifierFlags: token 'L'
Mon Aug 02 22:19:57 -  6188 - rule: Last
Mon Aug 02 22:19:57 -  6188 - ReadSiteConfig: Done reading, found 1 rules (0 errors, 0 warnings) on 11 lines
Mon Aug 02 22:19:57 -  6188 - GetSiteConfig: Obtain  site '/LM/W3SVC/16455/Root' (era=8) (rc=1) (Expired=0) (ptr=0x01884D30)...
Mon Aug 02 22:19:57 -  6188 - HttpFilterProc: SF_NOTIFY_URL_MAP
Mon Aug 02 22:19:57 -  6188 - HttpFilterProc: cfg= 0x01884D30
Mon Aug 02 22:19:57 -  6188 - HttpFilterProc: SF_NOTIFY_AUTH_COMPLETE
Mon Aug 02 22:19:57 -  6188 - DoRewrites
Mon Aug 02 22:19:57 -  6188 - GetServerVariable_AutoFree: getting 'url'
Mon Aug 02 22:19:57 -  6188 - GetServerVariable_AutoFree: 128 bytes
Mon Aug 02 22:19:57 -  6188 - GetServerVariable_AutoFree: result ''
Mon Aug 02 22:19:57 -  6188 - GetHeader_AutoFree: getting 'url'
Mon Aug 02 22:19:57 -  6188 - GetHeader_AutoFree: 25 bytes   ptr:0x001A9E28
Mon Aug 02 22:19:57 -  6188 - GetHeader_AutoFree: 'url' = '/content/test-article/12'
Mon Aug 02 22:19:57 -  6188 - GetServerVariable_AutoFree: getting 'QUERY_STRING'
Mon Aug 02 22:19:57 -  6188 - GetServerVariable_AutoFree: 1 bytes
Mon Aug 02 22:19:57 -  6188 - GetServerVariable_AutoFree: result ''
Mon Aug 02 22:19:57 -  6188 - GetHeader_AutoFree: getting 'method'
Mon Aug 02 22:19:57 -  6188 - GetHeader_AutoFree: 4 bytes   ptr:0x001AB370
Mon Aug 02 22:19:57 -  6188 - GetHeader_AutoFree: 'method' = 'GET'
Mon Aug 02 22:19:57 -  6188 - DoRewrites: New Url, before decoding: '/content/test-article/12'
Mon Aug 02 22:19:57 -  6188 - DoRewrites: Url (no decoding): '/content/test-article/12'
Mon Aug 02 22:19:57 -  6188 - EvaluateRules: depth=0
Mon Aug 02 22:19:57 -  6188 - DoRewrites: No Rewrite
Mon Aug 02 22:19:57 -  6188 - HttpFilterProc: SF_NOTIFY_LOG
Mon Aug 02 22:19:57 -  6188 - ReleaseOrExpireSiteConfig: site '/LM/W3SVC/16455/Root' (era=8) (rc=0) (Expired=0) (ptr=0x01884D30)...

Any and all help would be fantastic

Thanks
Richard

Aug 3, 2010 at 1:31 PM
Hi,

Just to keep this thread updated, I have updated to version 2.1 to see if that made any difference but its still the same.
I tried changing the iirf.ini file to something simple just to test it and it all seems to be reading the rules but just not executing them :(

Latest iirf.ini:

RewriteEngine ON

RewriteLog C:\Inetpub\iirfLogs\iirf
RewriteLogLevel 5
StatusInquiry ON

RedirectRule ^.*$ http://www.google.com/ [I,R=301]

Has anyone any ideas why this might be happening?

Cheers
Richard

Aug 3, 2010 at 10:54 PM

It's Working!!

The sad thing is i'm not sure what fixed it :(

I basically tried lots of things, then removed it and reinstalled v2.1 and it worked!

Using the following IirfGlobal.ini

NotifyLog OFF
RewriteEngine ON
RewriteFilterPriority MEDIUM
StatusInquiry ON

And one i forgot before and incase any on has the same issues I set the permissions on the Iirf.ini file to the same as the global ini, i don't think this is in the documentation but there you go.

Having a new problem now :( but I will post a seperate thread for that as it's unrelated.

Cheers

Richard