In this lesson/tutorial I will show you how to install Commerce Server 2009 and all needed for a development platform on a single machine, standalone installation, not farm, meaning that all needed will be on the same machine : Windows Server 2008, Sql Server 2008, IIS 7.0, Windows Sharepoint Services 3.0, Visual Studio 2008, etc.
This installation will be for educational purposes, in real life situation farm installation being advised. It would be better for the overall performance/ security /mantainance to have a separate Sql Server Machine and separate Sharepoint Server for example.
Being a Microsoft product you would expect an easy installation with next, next – finish setup.
Well this is not the case, the setup being a long process with traps along the way.
I will try to show you the steps for installing and configuring Commerce Server 2009 .
Step number 1. Prepare Windows Server Environment
Let`s say you have installed Windows Server 2008.
This platform is for building B2X ecommerce applications/ websites, so the first thing you would need is IIS 7.0 or 7.5 Web Server.
For this you have to go to Server Manager – > Roles – > Add Role -> Web Server (IIS)
Next you have to select the Role services .
Select
- Application development (if other features need to be installed you will be prompted with a new form. Click on the “Add Requiered Features” button.
- From Security select
- Basic Authentication,
- Client Certificate Mapping Authentication
- IIS Client Certificate Mapping Authentication
- From Management Tools select All
Click next and Install.
Step number 2. Install SQL Server R2 Express
Next you have to install Sql Server 2008 R2 Express. I chose the Sql Server Express with Advanced Services package because it includes the Reporting Services, which could be useful.
http://www.microsoft.com/download/en/details.aspx?id=25174
Download the package from Microsoft, enter the setup then click on “New Installation or add features to an existing installation button”.
Observation on the installation:
- If you get this:
Then go to Server Manager -> Features -> Add Features – > Windows PowerShell
- You should select the features below at the Sql Server Install:
.
- You could select any name for your Server, but I advise you to let the default SQLExpress name for future references
- In the Server Configuration Section Select the Sql Browser Services and select the Automatic Startup Type:
- At DataBase Configuration Add the current User (should be administrator account)
- After the installation go to SQL Management Studio and verify your instance name
Step number 3. Visual Studio Installation
Install Visual Studio 2008/2010 and Services Packs if they exists (for example Visual Studio 2008 had a SP1 edition)
Step number 4. SharePoint Installation
SharePoint installation
Download Windows SharePoint Services 3.0 or SharePoint Foundation 2010 from Microsoft .
Find and choose the x86 or x64 version, based on your machine .
Observation
- Install in Advanced Mode
- Choose Web Front End Server Type
- At the end check the “Run the SharePoint Products and Technologies Configuration Wizard now” and click the close button and then :
- At Connect to a Server farm Screen choose “No, I want to create a new server farm”
- At the next step choose the right instance name of your database server (You could go to Sql Management Studio and copy paste the Server Name. It could be only the servers name (usually when you have a higher version of the Express Server) or MachineName\InstanceName) . In our case it is “Ecommerce\SQLEXPRESS”
At the username choose your administrator account (You could make an account with the specific rights for Sharepoint Administration)
After the installation/ configuration go to SharePoint Central Administration (program files) , to Operations Tab -> Services on Server from Topology and Services :
Select the Windows SharePoint Services Search and click on Start :
Next use your Administrators credentials in the User Name and Passwords textboxes and Context Access Acount ad then click start :
Then, go to Central Administration again, Application Management, Create or Extend Web Application and click “Create a new Web Application”.
Choose a new port, for example 8088, and choose your Adminstrators credentials for the application pool:
Select your Windows Sharepoint Services search Server, in this situation being the current machine :
Step number 5. Commerce Server 2007 Installation
Insert the first part/cd of the Commerce Server 2009 installation package, and install Commerce Server 2007 (Commerce Server 2009 is based on 2007)
Install in this order :
- Commerce Server 2007 (other than the one below use default settings in the wizard)
- Choose Direct Mailer from components (it is useful for the Marketing System)
At the end of the installation wizard uncheck the “Launch the Commerce Server Configuration Wizard” and click finish .
- Next install the Microsoft Commerce Server Business User Applications with default wizard settings.
Step number 6. Commerce Server 2009 Installation
Insert the second part/cd of the Commerce Server 2009 installation package, and install Commerce Server 2009 .
In the Commerce Server Configuration Wizard
- Select the right Sql Server name : Ecommerce\SQLEXPRESS (in our case). Click Test to test the sql server connection.
- Use the Adminstrator credentials for direct mailer service account (you could make a user just for this service )
In the Upgrade Wizard :
- You should select a different location for the log file, to know its location precisely if something does not work as planed
Next go to Program Files, Commerce Server 2009, Tools and start Sharepoint Commerce Server Configuration Wizard
- Select Commerce SharePoint Default Web Site and Web Parts
- Use the web application that we created earlier (SharePoint – 8088), Select “Unpack Commerce Server Site(With Sample Data) and enter the right instance of the Database Server :
Next go to Program Files, Commerce Server 2009, Tools and start Site packager :
- Select Unpack from a package file (.pup)
- Select custom unpack, click browse and go to Program Files, Commserce Server 2007, Commerec Server 2009, Site and select MicrosoftCommerceDefaultSiteWithSampleData.pup
- Select Add an Application in the package to an existing site
- All of the other steps are with default values
Step number 7. Commerce Server 2009 Configuration
Now we have to configure the Business tools (Catalog Manager, Customers and Orders Manager, Marketing Manager, etc. )
We have to create a user for every web service the sdk uses for the business tools :
Go to Server Manager – > Configuration – > Local Users and Groups -> Users – > New User -> Insert CatalogWebSvc as the UserName and set its password (uncheck “User Must Change password at next logon”. I also unchecked “Password never expires”)
Add the user RunTimeUser also, using the same steps described before.
Also create the users : MarketingWebSvc , OrdersWebSvc, ProfilesWebSvc
Then go to Logal Users and Groups to Groups.
- Add the group CatalogAdminGroup and add the CatalogWebSvc user.
- Add the group MarketingAdminGroup and add MarketingWebSvc user.
- Add the group OrdersAdminGroup and add OrdersWebSvc user.
- Add the group ProfilesAdminGroup and add ProfilesWebSvc user.
- Find the IIS_IUSRSGroup and add the following users :
- RunTimeUser
- CatalogWebSvc
- OrdersWebSvc
- ProfilesWebSvc
- MarketingWebSvc
Go to Internet Information Services (IIS Manager in Administrative Tools) – > Application Pools (right click on it) and create the following Application Pools(select Classic Managed Pipeline Mode):
- CatalogWebSvcAppPool
- OrdersWebSvcAppPool
- ProfilesWebSvcAppPool
- MarketingWebSvcAppPool
Next go to CatalogWebSvcAppPool -> Advanced Settings->
Select the Identity from Process Model :
Select Custom Account and add CatalogWebSvc user .
Do the same to
- OrdersWebSvcAppPool ( associate the OrdersWebSvc user )
- ProfilesWebSvcAppPool ( associate the ProfilesWebSvc user )
- MarketingWebSvcAppPool ( associate the MarketingWebSvc user )
Go to Sites (from IIS maneger) ->Default Web Site – > Default_CatalogWebService -> Advanced Settings > and change the Application pool to CatalogWebSvcAppPool :
Do the same (and associate the appropriate Application pool ) with:
- “DefaultSite_MarketingWebService”
- “DefaultSite_OrdersWebServiec”
- “DefaultSite_ProfilesWebService”
Open Sql Management Studio and go to Security Logins :
- New Login – > Add the RunTimeUser (Windows Auth), in this case Ecommerce\RunTimeUser
Then you add the other 4 users :
- Ecommerce\CatalogWebSvc
- Ecommerce\OrdersWebSvc,
- Ecommerce\ProfilesWebSvc,
- Ecommerce\MarketingWebSvc,
Now we have to configure the user mappings and permissions every users has.
- Select ECOMMERCE\CatalogWebSvc from Logins, go to User Mappings and select(check) MSCS_Admin and add the admin_reader_role.
Check the MSCS_CatalogScratch database and add the roles:
- db_ddladmin
- db_datawriter
- db_ddladmin
Check DefaultSite_productcatalog database and select:
- ctlg_CatalogWriterRole
- db_datareader
- db_datawriter
- db_ddladmin
- db_securityadmin
- Inventory_ReaderRole
- Inventory_WriterRole
- Select the ECOMMERCE\MarketingWebSvc user from logins and go to User Mappings .
Check MSCS_Admin database and select admin_reader_role .
Check MSCS_CatalogScratch database and select the roles :
- Db_datawriter
- Db_datareader
- Db_ddladmin
Check DefaultSite_Marketing database and select the roles :
- Mktg_marketing_Service_Role
- Mktg_runtime_role
- Mktg_promoCodeGenerator
Check DefaultSite_marketing_lists database and select the dbo_owner role.
Check DefaultSite_productcatalog database and select the roles :
- Ctlg_CatalogReaderRole
Check DefaultSite_profiles database and select the roles :
- Profile_Reader
- Profile_Schema_Reader
- Select the ECOMMERCE\OrdersWebSvc user from logins and go to User Mappings .
Check MSCS_Admin database and select admin_reader_role .
Check MSCS_CatalogScratch database and select the roles :
- Db_datawriter
- Db_datareader
- Db_ddladmin
Check DefaultSite_productcatalog database and select the roles :
- Ctlg_CatalogReaderRole
- Inventory_ReaderRole
Check DefaultSite_transactionconfig database and select the roles :
- Orders_Management
Check DefaultSite_transactions database and select the roles :
- Orders_Management
- Orders_Runtime
Check DefaultSite_Marketing database and select the roles :
- Db_ddladmin
- Mktg_runtime_role
- Select the ECOMMERCE\ProfilesWebSvc user from logins and go to User Mappings .
Check MSCS_Admin database and select admin_reader_role .
Check DefaultSite_profiles database and select the roles :
- Profile_Schema_Manager
- Profile_Runtime
- Select the ECOMMERCE\RunTimeUSer user from logins and go to User Mappings .
Check MSCS_Admin database and select admin_reader_role .
Check MSCS_CatalogScratch database and select the roles :
- Db_datawriter
- Db_datareader
- Db_ddladmin
Check DefaultSite_Marketing databae and select the roles :
- Db_ddladmin
- Mktg_runtime_role
Check DefaultSite_marketing_lists database and select the db_datareader role.
Check DefaultSite_productcatalog database and select the roles :
- Ctlg_CatalogReaderRole
- Inventory_RuntimeRole
Check DefaultSite_profiles database and select the roles :
- Profile_Runtime
- Profile_Schema_Reader
Check DefaultSite_transactions database and select the roles :
- Orders_Runtime
Check DefaultSite_transactionconfig database and select the roles :
- Orders_Runtime
Configuring the Catalog Manager
Go to Start and write azman.msc in execute and press enter. Go Actions->Open Authorisation Store- > Browse c:\inetpub\wwwroot\DefaultSite_catalogWebService and select the CatalogAuthorizationStore xml file .
Go to CatalogInventorySystem-> Role Assignments -> Administrator , right click on the empty right part (where it writes “There are no items to show in this view) and Assign Users and Groups (from active directory) and add CatalogAdminGroup and your Administrator Account .
I also added the administrator account to every other role in the role assignments, but I do not think it is necessary, so feel free to try it without the last part.
Go to IIS Management tool -> Sites -> Default Web Site -> DefaultSite_CatalogWebService -> browse and add the CatalogWebService.asmx part to the end of the url in the browser.
It should be something like this :
http://ecommerce/DefaultSite_CatalogWebService/CatalogWebService.asmx
Go to Program Files and open the Catalog Manager from Commerce Server 2009.
At first run you will get an error. Press ok and then edit the url path of the webservice and add the url from above:
http://ecommerce/DefaultSite_CatalogWebService/CatalogWebService.asmx
and press ok. You will get another error. If you check the event viewer you will see that that it does not have rights to access the AuthorizationStore.xml.
All you have to do is to go to c:\inetpub\wwwroot\DefaultSite_CatalogWebService, folder properties, security , edit -> add user , and there you add the administrator account and CatalogWebSvc User with full control .
Do the same to the folders c:\inetpub\wwwroot\DefaultSite_MarketingWebService, but add the MarketingWebSvc user, c:\inetpub\wwwroot\DefaultSite_OrdersWebService, but add the OrdersWebSvc user and c:\inetpub\wwwroot\DefaultSite_ProfilesWebService, but add the ProfilesWebSvc user.
If you open the Catalog Manager again it should work.
Configuring the Customers and Orders and Marketing Manager
Go to IIS Manager, the main node (with the machine name, in this case ECOMMERCE) and go t Server Certificates :
Create Self-Signed Certificate, and give it the machine name : ECOMMERCE
Now go to Sites->Default Web Site -> Bindings -> Add and choose https with the newly created certificate (ECOMMERCE)
For the other Business tools to work we have to configure the roles in azman.msc as we did with the CatalogManager:
Go to azman.msc again. Right Click on the first node (Authorization Manager) Open Authorization Store, and go to c:\inetpub\wwwroot\DefaultSite_MarketingWebService\ and open the MarketingAuthorizationStore.xml
Go to the MarketingSystem subnode -> Role Assignments and add MarketingAdminGroup to MarketingAdministrator Role
Right Click on the first node (Authorization Manager) Open Authorization Store, and go to c:\inetpub\wwwroot\DefaultSite_OrdersWebService\ and open the OrdersAuthorizationStore.xml
Go to the OrdersSystem subnode -> Role Assignments and add OrdersAdminGroup to OrdersAdministrator role and Admin to OrdersViewer role
Right Click on the first node (Authorization Manager) Open Authorization Store, and go to c:\inetpub\wwwroot\DefaultSite_ProfilesWebService\ and open the ProfilesAuthorizationStore.xml
Go to the ProflesSystem subnode -> Role Assignments and add ProfilesAdminGroup and the Administrator account to ProfilesAdministrator role
Go to DefaultSite_OrdersWebService(iis manager -> sites->Default Web Site – > Default_OrdersWebService browse (https 443) and add the OrdersWebServices.asmx to the url .
It should look like this : https://ecommerce/Default_OrdersWebService/OrdersWebServices.asmx
Do the same with the profiles webservices :
https://ecommerce/default_profileswebservices/profileswebservice.asmx
Go to start and in the program files find the Customers and Orders tool from Commerce server and open it.
Click the edit button and edit the webservices url . Use the two urls from above for the orders webservice and profile web services and the url we mentioned at the Catalog Manager : http://ecommerce/DefaultSite_CatalogWebService/CatalogWebService.asmx
Now go to start button again and in the proram files find the Marketing Manager tool and open it.
Click the edit button and set the webservices straight :
http://ecommerce/DefaultSite_MarketingWebService/MarketingWebService.asmx for the marketing webservice and the mentioned above url for the CatalogWebService .
Commerce Server Starter Site
As you might remember, we unpacked a site with sample data on the Sharepoint – 8088 web application.
Let`s try the website. Enter the url in the browser : http://ecommerce:8088
The site should load, but you will have some webpart errors.
Go to site actions – > Site Settings -> User And Permissions -> Advanced permissions
Then in the left side click on Channel Configuration. Click on Channel , edit item and write “DefaultChannel”(without commas) in the value textbox .
Go back, click DefaultCatalog, edit, and write “Adventure Works Catalog” (without commas) in the value textbox and press ok.
Go back to http://ecommerce:8088 . It should work now.
We still have something to do though. If you write something in the search box, like big sur, for example, you will get a page that says results have been found, but you do not see them.
Click site actions again, edit page, and go to Search Results Web Part and click on Modify Shared Web Part :
In the right side of the page a panel will appear .
Go to Commerce tab -> (Tab 2) Content Type and select “None”
[i] Gheorghe Dan-Alexandru




























