BC On-Premises Cumulative Update install process and update Symbol versions

This is just a short work instruction blog about how to update CU on an BC On-premises installation including Symbol versions update.

Update Business Central client

First of all, you have to install new version of the Platform. Standard procedure is to uninstall previous version and reinstall it again from the new CU package. You can also use various update scripts that copy the files from the installation folders to c:\Program Files(x86) -folder. Especially you need to have Development environment installed, since the new and updated Test and System app files are located in that folder.

Update Business Central Objects

Open Development Environment as an administrator and import the CU objects from the uncompressed CU APPLICATION folder. If you have modified some of the objects, you have to do a merge. Othervise replace all objects that have been updated in the package.

Update symbols

Next you have to run PowerShell as an admin and run some commands. First Import-Module navadmintool.ps1 to have all the commands, and then run Get-NAVAppInfo.

Import-Module 'C:\Program Files\Microsoft Dynamics 365 Business Central\140\Service\navadmintool.ps1'

Get-NAVAppinfo BC140 -SymbolsOnly

This command returns you the current symbol versions:

Note the versions of the symbols. Next step is to remove the old System and Test applications from the database.

Unpublish-NAVApp -ServerInstance BC140 -Name System -Version 14.0.37587.0
Unpublish-NAVApp -ServerInstance BC140 -Name Test -Version 14.7.37609.0

You can add -Verbose switch to see some output, but it isnt really helpful, and you have to check that the old symbols have been removed by running the Get-NAVAppinfo again. As you can see below, there is only BC Base Application available now.

Next step is to publish new Test and System applications from the Development Environment folder. Again, the output is minimal, and you can use -Verbose to have a bit more information.

Publish-NAVApp BC140 -Path "C:\Program Files (x86)\Microsoft Dynamics 365 Business Central\140\AL Development Environment\Test.app" -PackageType SymbolsOnly
Publish-NAVApp BC140 -Path "C:\Program Files (x86)\Microsoft Dynamics 365 Business Central\140\AL Development Environment\System.app" -PackageType SymbolsOnly

Verify that the new versions of the System and Test applications has been installed with Get-NAVAppInfo. Notice that the versions below are now updated with CU16 versions. Test and System application version numbering is not in sync, do not worry about that.

Next step is a bit tricky, here you recreate the symbol files for the Base Application. This is excuted most easily with Administrator Command prompt. If you do not need some objects, you can filter objects out with "Filter" parameter. The command below has demonstrative parameter for filtering out Test suite in the base application.

cd C:\Program Files (x86)\Microsoft Dynamics 365 Business Central\140\RoleTailored Client
finsql.exe Command=generatesymbolreference, Database="Demo Database NAV (14-0)", ServerName=localhost, navservername=localhost, navserverinstance=BC140, navservermanagementport=7145, filter="Object ID=1..129999|140000..1999999999"

Finsql.exe does not give any output for this command, but running it can take up to 15 minutes depending your computer horsepowers. You can check the Windows Task manager to see if there is a process for finsql.exe, and when it disappears, then you know that the symbols have been created.

You can also check the current folder for navcommandresult.txt or naverrorlog.txt files. If either of these appears, then finsql.exe has finished its job. The text file contains information about the possible error or execution of the task.

Set the Application version

Set-NAVApplication -ServerInstance BC140 -ApplicationVersion "14.17.44663.0" -Force -Verbose

Restart the NAV service to load new Application symbols and check the symbols versions with Get-NAVappInfo.

NOTE!!! For some reason this did not work with CU16. I will get back to this, but the Application version should have been changed to the one that was set.

Comment List
Anonymous
  • This is nice and brief summary!

    For symbols generation, one doesn't need to call finsql explicitly. There is a Compile-NavAppplicationObject command and when used with -Recompile and GenerateSymbolsReference it will do the same. You can specify filters as well, and you can choose the synchronization method. Also the error list is printed to console at the end of the process.

    I personally somehow prefer this one over calling finsql.

  • This is a nice and brief summary!

Related
Recommended