Setting up SmarterMail 8 as a site in IIS7 as apposed to a Service command line

Setting up SmarterMail 8 as a site in IIS7 as apposed to a Service is rather straight forward.  SmarterTools has this article here:

http://portal.smartertools.com/KB/a1485/set-up-smartermail-as-a-site-in-iis-70.aspx

I decided to go once step further and make this scripted:

 

32bit:

net stop SMWebSvr
sc config SMWebSvr start= disabled
%SYSTEMROOT%\System32\inetsrv\appcmd add apppool /name:"SmarterMail" /managedRuntimeVersion:v4.0 /managedPipelineMode:Integrated
%SYSTEMROOT%\System32\inetsrv\appcmd set config /section:isapiCgiRestriction /[path='C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll'].allowed:True
%SYSTEMROOT%\System32\inetsrv\appcmd add site /name:"SmarterMail" /bindings:http/*:9998: /physicalPath:"C:\Program Files \SmarterTools\SmarterMail\MRS"
%SYSTEMROOT%\System32\inetsrv\appcmd set app "SmarterMail/" /applicationPool:"SmarterMail"
%SYSTEMROOT%\System32\inetsrv\appcmd set config "SmarterMail/App_Themes" /section:staticContent /clientCache.cacheControlMode:UseMaxAge /clientCache.cacheControlMaxAge:7.00:00:00
%SYSTEMROOT%\System32\inetsrv\appcmd set config /section:applicationPools /[name='SmarterMail'].processModel.identityType:NetworkService

And 64bit:

net stop SMWebSvr
sc config SMWebSvr start= disabled
%SYSTEMROOT%\System32\inetsrv\appcmd add apppool /name:"SmarterMail" /managedRuntimeVersion:v4.0 /managedPipelineMode:Integrated
%SYSTEMROOT%\System32\inetsrv\appcmd set config /section:isapiCgiRestriction /[path='C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll'].allowed:True
%SYSTEMROOT%\System32\inetsrv\appcmd add site /name:"SmarterMail" /bindings:http/*:9998: /physicalPath:"C:\Program Files (x86)\SmarterTools\SmarterMail\MRS"
%SYSTEMROOT%\System32\inetsrv\appcmd set app "SmarterMail/" /applicationPool:"SmarterMail"
%SYSTEMROOT%\System32\inetsrv\appcmd set config "SmarterMail/App_Themes" /section:staticContent /clientCache.cacheControlMode:UseMaxAge /clientCache.cacheControlMaxAge:7.00:00:00
%SYSTEMROOT%\System32\inetsrv\appcmd set config /section:applicationPools /[name='SmarterMail'].processModel.identityType:NetworkService

On a side note, in certain cases, I had to change the application pool back to Classic Mode.  IDK why, if you figure it out, pls tell me!

Ok, as of last I think I fount the inconsistency.  The application pool is not getting updated to run as NetworkService, alternative command to give us desired result:

%SYSTEMROOT%\System32\inetsrv\appcmd.exe set AppPool SmarterMail -processModel.identityType:NetworkService

 


Posted

in

by

Tags:

Comments

2 responses to “Setting up SmarterMail 8 as a site in IIS7 as apposed to a Service command line”

  1. tweakservers Avatar

    Nice One! This helps setting up SmarterMail scriptted without the needs to manually go through all the manual work.

    If you are looking for SmarterMail license – new or upgrade protection, visit us at http://www.tweakservers.com as we are the authorised SmarterTools reseller by helping you to save 10% off RRP + you receive Free SSL + Uptime monitoring services from us.

  2. Kate Blodgett Avatar

    Rose saves the day! Thank you for posting, you are always a huge help.

Leave a Reply

Your email address will not be published. Required fields are marked *