Solved

Domino Mail file inventory/Cleanup

Posted on 2003-10-21
18
214 Views
Last Modified: 2013-12-18
We have several hundred user that have left , How can I find out who has person documents vs mail files on the server. We don't have a access to mailfile acl. I would like to create a list of mail files with no person documents, and a list of person document with no mail file.
Is there such an agent. The help software by "Power Tools" require admin access to the database. P.S. This is an AIX env.
0
Comment
Question by:dgardin
  • 8
  • 3
  • 2
  • +1
18 Comments
 
LVL 31

Expert Comment

by:qwaletee
ID: 9594132
You can use the DbDirectory object to get a list of files, and match them up.  or, you can use catalog or statlog data.
0
 
LVL 31

Expert Comment

by:qwaletee
ID: 9594135
Note: DbDirectory will not show items that have "show in open file dialog" turned off in database properties.  However, the catalog and statlog ALWAYS show ALL files.
0
 
LVL 31

Expert Comment

by:qwaletee
ID: 9594151
Correctoon: The catalog always CONTAINS al files, but the regular views in the catalog do not show item that have ben marked as "do not show in catalog" in database properties.
0
 
LVL 14

Accepted Solution

by:
p_partha earned 168 total points
ID: 9594193
You have to write a lotusscript agent to find out whether the user has mail fiel or not...

something on these lines
      Dim db As New NotesDatabase("notes007", "mail\b\test.nsf")
      Dim acl As NotesACL
      Dim entry As NotesACLEntry
      Set acl = db.ACL
      
      Set entry = acl.GetFirstEntry
      flag = Entry.IsGroup
      Msgbox flag

You will get the error cannot open if it is found. If the mail file is not found then it will say "it is not opened yet"
depending on the error number u can find out whether mail fiel exists or not

HTH
partha
0
 
LVL 31

Expert Comment

by:qwaletee
ID: 9594419
Const serverName = "your server"
Const dbFiles = "c:\mail_dbs.txt" 'for running on a windows PC
Const malUserFiles = "c:\mailuser.txt" 'ditto, for output of listed filenames on person docs
Dim db as new notesDatabase (serverName , "log.nsf" )
Dim view as notesView
Open dbFiles for output as #1
set view = db.getView("DatabaseSizes")
dim doc as notesDOcument
set doc = view.getFirstDocument
Dim fileName as string
Do Until doc is nothing
  fileName = lcase(doc.PathName(0))
  if Left$(fileName, 5) = "mail/" Then Print #1, fileName
  set doc = view.getNextDocument(doc)
Loop
Close #1

dim nab as new notesDatabase ( servername , "names.nsf" )
set view = nab.getView("Mail Users")
open mailUserFiles for output as #2
set doc = view.getFirstDocument
Do Until doc is nothing
  fileName = lcase(doc.MailFile(0))
  if fileName <> "" Then Print #1, fileName
  set doc = view.getNextDocument(doc)
Loop
Close #1


Now, srt the two files, and compare.  the differences will show where there is a file in the mail directory with no user, or a mail user with no mail file.  This assumes you have a single server, consistently use / instead of \ in person doc mail file names, and all mail files are in the mail directory.

While this will not identify teh USER NAME with the missing mail file directly, you can probably find those pretty easily based on the reported file name.  Being a Unix shop, I'm sure youknow how to use the shell commands to sort and compare the files.  The Windows eqivalents are sort.exe and fc.exe
0
 
LVL 31

Assisted Solution

by:qwaletee
qwaletee earned 166 total points
ID: 9594425
One more assumption: You run statlog nightly.  If not, just type LOAD STATLOG on the server console right now, and wait for it to complete before running this script.
0
 
LVL 14

Expert Comment

by:p_partha
ID: 9594432
Qwalette,
You seem to be too busy today in EE

CHeers
Partha
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 31

Expert Comment

by:qwaletee
ID: 9595037
Find somebody to pay me, I'll go away.
0
 

Author Comment

by:dgardin
ID: 9595177
Yes You guys are great. Ive never been to a forum so responsive.
0
 

Author Comment

by:dgardin
ID: 9595179
One other thing I forgot to mention, this is a clustered env.
0
 
LVL 31

Expert Comment

by:qwaletee
ID: 9595244
dgardin,
CLustering adds a bit of complexity, but nothing terrible.  Run the script against both servers.  The user list will be identical, becaus ethe NABs should be identical.  The dbs files MAY be identical, because typically in a clistered environment, you try to have all files on all servers (well, in a two-server cluster, anyway; on a three way, you may be load balancing and providing failover for each user to only one of the other servers).

I would actually identify the clustrer file differences first, and validate the "missing" fles from each server.  They may bemissing because someone got rid of a user, but only deleted one of the replicas instead of both... or it may help you find users you forgot to cluster or whose cluster creation failed.

Once you figure out what to do with the clustr imbalances, re-run the script, sort and merge the db lists, and compare to the sorted user list, as described above.  Any mismatches are an indicator of a file without a useror a user without a file.
0
 
LVL 15

Assisted Solution

by:Bozzie4
Bozzie4 earned 166 total points
ID: 9597250
I've used this tool from the sandbox in the past.

http://www-10.lotus.com/ldd/sandbox.nsf/ecc552f1ab6e46e4852568a90055c4cd/f5f9b19404adedba00256c38004abfb8?OpenDocument&Highlight=0,mail

Does the same as the other posters suggest, but it's an application that's ready to roll.

cheers,

Tom
0
 
LVL 15

Expert Comment

by:Bozzie4
ID: 9597262
And if you save your agents with the server.id, you can have admin access to all your databases.

I generally don't recommend saving agents using a server id, but in this case (on R5, I presume), it's a good way to do it.

If you are on R6 by any chance, you can use the Full Access Administrator feature to examine the mailfiles more closely ...  You won't need to save your agent with a server.id then, either, since you can use the 'Run on behalf of' feature

cheers,

Tom
0
 
LVL 31

Expert Comment

by:qwaletee
ID: 9599619
Bozzie4,

I've seen that tool.  Pretty good, but there are a few things coded to either IEEE's or Sumitomo's server configuration.
0
 
LVL 15

Expert Comment

by:Bozzie4
ID: 9601246
Can't remember, it's been 2 years since I used it myself (modified it to incorporate in a bigger analysis tool)
It does the job ...

cheers,

Tom
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Notes Document Link used by IBM Notes is a link file which aids in the sharing of links to documents in email and webpages. The posts describe the importance and steps to create a Lotus Notes NDL file in brief.
This article covers general Notes 8.5 troubleshooting information including recreating the Notes\Data folder.
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now