Hi there,
I am in the process to built a WFA Cache Database storing values that are required for User-Quota-Management (UQM). UQM should be implemented as Workflow and is relying on activated default user-quotas.
SVM:\\VolumeName\QtreeName\user_name <---- user_quota.users
In order to obtain all required storage-object details required for UQM I am querying the OCUM DB with following sql statement:
####
SELECT
qtree_quota.objid AS id,
qtree_quota.diskLimit/1024 AS disk_limit_mb,
qtree_quota.fileLimit AS file_limit,
qtree_quota.qtreeId AS qtree_id,
qtree_quota.softDiskLimit/1024 AS soft_disk_limit_mb,
qtree_quota.softFileLimit AS soft_file_limit,
qtree_quota.quotaTarget AS target,
qtree_quota.threshold/1024 AS threshold_mb,
'tree' AS type,
NULL as user_mapping,
qtree_quota.volumeId AS volume_id,
NULL as user_name
FROM
netapp_model_view.qtree_quota
UNION
SELECT
user_quota.objid AS id,
user_quota.diskLimit/1024 AS disk_limit_mb,
user_quota.fileLimit AS file_limit,
user_quota.qtreeId AS qtree_id,
user_quota.softDiskLimit/1024 AS soft_disk_limit_mb,
user_quota.softFileLimit AS soft_file_limit,
user_quota.quotaTarget AS target,
user_quota.threshold/1024 AS threshold_mb,
user_quota.quotaType AS type,
NULL as user_mapping,
user_quota.volumeId AS volume_id,
user_quota.users AS user_name
FROM
netapp_model_view.user_quota
########
This sql-statement is working within an simple SQL-Editor and is returning the storage-object details required for changing a quota for an existing user "user_quota.users".
Unfortunately a WFA cache update for this specific "table" fails. If I have understood the "Dynamic Home Share function" correctly, using default quotas would result in multiple
entries with different users but in the same Qtree.
####
Extract WFA Log Message:
2014-10-23 11:01:27,925 INFO [com.netapp.wfa.cache.job.CacheJobExecutorImpl] (Thread-6883 (HornetQ-client-global-threads-1685068325))
Acquisition job 7859 - 1 warning - Duplicate rows found for cache table 'cm_storage.quota_rule_cache',
Columns: (id,disk_limit_mb,file_limit,qtree_id,soft_disk_limit_mb,soft_file_limit,target,threshold_mb,type,user_mapping,volume_id,user_name)
Rows: (6237,0.0000,0,6236,0.0000,0,,0.0000,USER,null,6230,BUILTIN\Administrators)
####
So - how do I have to change the Cache-DB query in order to get these multiple?
Environment: OCUM 6.1 and WFA 2.2.x.
Thank you,
Rabé