InstallationScalable Installation Options

Scalable Installation Options

Multiple NAS'es

 
Every NAS requires its own MS Dynamics NAV license! So when you use multiple NAS, you should also have multiple MS Dynamics NAV licenses.
In the previous chapter you have been able to see the use of multiple servers, which improves the performance of Sana Commerce. Another way to achieve this, is the use of multiple NAS. If required, multiple NAS can also be combined with multiple servers.
 
 
The performance bottleneck of Sana Commerce is in the NAS. This application service of MS Dynamics NAV, which is delivered with MS Dynamics NAV, only supports one request at a time. This means that when the requests in MS Dynamics NAV are taking some time, concurrent requests will have to wait until the previous request is finished. This results in a queue on the NAS.
To optimize this situation, multiple NAS can be setup, so that multiple requests can be handled simultaneously. Sana Commerce supports up to three NAS and the selection of which NAS will be used, is based on the Sana Commerce subsystems.
For the following subsystems different NAS can be configured:  
  • Catalog subsystem;
  • Customer subsystem;
  • Order/Shop subsystems. 
Every combination is possible. For example: using two NAS; one for the catalog and customer subsystem and another one for the order/shop subsystem. The order and the shop subsystems always use the same NAS. 
 
Install Multiple NAS 
The installation wizard of the Navision Application Server can only install one NAS per server. When more than one NAS are required on one server, they have to be installed manually (except for the first one). 
 
Perform the following steps to install a NAS manually (SQL option): 
  • Copy all files that belong to the previously installed NAS to another target folder. By default, the first NAS is installed in C:\Program Files\Microsoft Dynamics NAV\Application Server. We recommend you to place the additional NAS in the same root directory, something like: C:\Program Files\Microsoft Dynamics NAV\Application Server X;
  • Open a command prompt (Start > Run > 'cmd');
  • Navigate to the NAS directory (using the cd command);
  • Run the following command (replace the parameter values with your settings):
    nassql installasservice, appservername="server name-SQL", servername="sqlServerName", nettype=tcp, database="database name", company="company name"
    
  • Make sure a MS Dynamics NAV license file is located in the NAS directory.
To install a NAS for an administration in a native storage, please check the MS Dynamics NAV installation manual.  
 
Configure the NAS 
When the NAS are in place, they should be configured to start the WCF on the right port number.
  • Open the NAV client, connect to the right administration, open the 'Webshop' menu and select 'Setup';
  • Open the 'Multiple NAS Setup' tab;

     
    The 'Multiple NAS Setup' Tab in the 'Sana Commerce Setup' Window 

  • In this case, there are two NAS. The first one will be used to handle catalog and customer subsystem requests and is configured in the SCCATALOG section. The second one is used by the order and shop subsystems and is configured in the SCORDER section;
  • Specify different port numbers for all NAS to avoid conflicts;
  • When you have finished specifying the port numbers, click OK to save your changes;
  • Open the Application Server Manager tool under 'Start > Programs > Microsoft Dynamics NAV';
  • When not all NAS are listed, add the missing ones by right clicking the Application Server for Microsoft Dynamics NAV Manager-node, then select 'New > Application Server';
  • Select the first NAS node, click the 'Stop Service' button, change the 'Start-Up Parameter' to SCCATALOG and click the 'Apply these settings' button;
  • Select the second NAS node, click the 'Stop Service' button, change the 'Start-Up Parameter' to SCORDER and click the 'Apply these settings' button;

     
    Configuring the NAS Service 

  • Now the NAS are properly configured and they are running on different port numbers.
Setup Access Rights for the Services 
 
To be able to complete this step in Windows XP, you need the Windows XP Service Pack 2 Support Tools. Make sure you have installed the optional tools, which can be downloaded here: http://www.microsoft.com/downloads/details.aspx?amp;displaylang=en&familyid=49ae8576-9bb9-4126-9761-ba8011fabf38&displaylang=en.
 
  • Open a command prompt and navigate to C:\Program Files\Support Tools;
  • Run the following command to set access rights for the WCF service as follows (this command is case sensitive!):
    httpcfg set urlacl /u "PROTOCOL://URL:PORTNUMBER/nav/" /a "O:AUG:AUD:(A;;GA;;;AU)"  
    
    #PROTOCOL#: Protocol type (HTTP or HTTPS)
    #URL#: Change to:
    + : when the port registrations in the HTTP Server routing table are placed in the "Strong Wildcard" bucket;
    [hostname] : when the port registrations are placed in the "Explicit" bucket;
    [IP-address] : when the port registrations are placed in the "IP-bound Weak Wildcard" bucket;
    * : when the port registrations are placed in the "Weak Wildcard" bucket;
    #PORTNUMBER#: must be replaced by the port number on which the NAS is running.
For more information about routing incoming requests, please check http://msdn.microsoft.com/en-us/library/aa364687(VS.85).aspx.
 
To see the detailed description of the 'Httpcfg' command syntax please check http://technet.microsoft.com/en-us/library/cc781601%28WS.10%29.aspx. 
 
For more information about this, please check http://msdn.microsoft.com/en-us/library/ms733768.aspx. You can also check this link when you are installing a NAS on Windows server 2008 or Windows Vista.   
 
Repeat these steps for all NAS. 
 
Configure the Web Applications  
  • Open the web.config of the Sana Commerce frontend web application in any text editor;
  • Locate the connectionStrings configuration section and make sure a node for every NAS is available. In the example mentioned earlier, the following configuration is applicable:
<connectionStrings>
    <remove name="LocalSqlServer"/>
    <add name="LocalSqlServer" connectionString="Data Source=server\SQL2005;Initial Catalog=database;User  Id=user;Password=pwd;" providerName="System.Data.SqlClient"/>
    <add name="CatalogCustomerNas" connectionString="http://127.0.0.1:6002/nav"/>
    <add name="OrderShopNas" connectionString="http://127.0.0.1:6001/nav"/>
</connectionStrings>
  • Select an appropriate name for these configuration nodes;
  • Then locate the sanaCommerceLive/modules section. All Sana Commerce subsystems are listed here;
  • Specify the name of the connection string in the Catalog and Customer subsystem, this name already has been specified in the connectionStrings section in the serviceConnection attribute of the provider node. In the example mentioned earlier, the name is 'CatalogCustomerNas';
  • Specify the name of the connection string in the Order and Shop subsystems, also this name already has been specified in the connectionStrings section in the serviceConnection attribute of the provider node. In the example, it is 'OrderShopNas';
  • Also a serviceConnection must be specified for the common subsystem. You can select either one of the NAS'es, It does not have any influence on the performance;
  • Open the 'web.config' of the Sana Commerce backoffice web application in any text editor;
  • Since the backoffice only uses the catalog and content subsystems (content subsystem is not relevant at the moment), only one NAS has to be configured here; the Catalog and Customer NAS;
  • Change or add a configuration node for this NAS in the same way as you have done in the frontend web.config. For consistency, you should give it the same name as used earlier, here this is 'CatalogCustomerNas';
  • Locate the 'sanaCommerceLive/modules/catalog' configuration section and update the 'serviceConnection' attribute to the name of the connection string specified in the connectionStrings section. In the example this is 'CatalogCustomerNas'. 
InstallationScalable Installation Options