Link to home
Start Free TrialLog in
Avatar of Amarjot Singh
Amarjot SinghFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Duplicity Linux Backup to Azure Error

Duplicity Linux Backup to Azure

Hi All,

Can anyone help me with the error below please? When executing the following command, I receive the corresponding error.

duplicity --full-if-older-than 1M /srv/folder azure://container --archive-dir /var/lib/folder --volsize 2000 --tempdir /srv/tmp

Open in new window


Import of duplicity.backends.giobackend Failed: No module named gio
UnsupportedBackendScheme: scheme not supported in url: azure://container

Open in new window


Running on a updated Debian build with Azure CLI 2.0
Avatar of Amarjot Singh
Amarjot Singh
Flag of United Kingdom of Great Britain and Northern Ireland image

ASKER

Update:

Realised that the azurebackend.py file was missing from /usr/lib/python2.7/dist-packages/duplicity/backends

Manually added this in and now the error is as follows:

Import of duplicity.backends.giobackend Failed: No module named gio
/usr/lib/python2.7/dist-packages/duplicity/backends/azurebackend.py:39: ImportWarning: Not importing directory '/usr/local/lib/python2.7/dist-packages/azure_storage_nspkg-3.0.0-py2.7.egg/azure': missing __init__.py
  import azure
/usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.py:1: UserWarning: Module azure was already imported from /usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.pyc, but /usr/local/lib/python2.7/dist-packages/azure_storage_nspkg-3.0.0-py2.7.egg is being added to sys.path
  __import__('pkg_resources').declare_namespace(__name__)
/usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.py:1: UserWarning: Module azure was already imported from /usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.pyc, but /usr/local/lib/python2.7/dist-packages/azure_storage_blob-1.1.0-py2.7.egg is being added to sys.path
  __import__('pkg_resources').declare_namespace(__name__)
/usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.py:1: UserWarning: Module azure was already imported from /usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.pyc, but /usr/local/lib/python2.7/dist-packages/azure_storage_file-1.1.0-py2.7.egg is being added to sys.path
  __import__('pkg_resources').declare_namespace(__name__)
/usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.py:1: UserWarning: Module azure was already imported from /usr/local/lib/python2.7/dist-packages/azure_storage_common-1.1.0-py2.7.egg/azure/__init__.pyc, but /usr/local/lib/python2.7/dist-packages/azure_storage_queue-1.1.0-py2.7.egg is being added to sys.path
  __import__('pkg_resources').declare_namespace(__name__)
/usr/lib/python2.7/pkgutil.py:186: ImportWarning: Not importing directory '/usr/local/lib/python2.7/dist-packages/azure_storage_nspkg-3.0.0-py2.7.egg/azure': missing __init__.py
  file, filename, etc = imp.find_module(subname, path)
BackendException: Azure backend requires Microsoft Azure Storage SDK for Python (https://pypi.python.org/pypi/azure-storage/).
Exception: No module named common

Open in new window

Avatar of David Johnson, CD
from the error message you need to install azure storage for python
Either from https://pypi.org/project/azure-storage/
or
pip install azure-storage

Open in new window

and retry
Hi David - thanks for your response!

Unfortunately I’ve tried the above already to no avail. pip install azure-storage cannot find the package but I have installed it manually using the same URL but I still get the same error.

I read that version 0.2 is required and have downgraded to this also but still have the same error!
I don't have your environment so I can't test unfortunately
This question needs an answer!
Become an EE member today
7 DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform.
View membership options
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.