|
Key
This line was removed.
This word was removed. This word was added.
This line was added.
|
Comment:
Changes (1)
View Page HistoryThis guide will explain how to set up the ECF SDK with Mediachase's Content Management system (CMS) version manually on your local machine. This guide is useful if you have problems with the {color:#ff0000}[installer|ecf51installanddeploy:SDK Installation Using Installer]{color} or want to learn more about the installation process. A typical installation will take anywhere between 30 - 60 minutes, depending on your knowledge and experience with IIS and ECF.
If this i is your first time manually installing ECF, this might feel overwhelming. Some knowledge of IIS, SQL Server, and XML would be helpful, but we provide step-by-step instructions.
*Before proceeding*, please review the System Requirements *[here|ecf51installanddeploy:System Requirements]*.
h3. *Overview*
Here is an overview of what you will be doing during the installation:
*Step 1*: Unzipping the ECF package
*Step 2*: Setting up your Web server
*Step 3*: Setting up your SQL server database
*Step 4*: Modifying the config files to fit your environment
*Step 5*: Importing the Sample Site, catalogs, and indexing your search
*Step 6*: Starting your Quartz service
*Step 7*: Installing a license key (not necessary if working with localhost)
h3. Step 1: Unzipping the ECF Package
* Unzip the *Mediachase.ECF.SDK.5.1* package.
For information on obtaining a package for evaluation or for purchase, please contact *[Sales|mailto:sales@mediachase.com]*.
* Click through the folder and then copy the *Mediachase* folder to the location where you will be setting us the ECF.
** If you don't have any preference you may either place it in the C:\Program Files directory or in the root level of the directly setting up your site.
* Open the *Data* folder and then unzip the *DeploymentPackage* folder. Once it's unzipped, open the folder and copy the *B2CSampleSite* folder to your IIS root which is usually located at C:\inetpub\wwwroot or whichever directory you use to run your sites
h3. *Step 2*: Setting up your Web Server
* In this section we will show you how to set up the Web Server by configuring IIS settings for Windows 2008 and Windows 7/Vista. If you have a different OS, skip to the [#Other OS]
*Configure Your Web Server for Window Server 2008, Windows 7, and Vista (IIS 7)*
Start IIS by going to Start > Administrative Tools > Internet Information Services (IIS) Manager.
Add a new web site.
* Right click on *Sites* and then click on *Add New Site*
* Enter into the following fields:
** Site name: "eCommerceFramework - 80" or whatever you like
** Application pool: Keep it same as the site name
** Physical path: *C:\inetpub\wwwroot\B2CSampleSite* (or any other IIS root location you are using)
Create a new Application Pool with a name identical to the Site name, (e.g., eCommerceFramework - 80) in this case.
* Choose *.NET Framework v2.0.50727* for .NET Framework version option.
* Choose *Classic* for *Manage pipeline mode* option.
Add three Virtual Directories ("_cmsbase", "_cmsctrls", "Apps") in the "eCommerceFramework - 80" web site and set their physical paths to their respective folders in the Shared folder contained in the Mediachase folder you initially moved to Program Files.
* Right click on the "eCommerceFramework - 80" web site. Select the command to add a new virtual directory and enter the following information:
** Alias: \_cmsbase
** Physical path: *C:\Program Files\Mediachase\eCommerceFramework\5.1\Shared_cmsbase* (or any other path)
** Virtual Directory Access Permission: *Read & Execute*
** Repeat these steps to create the other two Virtual Directories.
Check your permissions.
* Verify that a *searchindex* folder is located in the App_Data folder. If not, manually create it.
* Then, grant whatever account is running your site in IIS *Modify* privileges for the App_Data folder and its sub-folders.
Once you are done with these steps you should see something like this:
!ManualInstallationIIS7.png|thumbnail,border=1!
{anchor:Other OS}
{color:#000000}{*}Click on the relevant links below if you are using a different OS:*{color}
*[Windows Server 2003|#IIS 2003]*
*[Windows XP|#IIS XP]*
h3. *Step 3*: Setting up your SQL Server Database
Ensure that the database name, database user name, and database user password you use to create this database is unique.
Open a command prompt and go to "~\Mediachase.ECF.SDK.5.1\Data\DeploymentPackage\SqlScripts\Helpers."
Then run the following command:
{code}
call setup.bat (database admin user) (db admin password) (db server name) (db name) (db user) (db user password) (application name)
{code}
!ManualInstallationCMD.png|thumbnail,border=1!
*Property Definitions:*
\[database admin user\]: Username for the SQL Administrator
\[db admin password\]: Password for the SQL Administrator
\[db server name\]: SQL Server name (e.g., localhost)
\[db name\]: Database Name
\[db user\]: Database user name with dbo rights
\[db user password\]:Database user password
\[application name\]: Application Name should equal the IIS Web Site name or Web Application name you specified in Step 2 (in this example "eCommerceFramework - 80")
After you run the command you'll see the command line re-appear once the script is done.
!ManualInstallationDB_B2CSampleSite.png|thumbnail,border=1!
If the script ran successfully, you'll see the database named ECF51_B2CSampleSite appear in SQL Server administration. If you access the Tables folder of the database as the image about, you should also see hundreds of items listed there.
h3. *Step 4*: Modifying the Config Files to Fit Your Environment
This is the manual method of updating ECF configuration files, requiring you to directly edit XML.
*Optional:* If you prefer, you can use a {color:#ff0000}[program tool|#UpdateConfigTool]{color} to automatically update and edit the configuration files.
You need to edit five configuration files located in the B2CSampleSite and Quartz Service:
* C:\inetpub\wwwroot\B2CSampleSite*connectionStrings.config\*
* C:\inetpub\wwwroot\B2CSampleSite*Web.config\*
* C:\inetpub\wwwroot\B2CSampleSite\Configs*Mediachase.Search.config\*
* C:\Program Files\Mediachase\eCommerceFramework\5.1\QuartzService*connectionStrings.config\*
* C:\Program Files\Mediachase\eCommerceFramework\5.1\QuartzService*Mediachase.Search.config\*
*Configure Database Connection Settings*
Update ..\B2CSampleSite\connectionStrings.config and ..\Mediachase\eCommerceFramework\5.1\QuartzService\connectionStrings.config so that your ECF solution will point to the database you created earlier.
{code:xml}
<?xml version="1.0" encoding="utf-8"?>
<connectionStrings>
<add name="EcfSqlConnection" connectionString="Data Source=DATABASE SERVER;Initial Catalog=DATABASE NAME;User ID=SQL ADMIN;Password=SQL ADMIN PASSWORD;Application Name=eCommerceFramework" />
<add name="XmlActionSetProvider" connectionString="~/_cmsbase/Design/actions.config" providerName="XmlActionSetProvider" />
</connectionStrings>
{code}
*Property Definitions:*
DATABASE SERVER: SQL Server name (e.g., localhost)
DATABASE NAME: Name you set up for the database. In our example, it would be ECF51_B2CSampleSite.
SQL ADMIN*:\* Username for the SQL Administrator
ADMIN PASSWORD: Password for the SQL Administrator
For more information on how ConnectionStrings elements are configured refer to [http://msdn.microsoft.com/en-us/library/bf7sd233.aspx].
*Configure Search Index*
In *..\B2CSampleSite\Configs\Mediachase.Search.config* and *..\Mediachase\eCommerceFramework\5.1\QuartzService\Mediachase.Search.config*, update the path to point to the *SearchIndex* folder located in "\B2CSampleSite\App_Data\".
{code:xml}
<?xml version="1.0" encoding="utf-8"?>
<Mediachase.Search>
<Indexers>
<add name="CatalogEntryIndexer" type="Mediachase.Search.Extensions.Indexers.CatalogIndexBuilder, Mediachase.Search.Extensions" basePath="(SITE ROOT FOLDER)\App_Data\SearchIndex">
</add>
</Indexers>
</Mediachase.Search>
{code}
*Configure Application Name*
On line 2 of the ..\B2CSampleSite\Configs\ecf.app.config file, replace "Application Name" with "eCommerceFramework" or any other application name you decide to use.
{code:xml}
<?xml version="1.0" encoding="utf-8"?>
<Application defaultApplicationName="APPLICATION NAME">
{code}
*Web Configuration*
Also in the ..\B2CSampleSite\Web.config file, there are five Application Names that needs to be specified. Just as the above step, replace "Application Name" with "eCommerceFramework", or an application name of your choosing.
{code:xml}
<dataService defaultProvider="SqlDataProvider">
<providers>
<add name="SqlDataProvider" type="Mediachase.Data.Provider.SqlDataProvider, Mediachase.SqlDataProvider" connectionStringName="EcfSqlConnection" applicationName="APPLICATION NAME" />
</providers>
</dataService>
{code}
{code:xml}
<imageService defaultProvider="HandlerImageProvider">
<providers>
<add name="HandlerImageProvider" type="Mediachase.Commerce.Engine.Images.Providers.HandlerImageProvider, Mediachase.Commerce" urlFormatString="~/images/t/{0}.image.ashx" applicationName="APPLICATION NAME" />
</providers>
</imageService>
{code}
{code:xml}
<templateService defaultProvider="XslTemplateProvider">
<providers>
<add name="XslTemplateProvider" type="Mediachase.Commerce.Engine.Template.Providers.XslTemplateProvider, Mediachase.Commerce" applicationName="APPLICATION NAME" templateSource="{SHARED FILES FOLDER}\NotificationTemplates\{0}\{1}.xsl" />
</providers>
</templateService>
{code}
{code:xml}
<membership defaultProvider="CMSMembershipProvider">
<providers>
<add connectionStringName="EcfSqlConnection" applicationName="eCommerceFramework" enablePasswordRetrieval="true" enablePasswordReset="false" requiresQuestionAndAnswer="false" requiresUniqueEmail="true" passwordFormat="Clear" passwordStrengthRegularExpression="" minRequiredPasswordLength="4" minRequiredNonalphanumericCharacters="0" name="CMSMembershipProvider" type="Mediachase.Commerce.Customers.Profile.Providers.CustomerSqlMembershipProvider, Mediachase.Commerce" />
</providers>
{code}
{code:xml}
<roleManager enabled="true" cacheRolesInCookie="true" defaultProvider="CMSRoleProvider">
<providers>
<add connectionStringName="EcfSqlConnection" applicationName="eCommerceFramework" name="CMSRoleProvider" type="Mediachase.Commerce.Customers.Profile.Providers.CustomerSqlRoleProvider, Mediachase.Commerce" />
</providers>
</roleManager>
{code}
Finally in the ..\B2CSampleSite\Web.config file, update these two lines that specify the path to the *LicenseManager*, and *NotificationTemplates* folders. You can quickly find the lines by doing a Ctrl+F search for "(SITE ROOT FOLDER)". In the original zip package, LicenseManager and NotificationTemplates folders are located in *\Mediachase\eCommerceFramework\5.1\Licensing* and *\Mediachase\eCommerceFramework\5.1\Shared* respectively.
{code:xml}
<providers>
<add name="fileProvider" type="Mediachase.Licensing.FileStorageProvider, Mediachase.Licensing" storagePath="(SITE ROOT FOLDER)\LicenseManager" />
<add name="sqlProvider" type="Mediachase.Licensing.SqlStorageProvider, Mediachase.Licensing" connectionStringName="EcfSqlConnection" tableName="" createTable="True" />
</providers>
{code}
{code:xml}
<providers>
<add name="XslTemplateProvider" type="Mediachase.Commerce.Engine.Template.Providers.XslTemplateProvider, Mediachase.Commerce" applicationName="eCommerceFramework" templateSource="(SITE ROOT FOLDER)\NotificationTemplates\{0}\{1}.xsl" />
</providers>
{code}
h3. *Step 5*: Importing the Sample Site, catalogs, and indexing your search
Now you are ready to access the ECF using your browser and Import the Sample Site and Catalogs
* Browse to [http://localhost/] or other url where your set up your ECF with (You can access the url from your IIS by right clicking on the *default.aspx* page and selecting "Browse.")
* Because currently there are no public site set up, this URL will automatically redirect you to the Commerce Manager (a.k.a. back-end site).
* At the login page, enter the default authentication (User name: admin, Password: store) and select log in.
!ManualInstallationCMD.png|thumbnail,border=1!
The Dashboard Home page of the Commerce Manager will open. The "Alerts" section indicate that Sites, Catalogs, and Search Indexes do not exist as shown below.
!ManualInstallationInitialBack-End.png|thumbnail,border=1!
Follow the instructions for each alert in the order listed from top to bottom and import the sample site, catalogs, and finally build new indexes.
For the Search Indexes alert, click on the *Rebuild* button once you enter the Search Manager page.
* Go here to see the detailed steps to import B2CSampleSite definition
* Go here to see the detailed steps to import sample catalog files
*Important:* Make sure to import the sample site before importing the catalogs. *Do not* import the catalogs when there is no existing sites.
h3. Step 6: Starting Quartz Service
Go to *C:\Program Files\Mediachase\eCommerceFramework\5.1\QuartzService*
Run the following command in the Command Prompt:
From
{code:xml}
install.bat eCommerceFramework (or any other application name of your choice)
{code}
Open the Local Services from *Start > Administrative Tool > Services*
Find *Mediachase eCommerce Framework Service (eCommerceFramework)* from the list. Right click and choose *Start*. The Status column will change from blank to "Started," confirming that the service has started.
!ManualInstallationService.png|thumbnail,border=1!
Starting the Quartz will also triggered the Catalog Search Index, that is set to automatically update ever 5 min by default.
You can change the frequency of the job or add new jobs such as recurring payments or rotating encryption. To read more about Quartz, go here.
h3. *Step 7*: Installing Your License Key (not necessary if working with localhost)
When browsing to the newly installed ECF SDK package, you will notice that the status of the License at the upper right hand corner of the Commerce Manager is displayed as "unlicensed version" in red font. The installation will fully work as long as you are using localhost. You will need to install your license key, however, in order to browse your site with with a hostheader name or to browse your site remotely or one set up on a server. To learn more about our license policy, go to our [ecf51installanddeploy:Licensing Overview] page.
To install your license click on the "unlicensed version" and you will be redirected to the Licensing page (this can also be accessed from Administration > System Settings > License Info). Enter your license file or your license key in the appropriate field and select Install. Your license info will appear at the bottom of the screen.
!Licensing.png|thumbnail,border=1!
h3. Your are done\!
Now you are ready to browse the Public B2C Sample Site.
*Sign Out from the Commerce Manager and Browse the Public B2C Sample Site*
Sign out from the Commerce Manager. The Sign Out option located in the pull-down menu of the *Welcome* button at the upper left corner of the screen.
You will be taken to the public B2C sample site (a.k.a. front-end site).
!ManualInstallationB2CDigitalCameras.png|thumbnail,border=1!
If everything works and looks good, you're done\! If problems do arise, please read our Troubleshooting section.
h3. Appendix
{anchor:IIS 2003}
*IIS Configuration on a Windows Server 2003 Workstation*
This will go step-by-step how to setup IIS 6 in Windows Server 2003 for ECF.
Click on *Start > Administrative Tools > Internet Information Services (IIS) Manager*
Highlight *Web Sites* and stop the *Default Web Site*. Then right-click on Web Sites and select *New > Web Site.*
* Enter in a description of the Web Site (e.g., eCommerce Framework - 80)
* Assign an IP or localhost and a TCP port
* Select a physical path to the Web content location (i.e. *C:\inetpub\wwwroot\B2CSampleSite* or any other IIS root location you are using)
* Check the following permissions: *Read* and *Execute*
Add 3 Virtual Directories ("_cmsbase", "_cmsctrls", "Apps") in the "eCommerceFramework - 80" web site and set their physical paths to their respective folders in the Shared folder contained in the Mediachase folder you initially moved to Program Files.
Right click on the "eCommerceFramework - 80" web site. Select the command to add a new virtual directory and enter the following information:
* Alias: \_cmsbase
* Physical path: *C:\Program Files\Mediachase\eCommerceFramework\5.1\Shared_cmsbase*
* Virtual Directory Access Permission: *Read* & *Execute*
* Repeat these steps to create the other two Virtual Directories (_cmsbase and Apps).
* Right-click on each virtual directory you created and go to *Properties*. Next to the *Application Name* field, click on *Remove* and *OK*.
Right-click on the Web Site name (i.e. eCommerce Framework - 80) and select *Properties*. Go to the *ASP.NET* tab make sure the ASP.NET version is set to *2.0.50727*.
In the end, it should look like this:
!iis6-config-ecf51.png|thumbnail,border=1!
{anchor:IIS XP}
*IIS Configuration on a Windows XP Workstation*
Open up the IIS Management Console.
Create a new virtual directory and point it to your *B2CSampleSite* folder or whatever name you used earlier for your website root folder.
* When using the Virtual Directory Creation Wizard, specify the Virtual Directory alias - we use "b2csamplesite" as the default but feel free to use whatever name you like.
* Point the Web Site Content Directory to the location on your machine where the B2CSampleSite contents are located (i.e. *C:\Inetpub\wwwroot\b2csamplesite*)
* Change the access permissions of this directory to "Read only."
Go to the properties of the new "b2csamplesite" virtual directory that was created and set the following:
* Go to the *ASP.NET* Tab and select "2.0.50727 as the ASP.NET version
* On the *Home Directory* tab, set permissions to "Read," "Log visits," and "Index this resource."
* In the *Home Directory* tab, set the Execute Permissions to "Scripts only."
* Select *Create* in the *Application Settings* portion in order to establish the application name.
* Set the *Execution Permissions* to "Scripts Only."
* In the *Documents* tab, make sure you add "Default.aspx" and move it to the top of the list.
* Make sure that the virtual directory that was created belongs to the same application pool as the website.
In IIS, set the permissions for the root home directory folder of your website to the following (the permissions to your "b2csamplesite" virtual directory should be inherited):
* Allow the following privileges for the *IIS_WPG* user group: "Read & Execute," "List Folder Contents," and "Read"
* Add the *NETWORK SERVICE* account by clicking *Add*, *Advanced* and then *Find Now*. Scroll to NETWORK SERVICE and then click *OK* to exit the window. Click OK again to go back to the *Security* tab properties. You should see NETWORK SERVICE in the list of Group or user names
* Verify that the Network Service account has "Modify "privileges.
!ManualInstallationIIS5.png|thumbnail,border=1!
{anchor:UpdateConfigTool}
h3. Automatically Update Configuration Files Using a Program Tool
We have a simple tool to recursively search through a directory to find a set of configuration files that are meant to be particular to each environment. This includes connection strings, storage path, etc.
The tool consists of four parts (Mediachase.ECF.SDK.5.1 *package\Tools\UpdateConfigFiles*):
* An executable file containing the programCopy of MSBuild Community Tasks DLL required by the executable
* A batch script to pass parameters to the executable
* XML file containing all fields that need to be configured for a target environment
*How to use*
* Right click on UserProperties.xml file and go to its Properties. Uncheck the Read-only attributes to make the file editable.
* Open the UserProperties.xml file using a text editing tool such as Notepad and overwrite the placeholder info (in black fonts in all uppercase letters below) with information to match your setup you used.
Here are the contents of the UserProperties.xml file you will initially see:
{code:xml}
<?xml version="1.0" encoding="utf-8" ?>
<UserProperties>
<DataSource>DATABASE_SERVER</DataSource>
<DBMain>MAIN_DB</DBMain>
<SqlUserId>USER_ID</SqlUserId>
<SqlUserPassword>USER_PASSWORD</SqlUserPassword>
<\!-\- Default application name \-->
<ApplicationName>eCommerceFramework</ApplicationName>
<AppNameConnectionString>eCommerceFramework</AppNameConnectionString>
<StorageBasePath>STORAGE_BASE</StorageBasePath>
<\!-\- Usually the same as storage base path above \-->
<PublicStorageBasePath>PUBLIC_STORAGE_BASE</PublicStorageBasePath>
<SearchIndexPath>SEARCH_INDEX_PATH</SearchIndexPath>
<\!-\- Network share form of search index path above \-->
<SearchIndexPathUnc>SEARCH_INDEX_NETWORK_PATH</SearchIndexPathUnc>
<TemplatePath>TEMPLATE_PATH</TemplatePath>
<\!-\- Usually set to {Directory containing ConsoleManager}\ConsoleManager\bin \-->
<LicenseStoragePath>LICENSE_STORAGE_PATH</LicenseStoragePath>
<TempStoragePath>TEMP_STORAGE_PATH</TempStoragePath>
</UserProperties>
{code}
Run the following command in the Command Prompt:
{code}
updateConfig.bat [directory containing the config files] (e.g., "C:\Program Files\ECF")
{code}
*Note:* For the optional line *<SearchIndexPathUnc>*, please use the form \*(SERVER NAME)(SHARED FOLDER PATH)\*
h3. Steps to Import B2C Sample Site Definition
Click on the link *here* to import a sample site. When the *Import Site* page opens, you should see one XML file available for import.
Click on the SiteExport-B2C.xml file to highlight it, then select the *Start Import* button. A progress window will open and the import should be complete in a few seconds.
Once the progress bar indicates that the import has been completed, click *close*.
*Note:* If the SiteExport-B2C.xml files does not appear in the *Import Site* page, you can find the XML file in the *\Mediachase.ECF.SDK.5.1\Tools\DataFiles* folder. Select the *Add New File button > Browse > Upload > Save the File* to add it to the *Available for Import* list.
!ManualInstallationSiteImport1.png|thumbnail,border=1!
h3. Steps to Import B2C Sample Catalog Files
*IMPORTANT NOTES:* We package the sample catalog data to use the native import functionality in ECF G5. The Brands Catalog and the Everything Store Catalog files will take a few Minutes to import so please leave the process running until it is complete-\- grab a cup of coffee while it is running. Do not import the sample catalogs if you have not imported the B2C site definition in the previous step above. It is important that the Site definition is performed before the catalog data imports.
At the Dashboard home page (as shown two images above), click on the link *here* to import sample catalogs. When the Import Catalog page opens, you should see two XML files (CatalogExport-B2C-Brands.zip & CatalogExport-B2C-Everything.zip) available for import.
Click on one of the two zip files to highlight it, then select the *Start Import* button. A progress window will open and the import should be complete after a few seconds.
Once the progress bar indicates that the import has been completed, select *close*.
Highlight the other zip file, and repeat the import process.
*Note:* If the CatalogExport-B2C-Brands.zip & CatalogExport-B2C-Everything.zip files do not appear in the Import Site page, you can find the XML file in the *\Mediachase.ECF.SDK.5.1\Tools\DataFiles* folder. Select the *Add New File button > Browse > Upload > Save the File* to add it to the *Available for Import* list.
Note: Please make sure you import *both* files.
!ManualInstallationCatalogImport.png|thumbnail,border=1!
{anchor:End ScreenSteps Content}