Hi again,

my apologies for posting this with the incorrect subject line. After a lot
of research, I found that the "No volumes found to label" error was caused
by an error in the group configuration for the user which bacula-sd runs
as. I have been following the fantastic instructions at
http://www.revpol.com/node/140?page=show which suggest running vchanger as
user=bacula and group=disk. However, bacula-sd could not access the files
referenced by the barcodes because the default primary group for the user
bacula was set to group=bacula. On some systems this may also be
group=tape. The solution is to ensure that the user/group combination for
the volume owner, bacula-sd and vchanger are all the same.

You can view the user as which daemons are running using "ps aux | grep
bacula".

I'm not particularly adept at Linux, so I found these instructions on
setting managing users and groups particularly useful.
http://www.howtogeek.com/50787/add-a-user-to-a-group-or-second-group-on-linux/

Cheers,
Leon



On Mon, Feb 25, 2013 at 12:53 PM, Leon White <leon.wh...@greenpeace.org>wrote:

> Hi,
>
> I am new to bacula and trying to set up a system which will backup our 3
> NAS towers to disks using the vchanger utility. We use an eSata changer
> with 1 drive only - quite a simple configuration. It took a while, but
> vchanger now works as advertised in the testing chapter of the
> documentation, and I am currently testing it with only 3 small slots
> configured to see how the drive swapping works in practice. However, I am
> not able to convince bacula to label the volumes using the label barcodes
> or update slots commands, and backup jobs hang waiting for me to issue a
> label command. The documentation informs me I should not enter volume
> labels for autochangers manually.
>
> The errors:
>
> *label barcodes
> Automatically selected Catalog: MyCatalog
> Using Catalog "MyCatalog"
> Automatically selected Storage: gpea-backup
> Connecting to Storage daemon gpea-backup at 192.168.85.55:9103 ...
> 3306 Issuing autochanger "slots" command.
> Device "vantec-nexstar" has 3 slots.
> Connecting to Storage daemon gpea-backup at 192.168.85.55:9103 ...
> 3306 Issuing autochanger "list" command.
> No Volumes found to label, or no barcodes.
>
> Following a run command:
> 25-Feb 12:47 dell-backup-dir JobId 3: Start Backup JobId 3,
> Job=BackupVideo3.2013-02-25_12.47.37_09
> 25-Feb 12:47 dell-backup-dir JobId 3: Using Device "vantec-drive-0"
> 25-Feb 12:47 dell-backup-sd JobId 3: Job
> BackupVideo3.2013-02-25_12.47.37_09 is waiting. Cannot find any appendable
> volumes.
> Please use the "label" command to create a new Volume for:
>     Storage:      "vantec-drive-0" (/var/lib/bacula/gpea-backup/0/drive0)
>     Pool:         File
>     Media type:   File
>
> However, running the vchanger list command shows that vchanger is in fact
> outputting 3 barcodes:
> strophy@dell-backup:/$ sudo vchanger -u bacula -g disk
> /etc/bacula/gpea-backup.conf list
> 1:gpea-backup_0001_0001
> 2:gpea-backup_0001_0002
> 3:gpea-backup_0001_0003
>
> Some config files:
>
> bacula-dir.conf:
> Storage {
>   Name          = gpea-backup
>   Address       = 192.168.85.55
>   SDPort        = 9103
>   Password      = "mH2Ps4Jim2UfNMxko_SQqxqTpuGSjJ7Up"
>   Device        = vantec-nexstar
>   Media Type    = File
>   Autochanger   = yes;
> }
>
> bacula-sd.conf
> Autochanger {
>   Name = vantec-nexstar
>   Device = vantec-drive-0
>   Changer Command = "/usr/local/bin/vchanger %c %o %S %a %d"
>   Changer Device = "/etc/bacula/gpea-backup.conf"
> }
>
> Device {
>   Name = vantec-drive-0
>   Drive Index = 0
>   Autochanger = yes;
>   Device Type = File
>   Media Type = File
>   Archive Device = /var/lib/bacula/gpea-backup/0/drive0
>   RemovableMedia = no;
>   RandomAccess = yes;
> }
>
> gpea-backup.conf (the vchanger configuration script):
> changer_name       = gpea-backup
> virtual_drives     = 1
> slots_per_magazine = 3
> magazine_bays      = 1
> automount_dir      = /mnt/vchanger
> logfile            = /var/lib/bacula/vchanger.log
> log_level          = LOG_ERR
> magazine = "UUID:ff4bd90a-b431-431e-b7d6-a9a323d4f5ee"
> magazine = "UUID:aa87944c-3a50-4c1d-a6dd-daca9761603d"
>
>
> Thanks for helping with this, let me know if more details are required!
> Leon
>
> --
> Leon White -- Greenpeace East Asia, Beijing
>



-- 
Leon White -- Greenpeace East Asia, Beijing
------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to