[Tilesathome] [PATCH] Don't rename uploaded files to ${file}_uploaded if using a common upload directory

Dirk-Lüder Kreie osm-list at deelkar.net
Mon Oct 27 18:23:51 GMT 2008


Ævar Arnfjörð Bjarmason schrieb:
> I run a t at h setup with multiple clients generating tilesets and a
> single uploader, the typical client configuration is:
> 
> WorkingDirectory = /home/avar/src/tah/work/tah-3
> UploadToDirectory = 1
> UploadTargetDirectory = /home/avar/src/tah/uploadable
> DeleteZipFilesAfterUpload=0



> And the upload client is:
> 
> WorkingDirectory = /home/avar/src/tah/work/tah-upload

This should be the same directory as mentioned above
i.e. /home/avar/src/tah/uploadable

> UploadToDirectory = 0
> ForkForUpload = 0
> DeleteZipFilesAfterUpload=0
> 

And not:
> The uploadable directory in each client's working directory is then
> symlinked to a central uploadable directory everyone uses:
> 
> $ file work/tah-{3,upload}/uploadable
> work/tah-3/uploadable:      symbolic link to `/home/avar/src/tah/uploadable'
> work/tah-upload/uploadable: symbolic link to `/home/avar/src/tah/uploadable'

This will not work as you would expect. It creates all sorts of issues 
with locking, incomplete zip files and so forth on platforms that don't 
implement locking.

> Recently this setup broke due to changes in SVN (I don't know what
> change specifically) and all the non-uploading clients started
> dropping zip files with the _uploaded suffix in their upload directory
> even though they weren't uploading them. To get them uploaded I needed
> to run:


>     $ rename 's/_uploaded$//g' *
> 
> And then run the upload client.

The problem with your setup being that the clients saw each other's zip 
files and tried to upload to the same directory the files were already 
in, creating _uploaded files in the process the next uploader would not 
overwrite.



-- 

Dirk-Lüder "Deelkar" Kreie
Bremen - 53.0952°N 8.8652°E

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 260 bytes
Desc: OpenPGP digital signature
URL: <http://lists.openstreetmap.org/pipermail/tilesathome/attachments/20081027/0c929030/attachment.pgp>


More information about the Tilesathome mailing list