Hi,
We already have North America Planet OSM installed successfully and we are properly getting Speed limits when we hit the lat/longs.
However, we wanted to have South America Planet OSM also to be installed within the same instance.
The following errors occurred while doing the same:
compute_geometry: Way 22573975 used in relation 3725897 not found.
The script what we used is below:
#!/bin/bash
#set -euo pipefail
set -o xtrace
osmVersion=0.7.54
EXEC_DIR=~/osm-3s/v$osmVersion/execdir
DB_DIR=~/osm-3s/v$osmVersion/dbdir
REPLICATE_DIR=~/osm-3s/v$osmVersion/replicatedir
region=us-east-1
aws_access_key_id=Confidential(my own key)
aws_secret_access_key=Confidential(my own key)
overpass_aws_access_key_id=Confidential(my own key)
overpass_aws_secret_access_key=Confidential(my own key)
for mail job
smtppassword=Confidential(my own key)
private ssh key for git
privateSSHKey=Confidential(my own key)
-----END RSA PRIVATE KEY-----
EOF
)"
public ssh key for git
publicSSHKey=Confidential(my own key)
configuration setup for awscli access
==========================================
setup command line access to aws
source secrets.sh
mkdir -p ~/.aws
cat < ~/.aws/credentials
[default]
aws_access_key_id=$aws_access_key_id
aws_secret_access_key=$aws_secret_access_key
BARBAR
cat < ~/.aws/config
[default]
output=json
region=$region
FOOBAR
sudo apt-get update
#sudo apt-get -y upgrade
sudo apt-get -y install python
sudo apt-get -y install python-pip
sudo apt-get -y install supervisor
sudo pip install awscli
#================================================
sudo apt-get update
sudo apt-get -y install g++ make expat libexpat1-dev zlib1g-dev
sudo apt-get -y install apache2
sudo a2enmod cgi
wget http://dev.overpass-api.de/releases/osm-3s_v$osmVersion.tar.gz
tar -zxvf osm-3s_v$osmVersion.tar.gz
cd osm-3s_v$osmVersion
./configure CXXFLAGS=“-O2” --prefix=$EXEC_DIR
make install
#download planetfile india
PLANET_FILE=~/argentina-latest.osm.bz2
wget -O $PLANET_FILE http://download.geofabrik.de/south-america-latest.osm.bz2
#sudo mv asia-latest.osm.bz2 ./…/
#populate data
$EXEC_DIR/bin/init_osm3s.sh $PLANET_FILE $DB_DIR $EXEC_DIR
cd
cat < ~/overpassrunner.sh
#!/bin/bash
export DB_DIR=~/osm-3s/v0.7.54/dbdir
export EXEC_DIR=~/osm-3s/v0.7.54/execdir
export PLANET_FILE=~/south-america-latest.osm.bz2
sudo rm -f /dev/shm/osm3s_v0.7.54_osm_base
sudo rm -f /home/ubuntu/osm-3s/v0.7.54/dbdir/osm3s_v0.7.54_osm_base
$EXEC_DIR/bin/dispatcher --osm-base --db-dir=$DB_DIR
BARBBB
cat < ~/overpassdispatcher.conf
[program:overpassdispatcher]
command=/home/ubuntu/overpassrunner.sh
autostart=true
autorestart=true
user=ubuntu
stdout_logfile=/var/log/overpassrunner.log
redirect_stderr=true
BARBAB
cat < ~/default.conf
<VirtualHost *:80>
ServerAdmin webmaster@localhost
#ExtFilterDefine gzip mode=output cmd=/bin/gzip
DocumentRoot /var/www/html/
# This directive indicates that whenever someone types [http://www.mydomain.com/api/](http://www.mydomain.com/api/)
# Apache2 should refer to what is in the local directory [YOUR_EXEC_DIR]/cgi-bin/
ScriptAlias /api/ /home/ubuntu/osm-3s/v0.7.54/execdir/cgi-bin/
# This specifies some directives specific to the directory: [YOUR_EXEC_DIR]/cgi-bin/
<Directory "/home/ubuntu/osm-3s/v0.7.54/execdir/cgi-bin/">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
# For Apache 2.4:
# Order allow,deny
# For Apache > 2.4:
Require all granted
#SetOutputFilter gzip
#Header set Content-Encoding gzip
</Directory>
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit, alert, emerg
LogLevel warn
CustomLog /var/log/apache2/access.log combined
BBRBAB
#supervisor configure
sudo cp ~/overpassdispatcher.conf /etc/supervisor/conf.d/
sudo supervisorctl start overpassdispatcher
#apache configure
sudo cp ~/default.conf /etc/apache2/sites-available/
sudo /etc/init.d/apache2 restart