Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to list files backed up from a client in a particular backup run?

Status
Not open for further replies.

libove

MIS
Apr 9, 2002
56
US
How do I get a list of all files backed up from a particular client during a particular backup run (a list of every file backed up from client "X" during the most recent run of the Default group, for example)?

I seem to be backing up WAY too much data from a particular client each night (>2GB per night on a simple workstation), so I want to see what is getting backed up exactly, as part of analyzing why the files are getting backed up.

Thanks!
-Jay
 
look at the man pages for nsrinfo... it has an example that does exactly that:

# mminfo -r nsavetime -v -N /usr -c mars -ot | tail -1
809753764
# nsrinfo -t 809753764 mars

In this case the client name is mars, and the saveset you want to query is /usr. -ot will display the output in ascending chronolical order. Tail -1 will display the last line of the mminfo output, thus giving you the most recent backup of /usr.

Piping the results to nsrinfo will produce the list of all files within the saveset.
 
Okay, that seems to make sense from the manual pages, and the output doesn't seem to make sense, so I have to expand the search. Though the output of the nsrinfo command looks like it is dumping the whole index for that client, I agree that the manual page states that the -t timestamp option restricts output to only those files in the specified saveset, and the research below suggests that indeed the files really are being backed up every night, and of course I trust you guys out here on tek-tips :)


C:> mminfo -r nsavetime -v -c beast3 -ot | tail -1
1037090013

C:> nsrinfo -t 1037090013 beast3 > file.txt

C:> wc -l file.txt
24714 file.txt

Repeat command for the previous several saveset timestamps and all of them have some 24000 to 25000 files.

Look at the actual file list from several of the last savesets, seeking a file which definitely hasn't changed and isn't post-dated, in my particular case the file

C:\WINDOWS2\winhelp.exe

C:\WINDOWS2\... is where I installed a second whole copy of Windows XP Pro on this client for diagnosis reasons.

C:\WINDOWS2\winhelp.exe is dated 08/18/2001. The current system date is 11/12/2002.

That file definitely should not show up in several consecutive incremental backups .. right??


So, next step: how do I run a command on the client, matching what the server will remotely execute on that client, to generate a list of files that would be backed up, so I can see perhaps why these files are actually being backed up repeatedly?

Thanks again!
-Jay
 
What type of backup are you performing? Full? incremental? level?

Before you try to do all that work, look at your daemom.log and see if there's any indications that your media database is corrupted.

If the size of the incremental or level>0 backups is about the same as the full, then this could be caused by a corrupted NetWorker database. Run nsrck -L6 <client> then msrim -X. Then see if the problem returns after a couple of backups.

You can always run the savegroup with a probe to see what would be backed up on the client:

savegrp -p -vv -c <client> -l 1 <Group_name>
 
Okay, I ran the nsrck and nsrim commands and found no index corruption or any other indication of problems. I then ran some savegrp -p and savefs -n commands, and I found that savefs on this client is choosing to backup files which should not need to be backed up.

The client is Networker 6.2.109 on Windows XP Pro SP1 with all patches; the server is Networker 6.2.109 on Windows NT 4.0 SP6a with all patches. The client is in the Default group. The Default group is the only enabled group. It is configured with only one save set &quot;c:\&quot; (no actual quotes in the Networker Administrator GUI), schedule Quarterly.

How do I go forward with figuring out why savefs is finding lots of files which it backed up the night before and which haven't changed and aren't future dated, with the indexes evidently in good condition?

Thanks again!
-Jay
 
What level backups are being performed? Does the incremental (or levels 1-9) backup seem to be the same size as the full?

Do these files have the archive bit set?

To prevent the incremental backup from backing up files that have the archive bit set, set the following SYSTEM environmental parameter:

NSR_AVOID_ARCHIVE=YES
 
The backup levels vary from numbers (every week or so) to incremental (every night except for the weekly numbers and quarterly full). The size backed up from this client is fairly consistent from night to night incremental to incremental. I'm not sure whether I've even seen a numbered backup go by yet. The manual commands I did (above) had the incremental level specified.

As it happens, the C:\WINDOWS2\winhelp.exe file does have the Archive attribute set. However, I thought that Networker doesn't rely on that at all, instead relying on the presence of the same file (according to date and size) in the index?

Reality check here, how does Networker decide whether to back up a particular file?

I don't want Networker to have to play with the Archive bit at all, as I don't consider it reliable (I'm a paranoid UNIX weenie, don't mind me please).

Thanks again
-Jay
 
Whether a file is backed up is dependant on the following:

Does the file already have a full backup?

Has the file been modified since the last backup, or last
full backup, depending on what backup level you are using?

Is the archive bit turned on?

Please refer to the following Legato document entitled: How NetWorker selects files for incremental backups on Windows NT



Try setting the environmental variable NSR_AVOID_ARCHIVE=YES and see if it resolves your issue. If not, then you might have stumbled upon a problem that you should call Legato support on.
 
Thanks. I've set NSR_AVOID_ARCHIVE=YES in the systemwide variables on the client, and will see how the backup runs tonight.

It IS on the client side where I need to set this variable, right?

Thanks!
-Jay
 
Yes, the NSR_AVOID_ARCHIVE variable is set on the NetWorker client

Set NSR_AVOID_ARCHIVE as a system environmental variable, not a user environmental variable.

Reboot the system to activate the variable.
 
So, I finally got around to rebooting the client system after setting the NSR_AVOID_ARCHIVE variable, and lo and behold the next two nights' backups were ~20MB each.

What is strange about all this is that the article referenced by Wallace88 indicates that for Networker version 4.3 and newer, the Archive bit isn't used at all... so why, with version 6.2, did I need to set a variable to tell Networker to ignore the Archive bit?

Thanks very much to Wallace88 for the help!
-Jay
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top