Follow my blog with Bloglovin

Installing Magento eCommerce on Windows and IIS 7

Wednesday, 20 July 2011 15:07 by Ben

Don’t be too put off by the system requirements on the Magentocommerce website, Magento is surprisingly easy to install and run on Windows and IIS 7.

We are currently developing a new ecommerce platform for an online t-shirt business specialising in music t-shirts.  In the past, we have used dashcommerce with great success, for example on Logs Direct. Unfortunately, dashcommerce has ceased to be living open source project.  Also, we develop primarily using mvc.net these days so I wanted to find an ecommerce solution based around mvc.net 3. 

The best mvc.net solution I could find was Orchard.  This is a really great platform but it doesn’t have a mature shop or ecommerce component, which is unfortunate, and perhaps somewhat strange, as I believe the codebase is founded upon Rob Connery’s MVC.NET ecommerce Kona project.

So, despite numerous reservations about Magento (the platform has a reputation for being slow, overly-complex, unwieldy, unsupported on Windows, good at marketing itself but lacklustre at delivering what it promises), I decided to have a bash at installing it on Windows Server 2008 running IIS 7.5 just to see what would happen/how hard it was.  It was surprisingly easy.

These are the steps I followed:

  • Prerequisites: We already have a Windows 2008 IIS 7.5 server setup running a number of PHP platforms (SugarCRM and CakePHP based web applications) so I think this helped a bit.  I didn’t have to install any extra components but these are the relevant ones I believe you need to install using the web platform installer:
    1. PHP 5.2.17
    2. IIS: CGI
    3. Windows Cache Extension 1.1 for PHP 5.2
    4. URL Rewrite 2.0
  • Install MYSQL: Once you have IIS setup, you also need a working mysql instance http://dev.mysql.com/downloads/
  • Upload Magento Install: Create a new website in IIS and copy/FTP the Magento 1.5.10 install files into the website directory.
  • Setting up the URL re-write rules:  This step is the key to a smooth Magento install.  Create a new web.config file in the base install directory and then copy the following URL rewrite rules in:
  • <?xml version="1.0" encoding="UTF-8"?> 
       <configuration> 
        <system.webServer>
        <rewrite>
        <rules> 
         <rule name="Imported Rule 1" stopProcessing="true"> 
          <match url=".*" ignoreCase="false"/>        <conditions> <add input="{URL}" pattern="^/(media|skin|js)/" ignoreCase="false" negate="true" /> 
          <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" /> 
          <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" /> 
        </conditions> <action type="Rewrite" url="index.php" /> 
        </rule> 
       </rules> 
       </rewrite> 
      </system.webServer> 
    </configuration>
  • Permissions: I also encountered some permission problems which were a little tricky to diagnose as magento hides errors by default.  You simply receive a generic “There has been an error processing your request” message.  To print errors to screen, I followed the guide here - http://www.designersandbox.com/magento/fix-for-magento-1-4-install-does-not-work/.  

Currently rated 3.0 by 12 people

  • Currently 3/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Comments

Add comment


(Will show your Gravatar icon)  

  Country flag

biuquote
  • Comment
  • Preview
Loading