[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Archive Restructuring - Package Pool



Rob Browning <rlb@cs.utexas.edu>:
>Basically, what I'd like to do is to take mirror or fmirror and modify
>it to create a "debian-mirror" program.  [...]
>
>Then you take this list, scan it, find (for example) any symlinks that
>point outside the given set of files, flatten those (and only those),
>and then hand the modified list back to mirror.  [...]
>
>At the minimum, hacking mirror or fmirror to be able to flatten only
>enough symlinks to give you a consistent mirror would be (IMO) a great
>feature, and would solve 90% of the problem.

You could do this at the server instead (assuming you're mirroring via
FTP).  Since an FTP client knows nothing about the server's filesystem
apart from the response to its "LIST -lR" command, returning something
different from that command would do the trick.

mirror (and maybe fmirror?) is able to read the "LIST -lR" information
from a file on the server instead of issuing the command itself; in
this case, the FTP server wouldn't even need changing -- just create
files called "ls-lR.no-crypto" and "ls-lR.no-violence".  Then the
mirror picks up that file and mirrors according to its contents...

Now there's just the little problem of how to create that file.  I'll
try this myself over the weekend, but what I'm thinking of is  a
filter, and a bunch of control files.  The filter takes the output of
"ls -lR" and fixes it up according to the control file.  To flatten a
symlink, it would remove the " -> " and everything after it, and also
substitute the target file's size, date, permissions etc. for the
symlink's.  It should be more straightforward to exclude particular
files or whole trees.

This approach has the advantage of allowing the mirrors to continue
using their favourite unhacked mirror clients, no need to change the
server either, but just fooling an existing option into doing what we
want.

Now, I'm sure there must be a fatal flaw with this idea (there always
is...)  So, where is it?

-- 
Charles Briscoe-Smith
White pages entry, with PGP key: <URL:http://alethea.ukc.ac.uk/wp?95cpb4>
PGP public keyprint: 74 68 AB 2E 1C 60 22 94  B8 21 2D 01 DE 66 13 E2


--  
To UNSUBSCRIBE, email to debian-devel-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org


Reply to: