Hello all
I decided to write a small blog post if someone else is upgrading their NAV 2016 from CU 03 to CU07
After updating the client and service files I started the Development client, converted the database to new version, and tried to start the NAV service with Administration tool.
The service did not start, and event viewer was populated with this error:
Server instance: NAV2016
The service MicrosoftDynamicsNavServer$NAV2016 failed to start. This could be caused by a configuration error. Detailed error information: System.MissingMethodException: Method not found: 'Microsoft.Dynamics.Nav.Types.TenantPollLimits Microsoft.Dynamics.Nav.Types.ServerUserSettings.get_TenantDetectionMaxRetryCount()'.
at Microsoft.Dynamics.Nav.Runtime.NavTenantCollection..ctor(Action`1 onApplicationMounted, NavAppGroupUpdater groupUpdater)
at Microsoft.Dynamics.Nav.Runtime.NavEnvironment..ctor(Boolean standaloneInstance)
at Microsoft.Dynamics.Nav.Runtime.NavEnvironment.get_Instance()
at Microsoft.Dynamics.Nav.WindowsServices.NavServerWindowsService.SetNavEnviroment(String commandLineServiceInstanceName, ServerUserSettings settings)
at Microsoft.Dynamics.Nav.WindowsServices.NavServerWindowsService.Start(String commandLineServiceInstanceName).
I pondered this for an hour, fiddling with the CustomSettings.config files a lot. I came to conclusion that this is something I cannot find an answer to, so I contacted Microsoft Support. We found quickly out that the problem was caused by old version of NavSip.dll file in folder C:\Windows\SysWOW64
Updating the dll from install dvd folder NAV.9.0.45834.FI.DVD\ServiceTier\System64Folder fixed the problem, and I was able to start the services. Thank you Abdelrahman for quick and professional help!
After successful service start, next step is to synchronize schemas. This did not work, I got an error dictating that there is something wrong with some fields.
The following SQL error was unexpected: Invalid column name 'Session Unique ID'.
Statement(s) could not be prepared.
I spent some time studying the tables and found out that development environment had added a new field "Session Unique ID" to two tables, Active Session and Session Event.
I fixed this by adding the columns via Management studio, with type uniqueidentifier. This fixed the problem, and I could synchronize the schema and compile all objects successfully.
I learned later that this can be fixed an easier way as well; simply running the Development environment as an administrator when converting the database to new client version.
So far the last problem is that running an object from Development environment causes the RTC client to crash. This is also fixed by running the Development Environment as an admin.
Hopefully this is all.. happy updating everyone!
EDIT 2016-05-13. If you update CU7 to development server, you have to update same client version to all customer deployments as well.
Changes in Session Event and Active Session tables cause older client versions to crash in login with error:
The Following SQL error was unexpected: Cannot insert the value NULL into column 'Session Unique ID', table 'NAV2016.Session Event'; column does not allow nulls. INSERT fails.
The statement has been terminated.
This happens if you or someone else updates either of these tables to production.
UrpoK
Comments
I have a server where the licenses are installed on the database. The master license is just the Microsoft one installed from the product CD. When I try to do the master upgrade with that one I get this error:
--
You do not have permission to read the 'Tenant Permission' Table.
Contact your system administrator to have your permissions changed.
--
Btw: I've reported the bug regarding the crash if you try to run objects and have not started the development environment as administrator. The Microsoft ID is "[REG:116051214158431] NAV crashes when running objects". It seems to be related to the development client searching for a running windows client in the process list too aggressively causing an access denied exception (according to the visual studio debugger). The code for this was changed in CU7 to eliminate COM code.
1. have a developer license loaded
2. compile all system tables (with option "later") after upgrade run
3. close the dev. environment, start with admin privileges
4. restart the NST just in case
5. do the synchronization.
with best regards
Jens
Robert's Dynamics NAV Blog - Vom NAV Entwickler für NAV (Navision) Interessierte
Anyway thanks @urpok for pointing in which tables error was.
https://community.dynamics.com/nav/f/34/t/204627
We have a client on CU7 who we are upgrading to CU12 precisely because of those metadata errors. (I know that that is not the latest update, but the client uses a vertical that is currently only available for CU12 or earlier).