I just made a backup of a live NAV 2013 R2 database to do an upgrade to NAV 2015. Since the system is live we have several servers running when the backup is created.
The backup was restored in a new environment and the database opened with a NAV 2015 Developement Client. The database is put in single user mode and converted. After the conversion a process to upgrade objects starts. Here is where things start to behave in an unwanted way.
The database is in a Single User Mode since it is still in the upgrade transaction and no NAV Server instance is connected. However, in the table “Server Instance” all the old NAV Server instances are listed. To get through this I needed to press N like a thousand times…
In a test upgrade process like this we need to add another step to the usual upgrade procedure. After the restore is completed make sure that the tables “Server Instance” and “Active Session” are empty.
After a restore to a new environment it is also good to clean unneeded users from the database. Only leave what is actually needed.
In this case the NAVLIGHT\srvNAV is the service user. Also make sure that the Compatibility Level is as new as possible and the Recovery Model in line with the backup process.
Also, when moving from one environment to another the users connected to the old domain are obsolete. Going to Users and trying to remove them results in an error and the user is only disabled.
In some cases this could be enough. It is possible to completely remove the user, just do some housekeeping first. Find the user in “User Personalization” and Edit the record. On the Action ribbon we can clean some of the user trails.
Finally make sure that the record is deleted from “User Personalization”.
After this cleanup work the user can be safely deleted.