cancel
Showing results for 
Search instead for 
Did you mean: 

Change order of DSU from command line in NB

subs
Level 4

Hi,

I'm looking for a way to automate the changing of the order of basic disk units in a storge group. I can see bpstudel and bpstuadd but I imagine weird things may happen if I delete and add units from a storage group whilst it is in use, which it mostly is.

We can re-order from the gui fine...so can it be done from the command line?

Cheers.

1 ACCEPTED SOLUTION

Accepted Solutions

watsons
Level 6

bpsturep is the command, but it does not allow you add or delete (change order) at the same time.

However there is still a workaround, assuming if you have 2 STUs inside a STUG. Prepare a script to run these 2 commands:

bpsturep -group tapeGroup -delstu <first_STU>
bpsturep -group tapeGroup -addstu <first_STU>

This will swap the order of the 2 STUs (FIFO order). If you have more, just add in more lines.

Whether NBU is going to pick up the change for the next job, I am not sure though.. may need to test out. Maybe doing a "bprdreq -rereadconfig" after those commands

View solution in original post

3 REPLIES 3

Mark_Solutions
Level 6
Partner Accredited Certified

I cant see anything but there must be one!

You could up your logging and them make the change and see if it logs the command under netbackup\logs\admin\

Please let us know if youy find it!

Karthikeyan_Sun
Level 6

 

install_path\NetBackup\bin\admincmd\bpsturep -label storage_unit_label [-verbose] [-host host_name | -nodevhost] [-path path_name | -dp disk_pool | -density density [-rt robot_type -rn robot_number] [-nh NDMP_attach_host] [-cj max_jobs] [-odo on_demand_only_flag] [-mfs max_fragment_size] [-maxmpx mpx_factor] [-cf 0 | 1] [-flags flags] [-tt transfer_throttle] [-hwm high_water_mark] [-lwm low_water_mark] [-okrt ok_on_root] [[-addhost | -delhost] host_name [host_name]] [-hostlist host_name [host_name]] [-M master_server [,...] install_path\NetBackup\bin\admincmd\bpsturep -group storage_unit_group [-addstu | -delstu] storage_unit_label [-M master_server [,...]] [-sm selection_method]
 
-sm selection_method 
 
Selects the method in which a storage unit group is chosen. This option is valid only for storage unit groups. The possible values for selection_method are:
 
 
Prioritized = 1 (DEFAULT)
 
 
Least Recently Selected = 2
 
 
Failover = 3
 
 
Load Balance = 4 (appears if Capacity Management license key is installed)
 
 
Option 1: Prioritized is the default condition. It selects the first storage unit in the list until either the unit is down or full, or its max-concurrent-jobs setting is reached. Then the next storage unit in the list is examined and so on until an available one is found.
 
 
Option 2: Least Recently Selected selects the least-recently selected storage unit.
 
 
Option 3: Failover is the same as Prioritized except MDS queues a job to wait for the first storage unit if the max-concurrent-jobs is reached. MDS moves to the next storage unit in the list only if the first unit is down or full.
 
 
Option 4: Load Balance. For this option to appear, make sure that you have installed the Capacity Management license key. If the user selects this option, Media Device Selection (MDS) balances the job load by considering if a media server meets these conditions:
 
 
- Enough disk volume free space available to accommodate the estimated job size.
 
 
- Enough CPU and memory resources available to accommodate another job.
 
 
- Least amount of estimated job size data being processed compared to other media servers of the same class or rank.
 
 
If the license expires, then Load Balance reverts to Option 2 behavior. It selects the least-recently selected storage unit. 

watsons
Level 6

bpsturep is the command, but it does not allow you add or delete (change order) at the same time.

However there is still a workaround, assuming if you have 2 STUs inside a STUG. Prepare a script to run these 2 commands:

bpsturep -group tapeGroup -delstu <first_STU>
bpsturep -group tapeGroup -addstu <first_STU>

This will swap the order of the 2 STUs (FIFO order). If you have more, just add in more lines.

Whether NBU is going to pick up the change for the next job, I am not sure though.. may need to test out. Maybe doing a "bprdreq -rereadconfig" after those commands