[Bacula-users] Cannot label tape from bconsole

2016-01-20 Thread danny
Solved this problem by deactivating SELinux, just type setenforce 0 with root 
permission and the problem was gone.

+--
|This was sent by da...@uci.cu via Backup Central.
|Forward SPAM to ab...@backupcentral.com.
+--



--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] Cannot label tape from bconsole

2007-02-28 Thread Alfonso Amato - Sintecnos srl
Really thanks Andrea.. That is a side of Linux I never investigate from 
my side and I guess I'll have a good time digging inside.

Alfonso

Andrea Conti wrote:
>> Can you tell me what method you have in mind for changing permissions? A 
>> shell line inside /etc/init.d/bacula-sd.conf (I use Fedora) with the 
>> chmod previously said or a different command?
> 
> I suppose you're using a recent (>2) version of fedora, so your system
> should be running udev.
> If that's the case, you just need to tell udev which
> owner/group/permissions you want that device node to be created with.
> 
> Create a file named "10-tape.rules" in /etc/udev/rules.d with the
> following line in it:
> 
> KERNEL=="nst0", OWNER="foo", GROUP="bar", MODE="0660"
> 
> If you don't need to set the owner or group simply leave out the
> corresponding section.
> 
> Taking a look at the udev documentation on rule writing might also be a
> good idea, since there is much more you can do with it.
> 
> Andrea

-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] Cannot label tape from bconsole

2007-02-27 Thread Ralf Gross
Alfonso Amato - Sintecnos srl schrieb:
> I agree and your position is true.
> 
> Can you tell me what method you have in mind for changing permissions? A 
> shell line inside /etc/init.d/bacula-sd.conf (I use Fedora) with the 
> chmod previously said or a different command?

If your system supports udev, you can write your own rule. This is for
a debian etch system.

/etc/udev/rules.d/010-local.rules

SUBSYSTEM=="scsi_generic", SYSFS{model}=="T40A",
SYMLINK+="NEC-T40A", GROUP="tape", MODE="0660"
KERNEL=="st*",  GROUP="tape", MODE="0660"
KERNEL=="nst*", GROUP="tape", MODE="0660

VU0EM005:~# ls -l /dev/NEC-T40A 
lrwxrwxrwx 1 root root 4 2007-02-09 15:18 /dev/NEC-T40A -> sg11
VU0EM005:~# ls -l /dev/sg11 
crw-rw 1 root tape 21, 11 2007-02-09 15:18 /dev/sg11

VU0EM005:~# ls -l /dev/nst*
crw-rw 1 root tape 9, 128 2007-02-09 15:18 /dev/nst0
...

You can get the necessary information with udevinfo.

udevinfo -a -p $(udevinfo -q path -n /dev/$YOURDEVICE)

Ralf

-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] Cannot label tape from bconsole

2007-02-27 Thread Andrea Conti
> Can you tell me what method you have in mind for changing permissions? A 
> shell line inside /etc/init.d/bacula-sd.conf (I use Fedora) with the 
> chmod previously said or a different command?

I suppose you're using a recent (>2) version of fedora, so your system
should be running udev.
If that's the case, you just need to tell udev which
owner/group/permissions you want that device node to be created with.

Create a file named "10-tape.rules" in /etc/udev/rules.d with the
following line in it:

KERNEL=="nst0", OWNER="foo", GROUP="bar", MODE="0660"

If you don't need to set the owner or group simply leave out the
corresponding section.

Taking a look at the udev documentation on rule writing might also be a
good idea, since there is much more you can do with it.

Andrea

-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] Cannot label tape from bconsole

2007-02-27 Thread Alfonso Amato - Sintecnos srl
I agree and your position is true.

Can you tell me what method you have in mind for changing permissions? A 
shell line inside /etc/init.d/bacula-sd.conf (I use Fedora) with the 
chmod previously said or a different command?

Alfonso

IEM - network operating center wrote:
> Alfonso Amato - Sintecnos srl wrote:
>> Changed permission of /dev/nst0* into 660 and works correctly! I suggest 
>> to add the "chmod " line into the Brief tutorial while testing not on 
>> file but on real tape.
>>
> 
> i rather suggest adding a line like "make sure you do have the correct
> permissions to access the tape" if it is not already there.
> 
> your chmod trick might well not work on all systems (e.g. udev/devfs
> will recreate the devices on bootup, thus losing the new permissions if
> you don't configure your system accordingly)
> 
> mfga.sdr
> IOhannes

-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] Cannot label tape from bconsole

2007-02-27 Thread IEM - network operating center
Alfonso Amato - Sintecnos srl wrote:
> Changed permission of /dev/nst0* into 660 and works correctly! I suggest 
> to add the "chmod " line into the Brief tutorial while testing not on 
> file but on real tape.
> 

i rather suggest adding a line like "make sure you do have the correct
permissions to access the tape" if it is not already there.

your chmod trick might well not work on all systems (e.g. udev/devfs
will recreate the devices on bootup, thus losing the new permissions if
you don't configure your system accordingly)

mfga.sdr
IOhannes

-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] Cannot label tape from bconsole

2007-02-27 Thread Alfonso Amato - Sintecnos srl
Changed permission of /dev/nst0* into 660 and works correctly! I suggest 
to add the "chmod " line into the Brief tutorial while testing not on 
file but on real tape.

Thanks alot Adam!

Alfonso

Adam Cécile wrote:
> Check permissions on /dev/nst0.
> 
> Alfonso Amato - Sintecnos srl a écrit :
>> While setting up Bacula and following "Brief Tutorial", I see a 
>> strange problem: after the command "run" asking me for labelling the 
>> tape, I give the command "label", and bconsole gets lock for some 2 
>> minutes, than says:
>>
>> 3910 Unable to open device "DAT72" (/dev/nst0): ERR=dev.c:424 Unable 
>> to open device "DAT72" (/dev/nst0): ERR=Permission denied
>>
>> The most strange thing is that if I use btape /dev/nst0 and issue a 
>> command "label", it works correctly and the "read" command says the 
>> tape has been correctly labelled.
>>
>> The Linux Box is a FC4.
>> bacula-sd.conf file about device is:
>>
>> Device {
>>Name = DAT72
>>Media Type = DSS-3
>>Device Type = Tape
>>Archive Device = /dev/nst0
>>AutomaticMount = yes;
>>AlwaysOpen = yes;
>>RemovableMedia = yes;
>>RandomAccess = no;
>>Label Media = yes;
>>Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
>> }
>>
>>
>> and in the bacula-dir.conf:
>>
>> Storage {
>>Name = Tape
>>Address = backupserver.pippo.local  #existing address resolved
>>SDPort = 9103
>>Password = ""
>>Device = DAT72
>>Media Type = DSS-3
>> }
>>
>> Any help?
>>
>> Thanks
>> Alfonso
>>
>> -
>> Take Surveys. Earn Cash. Influence the Future of IT
>> Join SourceForge.net's Techsay panel and you'll get the chance to 
>> share your
>> opinions on IT & business topics through brief surveys-and earn cash
>> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
>> ___
>> Bacula-users mailing list
>> Bacula-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/bacula-users
>>   
> 
> 

-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


Re: [Bacula-users] Cannot label tape from bconsole

2007-02-27 Thread Adam Cécile
Check permissions on /dev/nst0.

Alfonso Amato - Sintecnos srl a écrit :
> While setting up Bacula and following "Brief Tutorial", I see a strange 
> problem: after the command "run" asking me for labelling the tape, I 
> give the command "label", and bconsole gets lock for some 2 minutes, 
> than says:
>
> 3910 Unable to open device "DAT72" (/dev/nst0): ERR=dev.c:424 Unable to 
> open device "DAT72" (/dev/nst0): ERR=Permission denied
>
> The most strange thing is that if I use btape /dev/nst0 and issue a 
> command "label", it works correctly and the "read" command says the tape 
> has been correctly labelled.
>
> The Linux Box is a FC4.
> bacula-sd.conf file about device is:
>
> Device {
>Name = DAT72
>Media Type = DSS-3
>Device Type = Tape
>Archive Device = /dev/nst0
>AutomaticMount = yes;
>AlwaysOpen = yes;
>RemovableMedia = yes;
>RandomAccess = no;
>Label Media = yes;
>Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
> }
>
>
> and in the bacula-dir.conf:
>
> Storage {
>Name = Tape
>Address = backupserver.pippo.local  #existing address resolved
>SDPort = 9103
>Password = ""
>Device = DAT72
>Media Type = DSS-3
> }
>
> Any help?
>
> Thanks
> Alfonso
>
> -
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys-and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> ___
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users
>   


-- 
Adam CECILELinbox / Free&ALter Soft
152 rue de Grigy   tél: +33 3 87 50 87 95
Technopôle Metz 2000   fax: +33 3 87 75 19 26   
57070 METZ - Francehttp://www.linbox.com


-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users


[Bacula-users] Cannot label tape from bconsole

2007-02-27 Thread Alfonso Amato - Sintecnos srl
While setting up Bacula and following "Brief Tutorial", I see a strange 
problem: after the command "run" asking me for labelling the tape, I 
give the command "label", and bconsole gets lock for some 2 minutes, 
than says:

3910 Unable to open device "DAT72" (/dev/nst0): ERR=dev.c:424 Unable to 
open device "DAT72" (/dev/nst0): ERR=Permission denied

The most strange thing is that if I use btape /dev/nst0 and issue a 
command "label", it works correctly and the "read" command says the tape 
has been correctly labelled.

The Linux Box is a FC4.
bacula-sd.conf file about device is:

Device {
   Name = DAT72
   Media Type = DSS-3
   Device Type = Tape
   Archive Device = /dev/nst0
   AutomaticMount = yes;
   AlwaysOpen = yes;
   RemovableMedia = yes;
   RandomAccess = no;
   Label Media = yes;
   Alert Command = "sh -c 'tapeinfo -f %c |grep TapeAlert|cat'"
}


and in the bacula-dir.conf:

Storage {
   Name = Tape
   Address = backupserver.pippo.local  #existing address resolved
   SDPort = 9103
   Password = ""
   Device = DAT72
   Media Type = DSS-3
}

Any help?

Thanks
Alfonso

-
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
___
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users