[Tilecache] Ubuntu, .deb, and sudo tilecache_seed
Christopher Schmidt
crschmidt at metacarta.com
Thu Apr 17 17:27:26 EDT 2008
On Thu, Apr 17, 2008 at 03:59:43PM -0500, Scot Wilcoxon wrote:
> I installed using the .deb file on Ubuntu. Got an error about not finding
> Image; apparently the dependencies didn't mention the Python Imaging
> Library so had to manually install the PIL package.
PIL is *not* required to use TileCache. It *is* a recommends of the
package: this means it isn't required, but it is recommended.
python-mapnik and python-mapscript are also suggests, meaning that they
might be useful. dpkg --info can let you see this information.
> Once I got some tiles appearing I tried to tilecache_seed. Got an
> error about a lock file; apparently tilecache_seed does not merely
> issue http requests but is tinkering in the cache files and needs
> access permissions.
Yeah, this is a recent change. This is a performance optimization: when
pre-caching against existing data, this can be orders of magnitude
faster.
> This being on Ubuntu, tried using sudo to run tilecache_seed as root.
You should run as www-data instead: the files are all owned by that
user. Alternatively, there are options in the Disk Cache about changing
the permissions of the files so that they're group owned or whatever. I
don't use it; I just su to www-data when I need to pre-cache.
> Nope, looks like sudo hung waiting for a password, which it won't get due
> to being wrapped in nohup and redirected output (so it can run without a
> terminal).
In general, I use screen: my experience is typically that backends blow
up on me and I like to be able to recover the failures.
> I can create an incantation to run tilecache_seed within the
> proper environment, but maybe there should be some instructions of what
> the creators think is the proper way to seed. If root is required then it
> should be mentioned; if root is not required then the .deb should create
> /tmp/tilecache with different permissions.
Ah, but the .deb doesn't create /tmp/tilecache at all: You did, when you
browsed your tiles :) However, you're right that the documentation
should be more specific that the cache dir permissions issue isn't well
covered: the relatively 'late' change of tilecache_seed isn't covered
well at all, mostly because I still keep planning to rewrite it to clean
it up.
Regards,
--
Christopher Schmidt
MetaCarta
More information about the Tilecache
mailing list