Bacula-users

[Bacula-users] Variables in bacula

2010-08-02 13:20:15
Subject: [Bacula-users] Variables in bacula
From: Daniel beas <beasdaniel AT hotmail DOT com>
To: <bacula-users AT lists.sourceforge DOT net>
Date: Mon, 2 Aug 2010 17:17:47 +0000

Hi to all.
I have a dsl connection with a dynamic ip and actually i'm resolving it with a subdomain from no-ip but sometimes i get this error
gethostbyname() for host "mydomain.zapto.org" failed: ERR=Non-authoritative for host not found, or ServerFail.
So i'm trying to change the way i get the ip for the Storage daemon by getting my public ip with a shell script (ran before the job) and putting it in a variable.

IP=`wget -q -O - checkip.dyndns.org|sed -e 's/.*Current IP Address://' -e 's/<.*$//'`

The problem i have is how can bacula-dir.conf get the $IP variable?

i tried just this way but it doesn work
Storage {
   Name = sxxx
   Address = $IP
   SDPort = 9103
   Password = "SHexZ8mwXW4YkbJgu2HpJloZfkuT5Pj5yyWLiPxBhoZy"
   device = dxxx
   Media type = File
}

and then tried using brackets this way
Storage {
   Name = sxxx
   Address = {$IP}
   SDPort = 9103
   Password = "SHexZ8mwXW4YkbJgu2HpJloZfkuT5Pj5yyWLiPxBhoZy"
   device = dxxx
   Media type = File
}
but looks like bacula thinks there finish the storage resource

Thanks in advance
Daniel Beas Enriquez

------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users
<Prev in Thread] Current Thread [Next in Thread>