RefChecker v1.0

over 13 years ago
Runs on: Linux
Command Dependencies: "which" & "wget"
Audience: Automated troubleshooting using iMonitor. Adapt script to cater for many situations where iMonitor is required for automation.

This utility will allow a cross reference check between two objects against specified attributes using iMonitor.

There used to be a utility around that could check the reference between user and group objects. This utility will check the reference between any object types, even for hidden schema attributes.


  1. Specify a source (initial) object name and the attribute which contains a list of objects to check, e.g. a group and the group's "member" attribute

  • Specify the attribute on the object referenced by the "member" attribute, which should contain the name of the source/initial object, e.g. groupmembership

The problem: There is a GroupWise object which reports -618 errors due to users in the Member attribute not being cleared when the user is deleted.

Example of how this works: The util gets a list of the users listed in Member attr on the GroupWise object "PO1" (from a specified server, IP address), then checks that server and each other server listed (on command-line or from serverlist file) to see if those users have a "Reference" attribute value of "PO1".

  • This version uses the &ref tag to make all requests through the first server listed

  • Will auto-check the schema to see if the attribute on the remote object is hidden. If so use an additional URL request to get the data, because we need the object entry info as well, which is not provided when requesting specific attributes. (iMon enhancement logged against this.)

Utility Syntax:

-n [name_of_initial_object] the TREE name is required!/

-a [attribute_name] on the initial object. (Case Sensitive)

-r [referenced_attribute_name] on the objects being checked/ (Case Sensitive)

-u [username_for_iMonitor_login]

-w [password_for_iMonitor_login]

-s [DNS_server_OR_ipaddress] of all servers to contact for checking. Separated by ; or ,

-f [Filename] listing servers to contact. Place each servername or IP Addr on a new line. (Overrides -s)

-p [iMonitor_port] Default is (8028). Must be the non-SSL port!

-o [output_file]

-k Report report all Values Details on the referenced object/s. Default is OFF

-x Use this option, instead of -w, to use the password hard-coded in the script
(Used for command-line privacy).

-z Don't clean up the temporary working directory '_tmpwget' after execution

-d Append the date and time to the output file name to make the file unique

-e If no errors are reported only create an empty file called 'lastrun_<date_time>'
(There will be max one 'lastrun' file)

Example: ./ -n "group1,services,acme,novell,TEST1" -a "Member" -r "group membership" -u "admin.novell" -w "novell" -s ",," -o group1-refs.txt

Specify the name of the initial object to be checked. This object could be a Group, GroupWise Post Office or ZEN application.

Feedback: If you have other requirements let me know, if it sounds like a good idea I can adapt the code to cater for that situation.


How To-Best Practice
Comment List
Related Discussions