python - I'm trying to install skytools in order to migrate a DB to an Amazon RDS, but I'm getting an error -
setup details: 1x ec2 running ubuntu 14.04 postgres 9.3, 1x rds running postgres 9.3
i trying move postgres database have on ec2 onto rds. using londiste, recommended aws migrating databases minimal downtime. specifically, using londiste/skytools 2.1.13, because londiste3 requires superuser privileges on both systems.
i have tried installing skytools both via zip website , via apt-get (both 2.1.13). have installed believe of dependencies: postgres,libpq-dev, postgresql-server-dev-9.3, pip, , psycopg2.
regardless, whenever try use skytools commands, following error:
traceback (most recent call last):
file "/usr/local/bin/pgqadm.py", line 9, in pgq.ticker import smartticker file "/usr/local/lib/python2.7/dist-packages/pgq/init.py", line 6, inimport pgq.consumer file "/usr/local/lib/python2.7/dist-packages/pgq/consumer.py", line 6, in pgq.baseconsumer import baseconsumer, basebatchwalker file "/usr/local/lib/python2.7/dist-packages/pgq/baseconsumer.py", line 75,
in class baseconsumer(skytools.dbscript): file "/usr/local/lib/python2.7/dist-packages/skytools/apipkg.py", line 114,
in __makeattr result = importobj(modpath, attrname) file "/usr/local/lib/python2.7/dist-packages/skytools/apipkg.py", line 37,
in importobj module = import(modpath, none, none, ['doc']) file "/usr/local/lib/python2.7/dist-packages/skytools/scripting.py", line 23,
in default_skylog = skytools.installer_config.skylog
attributeerror: 'module' object has no attribute 'skylog'
am missing dependency? (skylog seems part of skytools, i've concluded it's not that.) has else hit issue? (there don't seem google results error.) thanks!
tl;dr:
make sure you're running pgqadm.py
in local skytools-2.x.y
installation directory, eg: ./python/pgqadm.py ticker.ini install
this can problem if have installed skytools 3.x, may come first in path
.
background
i ran same issue. have same use case (migrating pg->rds), , followed same recommendation aws documentation.
i had installed skytools 3.x before noticing requires superuser privileges on would-be replica. which pgqadm.py
returns /usr/bin/pgqadm.py
, artifact of abandoned skytools 3.x installation.
i became suspicious of version conflict when went skytools source repository looking instances of skylog
. first result here: https://github.com/pgq/skytools-legacy/blob/11afc5210a92d4a2ccf701e4f92138488c31a3cb/python/skytools/installer_config.py.in
however, realized repository tracking latest 3.x release. switched apparent 2.1.x branch, , skylog
found, expected:
fully-qualifying path pgqadm.py
resolves issue in case.
Comments
Post a Comment