aboutsummaryrefslogtreecommitdiff
path: root/sources
diff options
context:
space:
mode:
Diffstat (limited to 'sources')
-rw-r--r--sources/db/README5
-rwxr-xr-xsources/db/osmium_tagstatsbin128430 -> 0 bytes
-rwxr-xr-xsources/db/tagstatsbin0 -> 299559 bytes
-rwxr-xr-xsources/db/update.sh15
4 files changed, 17 insertions, 3 deletions
diff --git a/sources/db/README b/sources/db/README
new file mode 100644
index 0000000..a9e2929
--- /dev/null
+++ b/sources/db/README
@@ -0,0 +1,5 @@
+
+The tagstats binary in this directory is build for Ubuntu Maverick (10.10). It
+might not work on your system. If not, you have to go to the ../../tagstats
+directory and build your own version.
+
diff --git a/sources/db/osmium_tagstats b/sources/db/osmium_tagstats
deleted file mode 100755
index ab5e21e..0000000
--- a/sources/db/osmium_tagstats
+++ /dev/null
Binary files differ
diff --git a/sources/db/tagstats b/sources/db/tagstats
new file mode 100755
index 0000000..756e9e2
--- /dev/null
+++ b/sources/db/tagstats
Binary files differ
diff --git a/sources/db/update.sh b/sources/db/update.sh
index 56a7652..5adf383 100755
--- a/sources/db/update.sh
+++ b/sources/db/update.sh
@@ -2,20 +2,28 @@
#
# Taginfo source: DB
#
-# update.sh DIR
+# update.sh DIR [PLANETFILE]
#
set -e
+# uncomment this if you want to get a core file in case tagstats crashes
+#ulimit -c 1000000000
+
DIR=$1
+PLANETFILE=$2
DATECMD='date +%Y-%m-%dT%H:%M:%S'
if [ "x" = "x$DIR" ]; then
- echo "Usage: update.sh DIR"
+ echo "Usage: update.sh DIR [PLANETFILE]"
exit 1
fi
+if [ "x" = "x$PLANETFILE" ]; then
+ PLANETFILE=/osm/planet/var/current-planet.osm.pbf
+fi
+
echo "`$DATECMD` Start db..."
DATABASE=$DIR/taginfo-db.db
@@ -32,7 +40,8 @@ sqlite3 $DATABASE <pre.sql
echo "`$DATECMD` Running count... "
HERE=`pwd`
cd $DIR
-bzcat $DIR/planet.osm.bz2 | $HERE/osmium_tagstats -
+#valgrind --leak-check=full --show-reachable=yes $HERE/tagstats $PLANETFILE >valgrind.log 2>&1
+$HERE/tagstats $PLANETFILE
cd $HERE
echo "`$DATECMD` Running update_characters... "