recursive fcopy for the complete files directory?

Henning Sprang henning_fai at gmx.de
Thu Jun 2 10:33:28 CEST 2005


On Thu, 2005-06-02 at 08:51 +0200, Henning Glawe wrote:
> [...]
> thats what fcopy's recursion code is for: I am calling 
> 
> fcopy -i -r .
> 
> in scripts/DEFAULT/S01recursive_fcopy.sh, that means at the really first
> scripts step (the -i sets the exitcode always to 0, because if you are doing
> a recursive fcopy, the probability of some not-matching files is high).
> 
> I am using this construct for at least 3 years now, so it should be pretty
> safe.
> 


Cool, will try that later. Thanks!

Another thing comes to my mind that I wanted to do some time ago, but I
don't remember the correct example back then - maybe the FAI config is a
good one:

For some services, there is not just one file, but a directory with
multiple files in it which belong together as configuration.

Now, if I have for example two different fai configs, say one for a
sarge install server, one for an ubuntu install server, but I want them
to reside on the installed machine in /etc/fai, assuming I never want an
install server that does them both together (which I want finally), I
have to make a setup like this in files:

/files/etc/fai/
	fai.conf/
		UBUNTU-FAI-SERVER
		FAI-SERVER
	make-fai-nfsroot.conf/
		UBUNTU-FAI-SERVER
		FAI-SERVER
	menu-lst/
		UBUNTU-FAI-SERVER
		FAI-SERVER
	sources.list/
		UBUNTU-FAI-SERVER
		FAI-SERVER

Which is somehow ugly (I often don't like the idea anyway of having
these files named as classes, but when i thought about having another
intermediate directory with the class name and put the file in it, I
didn't like that also, so it seems the way it is is the one that sucks
less). 
I'd like to able to just manage a whole
directory of files belonging together to one useful configuration
in a single directory like:

/files/etc/fai/UBUNTU-FAI-SERVER/
				fai.conf
				make-fai-nfsroot.conf
				menu-lst
				sources.list

/files/etc/fai/FAI-SERVER/	
			fai.conf
			make-fai-nfsroot.conf
			menu-lst
			sources.list

Would it be a bad idea if I'd add an option to fcopy that could handle
this? Hmm, I guess it could work and be nice, but it might interfere
with the "-r" when I use it as Henning does...

P.S: I know about ftar, but I wanna do version control - if I put
*.tar's in the files dir, there's no easy way to get diff's from the
text files inside.

Henning





More information about the linux-fai mailing list