You are here

Bulk labelling volumes in Bacula

My EC2 Bacula storage configuration consists of a single pool containing multiple storage devices. Each storage device is a 100GB EBS store, and each contains a fixed number of prelabelled 1GB volumes.

Here's a little script I whipped together to prelabel the volumes with an incremental identifier.

[geshifilter-code]NAME bulklabel -- label new Bacula volumes with incremental names VERSION 1.0 February 5, 2013 SYNOPSIS bulklabel <pool> <storage> <start> <count> <prefix> bulklabel <pool> <storage> <start> <count> pool: name of pool resource storage: name of storage resource start: first numerical identifier count: number of volumes to create prefix: optional volume name prefix EXAMPLES bulklabel Default FileStorage1 10000 100 Vol- will create 100 volumes named Vol-10000, Vol-10001... bulklabel Scratch Tape1 20000 50 will create 50 volumes named 20000, 20001... COPYRIGHT (c) 2013, Yvan Rodrigues http://yvanrodrigues.com Red Cell Innovation Inc. http://two-red-cells.com LICENSE FreeBSD license http://en.wikipedia.org/wiki/FreeBSD_License [/geshifilter-code]

Add new comment

Simple Copyright Policy: If you want to reproduce anything on this site, get my permission first.