Deploy a Model Deployment Package by Using MDSModelDeploy
Applies To: SQL Server 2016 Preview
In Master Data Services, use the MDSModelDeploy tool to deploy a package that contains either:
Model objects only.
Model objects and data.
If you want to deploy a package that contains model objects only, you can use the model deployment wizard in the Master Data Services web application instead. For more information, see Deploy a Model Deployment Package by Using the Wizard.
Packages can be deployed to the edition of SQL Server they were created in only. This means that packages created in SQL Server 2012 cannot be deployed to SQL Server 2014 or higher.
To perform this procedure:
You must have permission to access the System Administration functional area in the target Master Data Services environment.
A model deployment package must exist. For more information, see Create a Model Deployment Package by Using MDSModelDeploy.
You must be an administrator in the environment where you are deploying the model. For more information, see Administrators (Master Data Services).
If you are updating a model with data, the version you’re deploying to cannot be Locked or Committed.
To deploy a model deployment package
Determine whether you are deploying a new model, a clone of a model, or updating a previously-cloned model. For more information, see Model Deployment Options (Master Data Services).
Open a command prompt and navigate to MDSModelDeploy.exe.
If MDS is installed at the default location, the tool is available at drive:\Program Files\Microsoft SQL Server\130\Master Data Services\Configuration
If MDS is not installed at the default location, search the local computer for MDSModelDeploy.exe.
Optional. View options and help.
To display all available options, type MDSModelDeploy and press Enter.
To display help for an option, type the following, where OptionName is the name of the option: MDSModelDeploy help OptionName.
Optional. If you have multiple web applications, determine the name of the service you will deploy to by typing this command and pressing Enter:
A list of values is returned, for example MDS1, Default Web Site, MDS. The first value in this list (in this case, MDS1) is needed to deploy the model.
Depending on whether you are creating a model, cloning a model, or updating a model, at the command prompt, type the following and press Enter.
To create a new model:
MDSModelDeploy deploynew –package PackageName -model ModelName -service ServiceName
To create a clone of a model:
MDSModelDeploy deployclone –package PackageName
To update an existing model and its data:
MDSModelDeploy deployupdate –package PackageName –version VersionName
If you use the MDSModelDeploy tool to update an existing model and its data, and the package does not contain an entity, attribute, or member that exists in the destination model, MDSModelDeploy will not delete that entity, attribute, or member from the model.
Where PackageName is the name of the package (.pkg) file, ModelName is the name of the new model, VersionName is the name of the version, and ServiceName is the name of the service that you returned in the previous step. Ensure that the model and version names match the exact case-sensitive names.
When the package is successfully deployed, a message stating “MDSModelDeploy operation completed successfully” is displayed.
If a subscription view in the package has the same name as a subscription view in an existing model, this warning is displayed: Deployer subscription view renamed and the view is created as modelname.subscriptionviewname. If this name is already in use, the subscription view is not created.
The deployment process has four steps:
The model objects are created.
Business rules are created.
Subscription views are created.
Master data is populated.
When creating a new or cloned model, if the process fails during any step, the model is deleted.
When updating a model, if the process fails during the first three steps, it does not proceed; however, changes that are already made are not rolled back. If the process fails in step 4, members that can be updated are updated.
File attributes, and user and group permissions are not included in model deployment packages. After you deploy a model, you must update these manually. For more information, see: