Unable to edit Groups in NPC because it says "Synchronizing Global Databases" and this never completes.

Document ID : KB000032501
Last Modified Date : 14/02/2018
Show Technical Document Details

Issue:

When trying to edit Groups in NPC, it does not allow you because the Global Synchronization process never seems to complete.

If you check the Data Sources page you will see the message below:

"Synchronizing global database"

 

Cause

If you look at the Data Source log in NPC, you will see the Global Synchronization process starting over and over, but never completing as it should.

SNAG_Program-0378.png

If you review the DeviceManagerService*.log and look for where Global Synchronization starts, see if there is a point where it seems to hang or timeout like below:

0:01:08 5 - Data Source Poller: Start domain Synchronization
0:01:08 5 - Data Source Poller: Updated 1 domains
0:01:08 5 - Data Source Poller: End domain Synchronization
0:01:09 5 - Data Source Poller: Start device Synchronization
0:23:30 5 - Data Source Poller: Processing 35601 device items
0:53:33 1 - Data Source Poller - :

Connection must be opened.

UPDATE data_sources2 SET State=4 WHERE SourceID=0

NetQoS.Core.Database.DBException: Connection must be opened.

In this case you can see that after about 30 minutes the device Synchronization step of the Global Sync process appears to time out.

 

Resolution:

In order to resolve this issue, you must increase the timeout for the Global Synchronization process.

To do so follow the steps below.

1. Increase the timeout in the netqosportal database using the commands below. 
Specify the timeout you want in miliseconds. For example: 360000=60 minutes 

mysql -P3308 netqosportal

insert into general values ('DeviceManager.Timeout', 3600000);

2. Backup a copy of your DeviceManagerService.exe.config file from the "D:\NetQoS\portal\bin" directory.
For example rename the original copy, Orig_DeviceManagerService.exe.config

 

3. Open the DeviceManagerService.exe.config file in a text editor and modify the line below to the timeout you desire in seconds.

<!-- NetQoS Portal (NPC) database configuration over-rides -->
<add key="portal.dbCommandTimeout" value="1800"/>

The default value is 1800 seconds(30 minutes), change it to the length of time you need, for example for 1 hour you would use:

<!-- NetQoS Portal (NPC) database configuration over-rides -->
<add key="portal.dbCommandTimeout" value="3600"/>

4. Save the file

5. Then, as a local administrator recycle IIS and the 'NetQoS Device Manager Service' with the steps below

iisreset /stop
sc stop "NetQoS Device Manager Service"
iisreset /start
sc start "NetQoS Device Manager Service"

6. Allow the Global Sync to run, if it still does not complete verify in the DeviceManagerService*.log that the timeout did apply and see if you need to increase it further.

7. To revert back the changes, copy the original DeviceManagerService.exe.config file and then run the SQL Statement below to restore the default values.

mysql -P3308 netqosportal
update general set value='1800000' where
attribute='devicemanager.timeout';