Home
>
Blogs
>
Gurupurna
>
How to do Skip Directives using default provider in Web Farm Framework 2.0 (WFF 2.0) by changing the applicationHost Config?
How to do Skip Directives using default provider in Web Farm Framework 2.0 (WFF 2.0) by changing the applicationHost Config?
Posted:
Jan 25, 2011
3 comments
Average Rating
- Tags
- ACLs
- Skip Directives
One of the feedback that customers provided was to enable them to exclude a specific set of directories from provisioning. WFF 2.0 enables this feature and lets customer control the provisioning of the directories using its default sync provider. Default behavior is to provision all the files and directories from the primary server to the secondary servers. Also note that the ACLs for the files and directories will be intact after the sync. Let’s assume that you have Folder1 and Folder2 under Default Web Site and you want to sync only Folder2 and exclude Folder1. In order to exclude the directories follow the steps below.
1. On the controller machine open the applicationHost.config file. This is under the directory %windir%\System32\inetsrv\config
2. Under applicationProvision element you need to add an entry to skip the directives as follows.
<webFarms>
<webFarm serverAutoStart="false" name="Farm" enabled="true" adminUserName="{0}\administrator" adminPassword=”pwd” primaryServer="demo-primary">
<server address="demo-primary" enabled="true" />
<server address="demo-secondary" enabled="true" />
<platformProvision syncPlatformFromPrimary="true" />
<applicationProvision syncWebServerFromPrimary="true">
<skipDirectives>
<skip name="folder1" skipDirective="objectName=dirPath,absolutePath=.*folder1.*" />
</skipDirectives>
</applicationProvision>
</webFarm>
</webFarms>
3. When we save the changes WFF immediately picks up the changes from the configuration file and do application provision.4. Verify that secondary servers provisioned only with Folder2 and Folder1 was excluded.5. You can also Skip binding as follows<skip name="folder1" skipDirective="attributes.protocol=https" />6. One another way you can do the syncing of a particular directory using msdeploy command directly as follows for each secondary server.C:\>cmd.exe /c ""%ProgramFiles%\IIS\Microsoft Web Deploy\msdeploy.exe" -verb:sync -source:contentPath="Default Web Site",computerName=demo-primary -dest:contentPath="Default Web Site" -skip:objectName=dirPath,absolutePath=.*folder1.*"
Submit a Comment
- Plain text is accepted.
- URLs starting with http:// are converted to links.