Additional NAV Instances in azure sql

manikandan
Member Posts: 160
Hi All,
When i am trying to import Key using below comments i am getting following error message .Please help me
Export-NAVEncryptionKey -ServerInstance LSVDB2017 -KeyPath 'C:\ProgramData\Microsoft\Microsoft Dynamics NAV\100\Server\Keys\LSVDB2017.key' -Password (Get-Credential).Password | Import-NAVEncryptionKey -ServerInstance NewInstance2017
Note:
The Aim is need to create multiple instance and need to connect with out any issue
Already having one instances with out having any issue .The issue comes when i am trying to create new instances
Regards,
Muthu
When i am trying to import Key using below comments i am getting following error message .Please help me
Export-NAVEncryptionKey -ServerInstance LSVDB2017 -KeyPath 'C:\ProgramData\Microsoft\Microsoft Dynamics NAV\100\Server\Keys\LSVDB2017.key' -Password (Get-Credential).Password | Import-NAVEncryptionKey -ServerInstance NewInstance2017

Note:
The Aim is need to create multiple instance and need to connect with out any issue
Already having one instances with out having any issue .The issue comes when i am trying to create new instances
Regards,
Muthu
0
Answers
-
Use the below command in Windows Powershell ISE
Execute the script line by line so that you can check where you go wrong.
Remove the comment provided.
The below script will help to restart a new service in AZURE ENVIRONMENT.
$Credentials = (New-Object PSCredential -ArgumentList 'sqluser',(ConvertTo-SecureString -AsPlainText -Force 'sqlpassword')) //sql user name in 'sqluser'& ans passwod in sqlpassword to login in nav db
$License = "D:\File\5278.flf" //license file path
Import-module "C:\Program Files\Microsoft Dynamics NAV\100\Service\NavAdminTool.ps1"
Install-WindowsFeature -Name NET-HTTP-Activation
New-NAVEncryptionKey -KeyPath "C:\NavTemp\DynamicsNAV2.key" -Password (ConvertTo-SecureString -AsPlainText -Force 'sqlpassword') //a keyfile must be created in a location and sql login password needs to be provided in place of sqlpassword
Import-NAVEncryptionKey -ServerInstance INSTANCENAME -ApplicationDatabaseServer AZURESERVERNAME -ApplicationDatabaseCredentials $Credentials -ApplicationDatabaseName 'AZUREDATABASENAME' -KeyPath "C:\NavTemp\DynamicsNAV2.key" -Password (ConvertTo-SecureString -AsPlainText -Force 'sqlpassword') -Force -Verbose //INSTANCENAME should be azure service instance name , AZURESERVERNAME sould be azure db server link, password SQL login password
Set-NAVServerConfiguration INSTANCENAME -KeyName DatabaseServer -KeyValue AZURESERVERNAME -Force //INSTANCENAME & AZURE SERVER LINK
Set-NAVServerConfiguration INSTANCENAME -KeyName DatabaseName -KeyValue 'AZUREDATABASENAME' //INSTANCENAME & AZURE DATABASE NAME
Set-NAVServerConfiguration INSTANCENAME -KeyName EnableSqlConnectionEncryption -KeyValue true //INSTANCE NAME
Set-NAVServerInstance INSTANCENAME -Restart //INSTANCE NAME1 -
Maybe the path doesn’t exist. Try using something like c:\temp\mykey.key instead (assuming you have a c:\temp folder).0
-
Hi ,
When i am trying to execute below line i am getting error message
Import-NAVEncryptionKey -ServerInstance DynamicsNAV100 -ApplicationDatabaseServer TESTSERVER -ApplicationDatabaseCredentials $Credentials -ApplicationDatabaseName 'TESTdatabase' -KeyPath "C:\ProgramData\Microsoft\Microsoft Dynamics NAV\100\Server\Keys\DynamicsNAV100.key" -Password (ConvertTo-SecureString -AsPlainText -Force 'password@123') -Force -Verbose
Import-NAVEncryptionKey : Cannot establish a connection to the SQL Server/Database.
This could be due to one of the following reasons:
* SQL Server is not started.
* The database does not exist.
* Proper permissions have not been given to the NAV Server Account.
Try again later or contact your system administrator.
At line:1 char:1
+ Import-NAVEncryptionKey -ServerInstance DynamicsNAV100 -ApplicationDatabaseServe ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (0:Int32) [Import-NAVEncryptionKey], NavCSideException
+ FullyQualifiedErrorId : MicrosoftDynamicsNavServer$DynamicsNAV100,Microsoft.Dynamics.Nav.Management.Cmdlets.ImportNavEncryptionKey
But i can able to open RTC with existing service
Kindly help
0 -
In the following path
Path : C:\ProgramData\Microsoft\Microsoft Dynamics NAV\110\Server\Keys\abc.key
The service name key would be present. If you receive the above error. Delete the key present in the above path. The try running the script.
A temporary folder needs to be created to store the key according to the script.
Note : (You can delete the key from the path and in server administration click on the instance -- go to configuration file and enter nav database USERID and password. and restart the service. The service will be restarted.)0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions