Question: Moving a Galaxy Docker instance from one server to another
1
gravatar for machinelearner
16 months ago by
machinelearner10 wrote:

Hi everyone!

Is there a way to move one instance of Docker Galaxy over from one server to another?

Here is the general timeline of events we have tried:

  1. Pull the stable base image
  2. Run the base image to create a container
  3. Made changes in the container (such as installing conda in the container)
  4. Commit the container to make a new image.
  5. Save the new image as a tar file on the first server.
  6. Load the new image into the other server.

After doing something along the lines of the described steps above, running the new image on the second server does not seem to work. Using the /usr/bin/startup script results in the following error:

Checking if database is up and running
Traceback (most recent call last):
  File "/usr/local/bin/check_database.py", line 25, in <module>
    query.count()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 2980, in count
    return self.from_self(col).scalar()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 2749, in scalar
    ret = self.one()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 2718, in one
    ret = list(self)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 2761, in __iter__
    return self._execute_and_instances(context)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 2774, in _execute_and_instances
    close_with_result=True)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 2765, in _connection_from_session
    **kw)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/session.py", line 893, in connection
    execution_options=execution_options)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/orm/session.py", line 900, in _connection_for_bind
    conn = engine.contextual_connect(**kw)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 2039, in contextual_connect
    self._wrap_pool_connect(self.pool.connect, None),
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 2078, in _wrap_pool_connect
    e, dialect, self)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1405, in _handle_dbapi_exception_noconnection
    exc_info
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/util/compat.py", line 202, in raise_from_cause
    reraise(type(exception), exception, tb=exc_tb, cause=cause)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 2074, in _wrap_pool_connect
    return fn()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 376, in connect
    return _ConnectionFairy._checkout(self)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 713, in _checkout
    fairy = _ConnectionRecord.checkout(pool)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 480, in checkout
    rec = pool._do_get()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 1060, in _do_get
    self._dec_overflow()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/util/langhelpers.py", line 60, in __exit__
    compat.reraise(exc_type, exc_value, exc_tb)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 1057, in _do_get
    return self._create_connection()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 323, in _create_connection
    return _ConnectionRecord(self)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 449, in __init__
    self.connection = self.__connect()
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/pool.py", line 607, in __connect
    connection = self.__pool._invoke_creator(self)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/engine/strategies.py", line 97, in connect
    return dialect.connect(*cargs, **cparams)
  File "/galaxy_venv/local/lib/python2.7/site-packages/sqlalchemy/engine/default.py", line 385, in connect
    return self.dbapi.connect(*cargs, **cparams)
  File "/galaxy_venv/local/lib/python2.7/site-packages/psycopg2/__init__.py", line 164, in connect
    conn = _connect(dsn, connection_factory=connection_factory, async=async)
sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) could not connect to server: Connection refused
    Is the server running on host "localhost" (::1) and accepting
    TCP/IP connections on port 5432?
could not connect to server: Connection refused
    Is the server running on host "localhost" (127.0.0.1) and accepting
    TCP/IP connections on port 5432?

Not sure if this is a misunderstanding on our part about how to use docker or if we're missing a step somewhere in the move.

Thanks!

galaxy docker • 397 views
ADD COMMENTlink modified 16 months ago by Bjoern Gruening5.1k • written 16 months ago by machinelearner10
0
gravatar for Bjoern Gruening
16 months ago by
Bjoern Gruening5.1k
Germany
Bjoern Gruening5.1k wrote:

Hi,

I think I do not get the question. So you have a Galaxy Docker image running on one server and want to start this on an other server? Just pull the same version on this other server and use the same /export/ folder as on the first server. This should be enough.

Why are you installing Conda manually? Galaxy Docker has Conda installed already. So ideally you don't need to change anything.

Cheers,

Bjoern

ADD COMMENTlink written 16 months ago by Bjoern Gruening5.1k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 177 users visited in the last hour