Hi guys,

thanks for all your help, it turned to be my stupid copy/paste mistake.
I had ClientRunBeforeJob instead of RunBeforeJob
so poor bacula was trying to run the sshtunnel script on the client.

Fixed and now my sshtunnel works

*message
23-Feb 14:54 bacula7-dir JobId 268: shell command: run BeforeJob 
"/etc/bacula/scripts/sshbacula.sh"
23-Feb 14:54 bacula7-dir JobId 268: BeforeJob: Starting SSH-tunnel to centos7...

*message
23-Feb 14:54 bacula7-dir JobId 268: Start Backup JobId 268, 
Job=centos7.2017-02-23_14.54.19_04
23-Feb 14:54 bacula7-dir JobId 268: Using Device "FileStorage" to write.
23-Feb 14:54 bacula-sd JobId 268: Volume "VirtualTape-Dev-0014" previously 
written, moving to end of data.
23-Feb 14:54 bacula-sd JobId 268: Ready to append to end of Volume 
"VirtualTape-Dev-0014" size=1,261,100,974
*
You have messages.
*
*message
23-Feb 14:54 bacula-sd JobId 268: Elapsed time=00:00:04, Transfer rate=2.963 M 
Bytes/second
23-Feb 14:54 bacula-sd JobId 268: Sending spooled attrs to the Director. 
Despooling 1,014,342 bytes ...
23-Feb 14:54 bacula7-dir JobId 268: Bacula bacula7-dir 7.0.5 (28Jul14):
  Build OS:               x86_64-redhat-linux-gnu redhat Enterprise release
  JobId:                  268
  Job:                    centos7.2017-02-23_14.54.19_04
  Backup Level:           Full
  Client:                 "centos7-fd" 5.2.13 (19Jan13) 
x86_64-redhat-linux-gnu,redhat,(Core)
  FileSet:                "centos7" 2017-02-20 13:06:34
  Pool:                   "DevServersFile" (From Job resource)
  Catalog:                "MyCatalog" (From Client resource)
  Storage:                "File" (From Job resource)
  Scheduled time:         23-Feb-2017 14:54:11
  Start time:             23-Feb-2017 14:54:31
  End time:               23-Feb-2017 14:54:36
  Elapsed time:           5 secs
  Priority:               10
  FD Files Written:       3,912
  SD Files Written:       3,912
  FD Bytes Written:       11,377,350 (11.37 MB)
  SD Bytes Written:       11,852,637 (11.85 MB)
  Rate:                   2275.5 KB/s
  Software Compression:   63.9% 2.8:1
  VSS:                    no
  Encryption:             no
  Accurate:               no
  Volume name(s):         VirtualTape-Dev-0014
  Volume Session Id:      1
  Volume Session Time:    1487890429
  Last Volume Bytes:      1,273,077,031 (1.273 GB)
  Non-fatal FD errors:    0
  SD Errors:              0
  FD termination status:  OK
  SD termination status:  OK
  Termination:            Backup OK

23-Feb 14:54 bacula7-dir JobId 268: Begin pruning Jobs older than 6 months .
23-Feb 14:54 bacula7-dir JobId 268: No Jobs found to prune.
23-Feb 14:54 bacula7-dir JobId 268: Begin pruning Files.
23-Feb 14:54 bacula7-dir JobId 268: No Files found to prune.
23-Feb 14:54 bacula7-dir JobId 268: End auto prune.

*


Thanks, take care

Jan Stefanovic
IT Systems Administrator

p | (604) 299-0458 x268
e | jstefano...@tantalus.com<mailto:jstefano...@tantalus.com>
u | www.tantalus.com

[Tantalus Logo]
CONFIDENTIALITY NOTICE.  This documentation, including any attachments, 
transmitted by electronic mail is intended for the use of the individual to 
whom or the entity to which it is addressed, and may contain information which 
is proprietary, confidential, privileged and/or protected from disclosure by 
applicable laws. Confidentiality and privilege are not lost by this 
documentation having been sent to the wrong electronic mail address. If you are 
not the intended recipient (or the person responsible for delivering thereto) 
please immediately notify the sender and destroy this documentation and all 
copies (in any form and media); and note that any distribution, reproduction or 
other use of this documentation is strictly prohibited and may violate public 
and intellectual property laws.  Thank you.

From: Wanderlei Huttel [mailto:wanderleihut...@gmail.com]
Sent: Thursday, February 23, 2017 12:11 PM
To: Jan Stefanovic
Cc: bacula-users@lists.sourceforge.net
Subject: Re: [Bacula-users] Bacula ssh tunnel - not working

Could you post some information?
- Job configuration
- Job log of job with problem (list joblog jobid=XXX)
- Script that you are using
- Permission from script (ls -lh /..../script.sh) (your script)

Best Regards

Wanderlei Hüttel
http://www.huttel.com.br

2017-02-23 16:59 GMT-03:00 Jan Stefanovic 
<jstefano...@tantalus.com<mailto:jstefano...@tantalus.com>>:
Thank you Wanderlei!

I am used to run ClientRunbefore job for SQL dumps and it works great, but 
somehow
this RunBeforeJob is not doing it for me, as I can see the ssh channel is not 
up.
When running script manually, ssh channel is up on both sides…

but when calling it from bconsole, no luck…
Really need to see someone’s working scenario


Thanks, take care

Jan Stefanovic
IT Systems Administrator

p | (604) 299-0458 x268<tel:(604)%20299-0458>
e | jstefano...@tantalus.com<mailto:jstefano...@tantalus.com>
u | www.tantalus.com<http://www.tantalus.com>

[Tantalus Logo]
CONFIDENTIALITY NOTICE.  This documentation, including any attachments, 
transmitted by electronic mail is intended for the use of the individual to 
whom or the entity to which it is addressed, and may contain information which 
is proprietary, confidential, privileged and/or protected from disclosure by 
applicable laws. Confidentiality and privilege are not lost by this 
documentation having been sent to the wrong electronic mail address. If you are 
not the intended recipient (or the person responsible for delivering thereto) 
please immediately notify the sender and destroy this documentation and all 
copies (in any form and media); and note that any distribution, reproduction or 
other use of this documentation is strictly prohibited and may violate public 
and intellectual property laws.  Thank you.

From: Wanderlei Huttel 
[mailto:wanderleihut...@gmail.com<mailto:wanderleihut...@gmail.com>]
Sent: Thursday, February 23, 2017 11:02 AM
To: Dimitri Maziuk
Cc: Jan Stefanovic; 
bacula-users@lists.sourceforge.net<mailto:bacula-users@lists.sourceforge.net>
Subject: Re: [Bacula-users] Bacula ssh tunnel - not working

Hello Stefanovic

The commands to run scripts on server is "RunBeforeJob" or "RunAfterJob"


Best Regards

Wanderlei Hüttel
http://www.huttel.com.br

2017-02-23 15:49 GMT-03:00 Dimitri Maziuk 
<dmaz...@bmrb.wisc.edu<mailto:dmaz...@bmrb.wisc.edu>>:
On 02/23/2017 12:32 PM, Jan Stefanovic wrote:
> Thanks Dimitri!!!
>
> How about the client's bacula-fd.conf?
> can you cut/paste some info?
>
> as well, how do you run the script to create ssh tunnel?
> Is backup job running it or you do it manually?

I don't, that was just off the top of my head.

You'd have to ask somebody (Kern?) exactly how it works: will RunScript
run before the director tries to contact the client or after -- if it's
the latter, it won't work.

--
Dimitri Maziuk
Programmer/sysadmin
BioMagResBank, UW-Madison -- http://www.bmrb.wisc.edu

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net<mailto:Bacula-users@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/bacula-users


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to