Welcome Serena Central users! CLICK HERE
The migration of the Serena Central community is currently underway. Be sure to read THIS MESSAGE to get your new login set up to access your account.
Highlighted
Knowledge Partner
Knowledge Partner

Re: User quotas display ** User Not Found **

Which OS and patchlevel are you running to get these entries listed with nssquota?

 

0 Likes
RSeifert Frequent Contributor.
Frequent Contributor.

Re: User quotas display ** User Not Found **

we are running on OES2015SP1, in preparation of upgrading to 2018SP1‎. Are the older versions of OES do not support this command?

0 Likes
Knowledge Partner
Knowledge Partner

Re: User quotas display ** User Not Found **

For sure they do, but even on a patched-to-the-top OES2018SP1 box nssquota doesn't display the "orphaned" entries.

 

0 Likes
RSeifert Frequent Contributor.
Frequent Contributor.

Re: User quotas display ** User Not Found **

Are you shure you are using USER quota? If you are using directory or volume quota you need other flags, of course.

Here's my script, which works as expected:

#!/bin/bash
### script for clearing orphaned user quota entries ("User Not Found"):

### Volumelist:

NSS_PREFIX=MUN
NSS_VOLLIST=`/opt/novell/ncpserv/sbin/ncpcon volumes 2>1 |grep ${NSS_PREFIX}` >/dev/null


### Verwaiste User Quotas?

for VOL in ${NSS_VOLLIST}
do

OrphanLog=/tmp/OrphanQuota_${VOL}.log
/opt/novell/nss/sbin/nssquota -U -V ${VOL} -g |grep 'User Not Found' |awk -F':' '{print $2}' |sed -e 's/^/"/' |sed -e 's/$/"/' > $OrphanLog

if [ -s $OrphanLog ]; then
echo -en "\nDie verwaisten User Quota Eintraege fuer das Volume '${VOL}' werden nun geloescht:\n\n"
sed -i "s/^/\/opt\/novell\/nss\/sbin\/nssquota -U -V ${VOL} -c -u /" $OrphanLog
sh $OrphanLog
else
echo -en "\nEs sind keine verwaisten User Quota Eintraege fuer das Volume '${VOL}' vorhanden!\n\n" >/dev/null
fi

sleep 1
rm $OrphanLog

done

 

0 Likes
Knowledge Partner
Knowledge Partner

Re: User quotas display ** User Not Found **

You're completely right. I had the impression it ceased to work on current 2018 code 'cause i had (on the lab box i checked) already removed the quota, so naturally nssquota couldn't list and consequently not remove it. But in iMan i had accidentally tagged the "All Users" instead of the "Users with Quotas" tab, and as the deleted object had ownership of a bunch of files its GUID was of course listed there.

So sorry for any confusion i might have caused: nssquota can still remove quotas by GUID.

 

0 Likes
RSeifert Frequent Contributor.
Frequent Contributor.

Re: User quotas display ** User Not Found **

Hi Mathias,
glad to hear that nssquota still works!

Best regards,
Robert
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.