>>>>> On Fri, 17 Aug 2007 13:51:34 -0400, Dan Langille said: > > Has anyone encountered this situation? The pwd of the > RunBeforeScript is the directory into which the source code was > unpacked. > > To reproduce, use this RunBeforeScript: > > #!/bin/sin > echo $PWD > > The output is: > > 17-Aug 13:28 ducky-dir: BeforeJob: run command > "/home/dan/bin/test_pwd" > 17-Aug 13:28 ducky-dir: BeforeJob: /home/dan/src/bacula-server > > FYI, /home/dan/src/bacula-server is where I built this particular > installation (my development box). The issue is: the build directory > isn't necessarily going to be around at script run time. > > I also tested ClientRunBeforeScript: > > *mes > 17-Aug 13:50 ngaio-fd: ClientRunBeforeJob: run command > "/home/dan/bin/test_pwd" > 17-Aug 13:50 ngaio-fd: ClientRunBeforeJob: > * > > Quite a different result. > > This situation came to my attention when someone mentioned it on IRC. > He'll be following up here later.
Yes, I can confirm it, but I don't think it is a new problem. The PWD is actually the directory where you started the daemons. Although there is a call to chdir("/") in src/lib/daemon.c, it is not used because DEBUG=1 is defined in src/version.h! __Martin ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users