Solved

Undead profile documents -- can't delete

Posted on 2004-03-31
16
529 Views
Last Modified: 2013-12-18
A profile-document mishap has left me with some "undead" profile documents that I can't get rid of. The problem is, one of these documents seems to be "attached" to a user, preventing him from performing a funciton in the database.

I've created a LotusScript agent that gathers all the profile documents in a doc collection (with Set dc = db.GetProfileDocCollection) and cycles through them. I've stepped through it in debug mode to take a look at these two rogue documents. Both seem to be entirely empty.

The UniversalID and NoteID are both empty. There are no items. The size is 0 (zero). The IsDeleted property is True.

I've tried removing the "good" profile docs from the doc collection and then cycling through calling dc.DeleteDocument(doc) and then doc.Remove(True), but that doesn't delete these zombies. I've also tried using dc.RemoveAll(true), but that crashes Notes, saying that some line of code has referenced memory location 0x0000000000.

All this is in Notes 5.08, by the way.

Any ideas how to exorcise these two documents?

Thanks.

-- b.r.t.
0
Comment
Question by:BarryTice
  • 7
  • 4
  • 3
  • +1
16 Comments
 
LVL 46

Accepted Solution

by:
Sjef Bosman earned 250 total points
Comment Utility
Hi Barry,

The only way I can think of is to call GetProfileDocument with the user's name, and then delete it.

Cheers!
   Sjef
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
You could also try to call GetProfileDocument, update a field, save the document and then delete it, hoping Notes corrected itself.

Already tried to run Fixup or Compact on that particular db?
0
 
LVL 7

Author Comment

by:BarryTice
Comment Utility
I've compacted the database, but I've not tried modifying the record. I'll try that.

Thanks.

-- b.r.t.
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
In yout replication settings of the db, goto space savers and enable remove Documents not modifiec in the last 90 days. And change the 90 to 0click ok and then close the dialog. If you want you can compact the db at this point.

After that check if there is any profile doc is left behind. And if so , then reset the changes that you made above in replica settings

~Hemanth
0
 
LVL 7

Author Comment

by:BarryTice
Comment Utility
Sjef --

When I change that dc.RemoveAll(true) to dc.StampAll("Garbage", Now) I get this error:
Notes error: Document has been deleted

I've also tried grabbing another "good" profile doc and using call goodDoc.CopyAllItems(doc, True) but I get the same error.

The IsDeleted property of the document is read-only, so I can't set that to false.

If I try to stuff a new item into the document using set item = new NotesItem(doc, "AnItem", "Help!") I get a "Could not create field" error.

After all this I tried to get the document using the user's name, as was your first suggestion. Darned if that didn't work. But the thing is, there were two of these zombie documents out there, and I don't know who the other one is attached to. Eventually I get the impression it's going to reach up and bite me.

Any ideas how to get rid of it, too?

Thanks!

Hemanth --

If I tell the db to remove documents not modified in the last 0 days, why wouldn't that delete all documents in the database? I don't think that would be in my best interests...

-- b.r.t.
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Last resort: try creating a new replica of the database, either local, or on the server in a separate directory. Then, move the old db from the Notes data directory outside the Notes data tree (either dbcache flush, or shut down the server if that's possible) and replicate the new replica back in place. The effect is a compact, but it's a whole new file.

There must be some Compact-option, I don't know them by heart (great Help-file!):
    Load Compact -c yourdb.nsf
This will do the same as the above.

See for the other options the Administrator's Help db
0
 
LVL 7

Author Comment

by:BarryTice
Comment Utility
Alas, I'm but a lowly rogue developer, expected to make things right in a dozen or so databases used by my business unit -- one small part of a multi-national company. They don't let me anywhere near the servers. (I'm so low in the company, when my boss's boss's boss asks me to create a new database, it still takes me two weeks' worth of jumping through hoops to even get someone to put it out on a server.) So I don't think that's going to be an option for me, Sjef.

I guess at this point it's going to be a matter of waiting until whoever it is tries to perform this action and gets the error message. Not the best solution, but it is job security, I guess.

I'll keep this open a bit longer to see if anybody else has any suggestions.

-- b.r.t.
0
 
LVL 24

Expert Comment

by:HemanthaKumar
Comment Utility
oh yeah.. it is possible I just wanted you to play with a backup copy and not live one.. so that you can remove profile docs and then copy/replicate the original documents.. It is just a hint, I haven't tried it as other methods worked gr8 for me.
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 7

Author Comment

by:BarryTice
Comment Utility
OK, you all saw him! Hemanth was trying to get me to delete all my documents! I'm telling mom!
0
 
LVL 7

Author Comment

by:BarryTice
Comment Utility
Oh, wait. Sorry. I thought this was the Lounge there for a moment...
0
 
LVL 31

Expert Comment

by:qwaletee
Comment Utility
Barry,

You can build a list of all users (either all names in the NAB, or all names in whatever groups have DB access).  Then, cycle through that user list and try to get the profile for each.

You can also try using NotesPeek to find the profile.

This really sounds like a corupt doc, and an exhaustive fixup should do the trick.
0
 
LVL 7

Author Comment

by:BarryTice
Comment Utility
Given that I have no administrative authority (other than Manager access to the database), how do I run fixup?
0
 
LVL 31

Expert Comment

by:qwaletee
Comment Utility
Ah... yu don't.  try getting friendly with an admin, and telling him you think you have a corrupt DB.
0
 
LVL 46

Expert Comment

by:Sjef Bosman
Comment Utility
Or tell him that your boss's boss's boss has a corrupt mail db, they might start running for you :)

By the way, do you have ANY rights on the server?? And on the db? Are you allowed to create replica's on the server?

Or is everything so secure that they make you forget what you did yesterday?? You can't remember, you say. Ah...
0
 
LVL 7

Author Comment

by:BarryTice
Comment Utility
I have no server rights to speak of, Sjef.

Officially, I'm not even supposed to be doing database work. My company has a division to do that. (Of course, they're in, uh, New York, I think, while I'm in Alabama.) But when I started here 5 years ago (as a tech writer) and my boss found out I could do Notes development, she jumped on the opportunity, and at that point corporate wasn't so strict. So I'm kind of grandfathered in as a developer for my business unit. (The "official" group sees me as a rogue developer, I'm told. I see them as good functional coders working on designs that don't take usability or appearance into consideration.)

As for getting friendly with an admin, there aren't even any in the state (despite no fewer than four corporate offices in the state). There's a guy I work with who used to be a Notes admin for our office, but they've taken that away from him and moved him to PC network support and AS/400 support. Now all the Notes admin work is handled remotely. (There are more than 250 Notes servers in my company worldwide, according to the All Server Documents view in the PAB.)

And, alas, it's not a mail database, so I can't use that as incentive to get them motivated. I can put in a call to the help desk, but my experience with that has been that they might get to it in a month.

Of course, that's better than nothing, I guess. So maybe I'll do that and check in a month or so to see if that last zombie document is gone. At least the function that will be limited for this one person is one that they may never have to use again, so even if the document stays there forever it might not cause any troubles.

Thanks, everyone, for all the help!

-- b.r.t.
0
 
LVL 31

Expert Comment

by:qwaletee
Comment Utility
If you don't mind my asking, what company do you work for?
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

Suggested Solutions

This is an old article, please see an updated version of this article, located here: http://www.experts-exchange.com/articles/23619/Notes-8-5x-Windows-7-Notes-info-and-tips.html
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.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

762 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

12 Experts available now in Live!

Get 1:1 Help Now