cancel
Showing results for 
Search instead for 
Did you mean: 

Does NetBackup follow sym and hard links?

Richard_Senda2
Level 4
Hello,
 
Can anyone please tell me if NetBackup will follow a symlink or a hardlink on UNIX?  i.e.  Will NetBackup backup the link itself, or the destination where the link points to?
 
Likewise, will NetBackup follow a hardlink on Windows created with the linkd utility?
 
So if I have a folder c:\test linked to c:\data\appser\webserv\images\java\etc will NetBackup just backup c:\test as a link or will it backup c:\test with the contents of c:\data\appser\webserv\images\java\etc?
 
If the latter, there is the potential to backup the same data twice once through c:\data\appser\webserv\images\java\etc and again through c:\test.  Is it possible to stop NetBackup from following the links in both Windows and UNIX?
 
I am using NetBackup 5.1 MP6.
 
Thanks.
 
Richard.
1 ACCEPTED SOLUTION

Accepted Solutions

Stumpr2
Level 6
NetBackup will backup the link but not the data that the link points to.
Netbackup can restore data via a link.
 
This is definitely covered in the admin guide
 
 

View solution in original post

5 REPLIES 5

Anton_Panyushki
Level 6
Certified
Short answer - no.

Stumpr2
Level 6
NetBackup will backup the link but not the data that the link points to.
Netbackup can restore data via a link.
 
This is definitely covered in the admin guide
 
 

Richard_Senda2
Level 4
Thanks for your replies.  I did some testing on this in a lab and what NetBackup does depends on the type of link:
 
Soft link or Windows Shortcuts:
These are backed up as files.  NetBackup does not follow the link therefore, the destination where the link points to is not backed up as part of the link.  So data only gets backed up once.
 
Hard links or Windows linkd:
Directories:
NetBackup follows the link and backs up the directory each time it finds a link.  Thus the directory will be backed up multiple times.
 
Files:
NetBackup will follow the first link it finds.  Subsequent links are backed up as links to the first.  This ensures that the file is only backed up once, but does mean that all of the links must be restored at the same time otherwise anomalies ocurr.
 
Richard.

Stumpr2
Level 6
Do you understand about restoring links?
This also is well documented in the admin guide.
 

stefanlasiewski
Level 3
I use symlinks, and it seems to work fine. Netbackup will follow the symlink, and will backup the destination directory. I have not been able to use symlinks to backup files, however.

For example, we have a cronjob which creates the following directory once per week. The date string changes every week.

    /nfs/nfs1.example.com/backup/server/weekly/20070915/

This cronjob also updates the following symbolic link every week:

Code:
    $ ls -ld /backup/server/weekly/    lrwxrwxrwx   1 root     root          39 Sep 27 16:50 /backup/server/weekly/ ->    /nfs/nfs1.example.com/backup/server/weekly/20070915

 


My Netbackup Netbackup policy has a backup selection of '/backup/server/weekly/'. The last backslash '/' is important, otherwise Netbackup will only backup the link itself, not the target.

In addition, I can see the files under the 'Restore Files' menu, and I have even run a couple of successful restores using these backup images. However, they are /nfs/nfs1.example.com/backup/server/weekly/20070915 .

I just discovered this possibility last week. Symantec support said this could not be done, but it seems to work fine. I hope that I'm not missing something obvious.