Changes between Version 1 and Version 2 of GIS/OpenStreetMap
- Timestamp:
- 12/06/12 12:33:30 (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
GIS/OpenStreetMap
v1 v2 82 82 ALTER TABLE ways OWNER TO osm; 83 83 \q 84 exit 84 85 85 cd planet86 wget http://download.geofabrik.de/openstreetmap/africa.osm. bz287 bzcat /home/osm/planet/africa.osm.bz2 | /home/osm/osmosis/bin/osmosis --read-xml file=/dev/stdin--tf accept-nodes amenity=hospital,place_of_worship,school --tf accept-ways amenity=hospital,place_of_worship,school --write-pbf /home/osm/planet/eurosha.osm.pbf86 cd /home/osm/planet 87 wget http://download.geofabrik.de/openstreetmap/africa.osm.pbf 88 /home/osm/osmosis/bin/osmosis --read-pbf /home/osm/planet/africa.osm.pbf --tf accept-nodes amenity=hospital,place_of_worship,school --tf accept-ways amenity=hospital,place_of_worship,school --write-pbf /home/osm/planet/eurosha.osm.pbf 88 89 su postgres 89 90 /home/osm/osmosis/bin/osmosis --read-pbf /home/osm/planet/eurosha.osm.pbf --write-pgsql database=osm user=osm password=planet … … 91 92 cd /home/osm/planet/replication 92 93 /home/osm/osmosis/bin/osmosis --rrii 94 sudo -H -u postgres psql -d osm -c "select max(tstamp) from nodes"; 93 95 http://toolserver.org/~mazder/replicate-sequences/ 94 ls -l /home/osm/planet/africa.osm.bz2 95 vi state.txt 96 Put timestamp into site, select hourly 97 vim state.txt 98 # paste in contents from website 99 vim configuration.txt 100 baseUrl=http://planet.openstreetmap.org/replication/hour 96 101 97 102 /home/osm/osmosis/bin/osmosis --rri workingDirectory=/home/osm/planet/replication/ --simc --read-pbf /home/osm/planet/eurosha.osm.pbf --ac --tf accept-nodes amenity=hospital,place_of_worship,school --tf accept-ways amenity=hospital,place_of_worship,school --tf reject-relations --write-pbf /home/osm/planet/eurosha-new.osm.pbf … … 109 114 /home/osm/osmosis/bin/osmosis --rri workingDirectory=/home/osm/planet/replication/ --simc --read-pbf /home/osm/planet/eurosha.osm.pbf --ac --tf accept-nodes amenity=hospital,place_of_worship,school --tf accept-ways amenity=hospital,place_of_worship,school --tf reject-relations --write-pbf /home/osm/planet/eurosha-new.osm.pbf 110 115 /home/osm/osmosis/bin/osmosis --read-pbf /home/osm/planet/eurosha-new.osm.pbf --read-pbf /home/osm/planet/eurosha.osm.pbf --dc --write-pgsql-change database=osm user=osm password=planet 116 mv /home/osm/planet/eurosha-new.osm.pbf /home/osm/planet/eurosha.osm.pbf 111 117 fi 112 118 113 119 chmod 0755 /home/osm/replicate.sh 114 120 vim /etc/crontab 115 1 3* * * root /home/osm/replicate.sh121 1 * * * * root /home/osm/replicate.sh 116 122 }}} 117 123 118 124 Monitor: 119 125 {{{ 126 su postgres 120 127 psql -d osm -c "select max(tstamp) from nodes"; 121 128 }}}