DOKK / manpages / debian 12 / tirex / tirex-tiledir-check.1.en
TIREX-TILEDIR-CHECK(1) User Contributed Perl Documentation TIREX-TILEDIR-CHECK(1)

tirex-tiledir-check - check tile dir

tirex-tiledir-check [OPTIONS] MAP

Display help message.
Use the config directory DIR instead of /etc/tirex.
Write list of tiles to FILE. See below for format.
Write stats about tiles to FILE. See below for format.
Start processing at min. zoom level i (default=0)
Stop processing at max. zoom level i (default=19)

Walks recursively through the tiles directory for the given MAP and checks for wrong directory or file names or files that can't be accessed. If problems are found, messages are written to STDERR.

When the --list and/or --stats options are given, it outputs information about each tile and/or generates statistics, respectively. The list and stats are written to the filenames given, if you give '-' as the filename STDOUT is used. You can only use STDOUT for either the list file or the stats file.

Caution: This command will go through all metatiles on your disk and stat each file. On a lightly loaded machine with lots of RAM this can go pretty quick, but under high IO loads it might take a long time. Take this into account if you want to run it regularly from cron or similar.

The list file is in CSV format with one line per metatile. The fields are:

Age of metatile in seconds.
Size in bytes of the metatile.
Number of blocks used for this metatile.
Description of metatile. Format: map=foo x=8 y=0 z=10

This data can be read with other programs to create statistics etc.

The stats file is in JSON format. It contains a hash with the names of all maps as keys and a list of zoom levels as their values. For each zoom level there is a nested hash containing the statistics:

The sumage, sumblocks, and sumsize values can be divided by count to get the average.

This file can be displayed on a human readable format with the Program tirex-tiledir-stat. It is also read by several Munin plugins.

/etc/tirex/tirex.conf
The configuration file.

Returns 0 if no errors were found or 1 if there were errors. If there were errors parsing the command line 2 is returned.

<http://wiki.openstreetmap.org/wiki/Tirex>

Frederik Ramm <frederik.ramm@geofabrik.de>, Jochen Topf <jochen.topf@geofabrik.de> and possibly others.

2023-04-11 perl v5.36.0