Environment
Novell Data Synchronizer Mobility Pack
Situation
Mobility server /var keeps growing every day by few gbs
/var/lib/pgsql/data keeps on growing in gigabytes every day
/var/lib/pgsql/data keeps on growing in size tremendously every day
Disk space being used very quickly on the mobility server
Resolution
There is a possibility that the Nightly Maintenance is not completing and needs more time to complete. Please follow the steps in the TID listed below to increase the time needed by nightly maintenance
http://https://support.microfocus.com/kb/doc.php?id=7012712
http://https://support.microfocus.com/kb/doc.php?id=7012712
Setting the Mobility Connector log file to debug and typing "cat default.pipeline1.mobility-AppInterface.log | grep maintenanceMonitor -i | grep users -i" can show how many users it has finished running the maintenance for.
If the Maintenance finishes but the database still keeps on growing tremendously, please type the following command to see which user has a lot of events in the database
-
Type psql -U datasync_user mobility
-
Enter the Database Password
-
Type the following command. Make sure to type the ; at the end of the command
Select DISTINCT u.userid AS "FDN", count(eventid) as "events", di.userid FROM deviceimages di INNER JOIN users u ON di.userid = u.guid GROUP BY u.userid, di.userid ORDER BY events DESC; -
It will give the list of users and their events. If any one user has tremendously large number of events, please delete that user
-
There is a possibility that even after deleting the user, the events may not get deleted from the database. Please follow the steps listed below to confirm
-
Type psql -U datasync_user mobility
-
Enter the Database Password
-
Type the following command. Make sure to type the ; at the end of the command
Select DISTINCT count(eventid) as "events", di.userid FROM deviceimages di GROUP BY di.userid ORDER BY events DESC; -
Note down the userid that has the highest number of events
-
Type the following command. Make sure to type the ; at the end of the command
select userid from users where guid = 'a9e4bef4f56b11e2b52d005056951c88';
Replace a9e4bef4f56b11e2b52d005056951c88 with the userid noted in the above step -
If no output is received then type the following command. Make sure to type the ; at the end of the command
delete from deviceimages where userid = 'a9e4bef4f56b11e2b52d005056951c88';
Replace a9e4bef4f56b11e2b52d005056951c88 that was noted above
-
After doing the above steps, please follow the steps in the following TID to run a vacuum and reindex
https://support.microfocus.com/kb/doc.php?id=7009453
https://support.microfocus.com/kb/doc.php?id=7009453