Victor McAllister wrote:
> Brent Gardner wrote:
>> I have a machine running Bering-uClibc v3.0.2.  The machine runs 
>> dnscache to provide name resolution for a group of machines.  The 
>> machine also runs tinydns to provide DNS information about a local 
>> domain called corp.local.
>>
>> In order to get dnscache to serve information about the corp.local 
>> domain I have to enter these commands after every boot:
>>
>>   echo 127.0.0.1 > /etc/dnscache/root/servers/local
>>   svi dnscache restart
>>
>>
>> I noticed there's a file called @ in /etc/dnscache/root/servers.  This 
>> file exists after every reboot.  The file is not listed in 
>> /var/lib/lrpkg/dnscache.list although /etc/dnscache/root/servers is. 
>> I'm not fully familiar with how the backup process works in LEAF 
>> Bering-uClibc.  I don't know if the /etc/dnscache/root/servers item in 
>> dnscache.list means 'backup the object called 
>> /etc/dnscache/root/servers' or 'backup the object and everything it 
>> contains'.  If the latter then I'm curious as to why my 
>> /etc/dnscache/root/servers/local file isn't there after a reboot.  If 
>> it put /etc/dnscache/root/servers/local in dnscache.list the file 
>> still does not get backed up.
>>
>> If I dissect the configdb.lrp or dnscache.lrp files the @ file does 
>> not exist in either of them so I suspect it's being generated by 
>> dnscache or daemontools after booting.  I'm still researching that, 
>> but if this is the case does anyone know how I can cause an arbitrary 
>> file to be auto-generated in /etc/dnscache/root/servers with specific 
>> content?
>>
>> The contents of /etc/dnscache/root/servers/@ match the contents of 
>> /etc/dnscache/env/DNS1
>>
>>
>> Thanks.
>>
>> Brent Gardner
>>
>>   
> LEAF file system is in RAM. The boot media is only used for loading up 
> the RAM and for saving changes in configuration.
> 

Right.  This is why I was looking at the contents of the .lrp files.  I 
wanted to see what the backup system was actually saving.

The @ file and my local file under /etc/dnscache/root/servers do not 
exist in the configdb.lrp or dnscache.lrp files after I run 'Save 
configuration' from the main menu.  The @ file exists after a reboot but 
any other file I put in /etc/dnscache/root/servers does not survive a 
reboot.  Research indicates that the @ file is generated by a script at 
boot and probably whenever 'svi dnscache restart' is executed.  It 
appears to be based on the contents of /etc/dnscache/env/DNS1.

It also appears that there is no way, using the tools that currently 
ship in the dnscache.lrp, daemontools.lrp, or tinydns.lrp packages, to 
get dnscache to automatically reconstitute other files under 
/etc/dnscache/root/servers at boot or restart as it does with the @ 
file.  I will have to do as you suggest and script it.

> The easiest way to keep specific scripts or files through a reboot is to 
> add them to local.lrp.
> You can list files in any directory, AFAIK.
> for example my /var/lib/lrpkg/local.local lists three files I put in 
> /usr/sbin.
> They are saved in local.lrp and restored during reboot as long as 
> local.lrp is in the load list.
> 
> var/lib/lrpkg/local.local
> /usr/sbin/rm-ide
> /usr/sbin/load-ide
> /usr/sbin/fixclk
> 
> 

So does the backup system look at *.list or *.local to determine what 
gets backed up?


Brent Gardner


------------------------------------------------------------------------------
------------------------------------------------------------------------
leaf-user mailing list: leaf-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/leaf-user
Support Request -- http://leaf-project.org/

Reply via email to