This topic describes how add a new Microsoft Dynamics NAV database instance to SQL Server from a database backup file (.bak). To add a Microsoft Dynamics NAV database, you use the New-NAVDatabase cmdlet of the Microsoft Dynamics NAV Administration Shell.
To add a Microsoft Dynamics NAV database
Establish a Remote Desktop Connection to the virtual machine that is running the SQL Server.
Run Microsoft Dynamics NAV Administration Shell as an Administrator.
On the remote computer, on the Start menu, search for Microsoft Dynamics NAV Administration Shell. Right-click the link, and then choose Run as Administrator.
At the command prompt, type the following command:
Copy Code New-NAVDatabase -FilePath <DatabaseBAKfile> -DatabaseName <MyNavDatabase> -DatabaseInstance <DatabaseInstance> DatabaseServer <DatabaseServer> ServiceAccount <ServiceAccount>
Change the following parameter values.
Parameter Description <DatabaseBAKfile>
Specifies the path and file name of the Microsoft Dynamics NAV database backup file that you want to restore.
<MyNavDatabase>
Specifies the name to give the new database in SQL Server.
<DatabaseInstance>
Specifies the name of the SQL Server database instance to connect to.
If you there is only one database instance on the SQL server, then you can omit this parameter. The default instance is DynamicsNAV70_Instance1.
<DatabaseServer>
Specifies the name of the computer that is running SQL Server. The name has the domain\computername format.
If this is the computer that you are working from, then you can omit this parameter.
<ServiceAccount
Specifies the logon account that runs the Microsoft Dynamics NAV Server instance.
This account is given the appropriate permissions to the database when you run the cmdlet. For more information, see Provisioning the Microsoft Dynamics NAV Server Account. If you do not specify an account, then Network Service is used.
Note The command that is shown includes only a subset of all the parameters of the New-NavDatabase cmdlet. For more information about the syntax and parameters, see New-NAVServerInstance. Press Enter to run the cmdlet.
A new Microsoft Dynamics NAV database that has the specified name is added on SQL Server.
Example
The following example restores a database and preserves the original file names, locations, and logon accounts.
Copy Code | |
---|---|
New-NavDatabase -FilePath C:\Backups\NavDemoDatabase.bak -DatabaseName MyNewDatabase -verbose |
See Also
Tasks
How to: Add a Microsoft Dynamics NAV Server InstanceHow to: Add a Microsoft Dynamics NAV Web Server Instance
How to: Add a Microsoft Dynamics NAV Company
How to: Change the Size of a Windows Azure Virtual Machine
Concepts
Network Topologies for Microsoft Dynamics NAV on AzureDeploying and Managing Microsoft Dynamics NAV 2013 on Windows Azure
Deploying Microsoft Dynamics NAV Using the Example Scripts
Scaling the Microsoft Dynamics NAV Network Topology on Windows Azure