We are excited to announce that the IIS.NET Forums are moving to the new Microsoft Q&A experience. Learn more >

URL Rewrite Module - Not working at all [Answered]RSS

8 replies

Last post Dec 10, 2013 12:33 AM by AgrawalAshishS

  • URL Rewrite Module - Not working at all

    May 13, 2011 12:26 PM|AndyString|LINK

    I set up some rewrite rules, and they didn't work at all.  Instead of redirecting to the new URL, I just got a 404 error. IIS didn't seem to even notice that the rules existed.

    As per http://learn.iis.net/page.aspx/467/using-failed-request-tracing-to-trace-rewrite-rules, I tried to turn on Failed Request Tracing to get more details, but found no option for Rewrite in the WWW Server Provider Property Areas. This made me wonder if something was not installed properly.

     However, I found some indications online that this could be due to installing Url Rewrite Module after IIS. Therefore, I went and manually modified the C:\Windows\System32\inetsrv\config\applicationHost.config to contain the needed area. Still all I got was a 404 error, and in the trace, lots of details about the 404 error.

    I thought, "Hmm, well why don't I just reinstall the Rewrite Module 2.0 from the ground up?" I loaded the Web Platform Installer and noticed that it was installed, but no way to remove it. I went to Control Panel > Programs, clicked "Turn Windows features on or off", and nothing related to Rewrite Module seemed to be there. Finally I thought to look under the standard programs list in Programs and Features.  There it was: IIS URL Rewrite Module 2.  I right click and choose "Repair".  Immediately things started working as they were supposed to.

    Talk about waiting until the last step to try the simplest solution. Ah well, such is life some days.

    IIS7 rewrite url corrupt reinstall

  • Re: URL Rewrite Module - Not working at all

    May 16, 2011 01:51 AM|KristoferG|LINK

    Do i understand correctly that this was merely information you shared with us and that you are not currently having any problem?

    Kristofer Gafvert

    http://www.it-notebook.org
  • Re: URL Rewrite Module - Not working at all

    May 16, 2011 05:50 AM|Lloydz|LINK

    Once you have installed URL Rewrite Module, you need to restart IIS Manager for the change. Glad to see your problem have been solved.
    Cheers.

  • Re: URL Rewrite Module - Not working at all

    May 16, 2011 12:17 PM|AndyString|LINK

    Yes, my problem was resolved. I just thought I'd take the time to share the info in case it might help others in future. Thanks.
  • Re: URL Rewrite Module - Not working at all

    May 16, 2011 12:24 PM|AndyString|LINK

    Good point, Lloyd. I forgot to mention that final step.

  • Re: URL Rewrite Module - Not working at all

    May 17, 2011 05:41 PM|mikegmi|LINK

     We have a lot of problems with the rewrite module - occasionally I'll receive a redirect loop error from Firefox, which appears to be related to the URL Rewrite module. Haven't been able to work out how to rectify yet. Recycling the Application Pool seems to help, on occasion.

  • Re: URL Rewrite Module - Not working at all

    May 17, 2011 09:11 PM|Lloydz|LINK

    Hi,

    Since op's issue has been solved, I suggest you open a new thread and post your rules content there. In this case, more community member would take a look at the unsolved case. And with the rule content, we could tell why the loop happen.

    Thanks.

     

  • Re: URL Rewrite Module - Not working at all

    May 07, 2013 08:45 AM|Simon 84|LINK

    Hi! I have the same problem but it doesn't help. I just can't make it work...

    Here is my web.config:

    <modules runAllManagedModulesForAllRequests="true" />
            <rewrite>
                <rules>
                    <rule name="Test">
                        <match url="/aaa.aspx" />
                        <action type="Rewrite" url="/bbb.aspx" />
                    </rule>
                </rules>
            </rewrite>

    and nothing is going on, I just get 404.

  • Re: URL Rewrite Module - Not working at all

    Dec 10, 2013 12:33 AM|AgrawalAshishS|LINK

    Instead for "/aaa.aspx" check for "aaa.aspx". URL rewrite check pattern over rwa url after first /.