-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Richard Bos wrote:
> Op vrijdag 1 december 2006 08:56, schreef Marcus Meissner:
>>> Maybe one of those talented persons who designed repomd should have a
>>> look at /var/lib/locatedb. It's able to store equivalent information
>>> about 2 Linuxes, 1 Windows system and a lot of user files in just 2.5MB.
>>> Thanks to not using XML.
>> Yeah, I saw this too and thought about at least using some kind of
>> directory prefix or similar handling.
>>
>> XML really makes it easy to be stupid in data design :/
> 
> What about md5sum-ming the filelist, and use the md5sum as key?  If a new 
> version of a package is released with the same filelist only the md5sum needs 
> to be transferred.  For big packages the compression might be around 100% ;)

Already done.

For yast2 repositories, package managers look at the serial number in
media.1/media (the 2nd line), so only the media.1/media file is
downloaded (very small, just a few bytes (22 bytes in my repository)).
I use a timestamp for that.

For rpm-md repositories, package managers look at the
repodata/repomd.xml file.
It has SHA checksums and timestamps of the other files (filelists.xml.gz
and primary.xml.gz), e.g.:
- ---8<------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<repomd xmlns="http://linux.duke.edu/metadata/repo";>
  <data type="filelists">
    <location href="repodata/filelists.xml.gz"/>
    <checksum type="sha">...</checksum>
    <timestamp>1165003298</timestamp>
    <open-checksum type="sha">...</open-checksum>
  </data>
  <data type="primary">
    <location href="repodata/primary.xml.gz"/>
    <checksum type="sha">...</checksum>
    <timestamp>1165003298</timestamp>
    <open-checksum type="sha">...</open-checksum>
  </data>
</repomd>
- ---8<------------------------------------------------------------

That file is somewhat larger as for yast2 repositories, but still very
small (951 bytes in my repository).

yast2 and smart look at the serial numbers/timestamps of those files and
compare it with the repository metadata they downloaded the last time.
They will download the full metadata if and only if the remote
serial/timestamp differs.

cheers
- --
  -o) Pascal Bleser     http://linux01.gwdg.de/~pbleser/
  /\\ <[EMAIL PROTECTED]>       <[EMAIL PROTECTED]>
 _\_v The more things change, the more they stay insane.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)

iD8DBQFFcL3Sr3NMWliFcXcRAiqXAJ9l5t7iClRQxzoO581P4nJb7idRZwCgo35P
ANBcC9X3wA6HVj04BX3zUc8=
=DQx6
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to