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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating a new policy from the command line

Status
Not open for further replies.

willster

IS-IT--Management
Aug 6, 2004
12
US
Does anyone have the syntax for creating Policys from the command line? Bppolicynew and bpplsched seem to work fine for creating and changeing the attributes, except I can't change the files I want to backup.
 
# ./bpplinclude -help
USAGE: bpplinclude policy_name [-v] [-M master_server,...] -L|-l
bpplinclude policy_name [-v] [-M master_server,...] -add path_name ...
bpplinclude policy_name [-v] [-M master_server,...] -add -f filename
bpplinclude policy_name [-v] [-M master_server,...] -delete path_name ...
bpplinclude policy_name [-v] [-M master_server,...] -delete -f filename
bpplinclude policy_name [-v] [-M master_server,...]
-modify {old_path_name new_path_name} ...

Note: paths with wildcards must be quoted.

Bob Stump
Just because the Veritas documentation states a certain thing does not make it a fact
 
There are two commands that may help you. I have never used them from command line but test it out and see if it works. /opt/openv/netbackup/bin/admincmd/bpplinclude and bpplexclude
Take a look at the syntax for these commands and I believe that they will let you change by adding or excluding certain files from existing policies.

The other option would be to create the include and exclude list manually in the /opt/openv/netbackup directory specifying the policyname and the schedule name on the client that the policy backs up on. I obviously prefer the second option but am interested if you decide to test the first one.
 
There is a man page on bpplinclude and here is a snippet:

bpplinclude maintains the policy file list for a NetBackup policy. This is the list of files backed up when NetBackup runs an automatic backup for the policy. The policy file list does not apply to user backups or archives since users select the files when they start those operations.

bpplinclude performs one of the following operations:

+ Adds pathnames to the policy file list

+ Deletes pathnames from the policy file list

+ Modifies pathnames in the policy file list

+ Displays the policy file list for a policy

The -add, -delete, and -modify options include a list of pathnames. The list of pathnames must be the final part of the bpplinclude command line. The pathname must be the entire path from the root of the file system to the desired location. For the absolute pathname syntax for your client type, refer to the File-Path Rules topics in the NetBackup System Administrator's Guide. The last part of the path can be a filename, a directory name, or a wildcard specification. You can en close pathnames in quotes. Use enclosing quotes if the pathname contains special characters or a wildcard specification.


Bob Stump
Just because the VERITAS documentation states a certain thing does not make it a fact and thats the truth
 
Thanks, it looks like bpplinclude is the piece I was missing.
 
Your Welcome!

...and Welcome! to this forum :)

Bob Stump
Just because the VERITAS documentation states a certain thing does not make it a fact and thats the truth
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top