Python memory error

Asked by juniorfga on 2017-02-05

Hello
I'm having some issues with my backup, is failing with this errors

Traceback (most recent call last):
  File "/usr/bin/duplicity", line 1530, in <module>
    with_tempdir(main)
  File "/usr/bin/duplicity", line 1524, in with_tempdir
    fn()
  File "/usr/bin/duplicity", line 1378, in main
    do_backup(action)
  File "/usr/bin/duplicity", line 1506, in do_backup
    incremental_backup(sig_chain)
  File "/usr/bin/duplicity", line 663, in incremental_backup
    globals.backend)
  File "/usr/bin/duplicity", line 428, in write_multivol
    globals.gpg_profile, globals.volsize)
  File "/usr/lib/python2.7/dist-packages/duplicity/gpg.py", line 329, in GPGWriteFile
    file = GPGFile(True, path.Path(filename), profile)
  File "/usr/lib/python2.7/dist-packages/duplicity/gpg.py", line 160, in __init__
    'logger': self.logger_fp})
  File "/usr/lib/python2.7/dist-packages/duplicity/gpginterface.py", line 374, in run
    create_fhs, attach_fhs)
  File "/usr/lib/python2.7/dist-packages/duplicity/gpginterface.py", line 414, in _attach_fork_exec
    process.pid = os.fork()
OSError: [Errno 12] Cannot allocate memory

20:54:19.873 Task 'BKP' failed with exit code '30'.

The installed versions are:
duply v1.9.2
duplicity version 0.7.03
python 2.7.3
gpg 1.4.12

Running on Linux Debian 7 x64, the server has 4Gb of ram, with 3Gb free, could you help me please?

Regards

Question information

Language:
English Edit question
Status:
Answered
For:
Duplicity Edit question
Assignee:
No assignee Edit question
Last query:
2017-02-09
Last reply:
2017-02-11
edso (ed.so) said : #1

On 05.02.2017 01:18, juniorfga wrote:
> New question #451493 on Duplicity:
> https://answers.launchpad.net/duplicity/+question/451493
>
> Hello
> I'm having some issues with my backup, is failing with this errors
>
> Traceback (most recent call last):
> File "/usr/bin/duplicity", line 1530, in <module>
> with_tempdir(main)
> File "/usr/bin/duplicity", line 1524, in with_tempdir
> fn()
> File "/usr/bin/duplicity", line 1378, in main
> do_backup(action)
> File "/usr/bin/duplicity", line 1506, in do_backup
> incremental_backup(sig_chain)
> File "/usr/bin/duplicity", line 663, in incremental_backup
> globals.backend)
> File "/usr/bin/duplicity", line 428, in write_multivol
> globals.gpg_profile, globals.volsize)
> File "/usr/lib/python2.7/dist-packages/duplicity/gpg.py", line 329, in GPGWriteFile
> file = GPGFile(True, path.Path(filename), profile)
> File "/usr/lib/python2.7/dist-packages/duplicity/gpg.py", line 160, in __init__
> 'logger': self.logger_fp})
> File "/usr/lib/python2.7/dist-packages/duplicity/gpginterface.py", line 374, in run
> create_fhs, attach_fhs)
> File "/usr/lib/python2.7/dist-packages/duplicity/gpginterface.py", line 414, in _attach_fork_exec
> process.pid = os.fork()
> OSError: [Errno 12] Cannot allocate memory
>
> 20:54:19.873 Task 'BKP' failed with exit code '30'.
>
> The installed versions are:
> duply v1.9.2
> duplicity version 0.7.03
> python 2.7.3
> gpg 1.4.12
>
> Running on Linux Debian 7 x64, the server has 4Gb of ram, with 3Gb free, could you help me please?
>

can you update to the latest duplicity from backports (looks like 0.7.10 is available) and see if the error persists?

..ede/duply.net

juniorfga (juniorfga) said : #2

Hi Ede

On Wheezy backports that's the last version, I'll search to see if there is a .deb i can test, but as I recall there was a python issue with this version on Wheezy.

Thank's

Could you share the command line you use and a rough estimate of the
number of incremental backups you have.

...Ken

On Mon, Feb 6, 2017 at 6:53 AM, juniorfga <
<email address hidden>> wrote:

> Question #451493 on Duplicity changed:
> https://answers.launchpad.net/duplicity/+question/451493
>
> juniorfga posted a new comment:
> Hi Ede
>
> On Wheezy backports that's the last version, I'll search to see if there
> is a .deb i can test, but as I recall there was a python issue with this
> version on Wheezy.
>
> Thank's
>
> --
> You received this question notification because your team duplicity-team
> is an answer contact for Duplicity.
>
> _______________________________________________
> Mailing list: https://launchpad.net/~duplicity-team
> Post to : <email address hidden>
> Unsubscribe : https://launchpad.net/~duplicity-team
> More help : https://help.launchpad.net/ListHelp
>

juniorfga (juniorfga) said : #4

Hello Ken
Sorry for the delay

duply ispconfig_s3 backup --preview
Start duply v1.9.2, time is 2017-02-08 21:16:32.
Using profile '/root/.duply/ispconfig_s3'.
Using installed duplicity version 0.7.03, python 2.7.3, gpg 1.4.12 (Home: ~/.gnupg), awk 'mawk 1.3.3 Nov 1996, Copyright (C) Michael D. Brennan', grep '(GNU grep) 2.12', bash '4.2.37(1)-release (x86_64-pc-linux-gnu)'.
Autoset found secret key of first GPG_KEY entry 'XXXXX' for signing.
-- Run cmd -- Checking TEMP_DIR '/tmp' is a folder --
test -d /tmp 2>&1
-- Run cmd -- Checking TEMP_DIR '/tmp' is writable --
test -w /tmp 2>&1
-- Run cmd -- Test - Encrypt to 'XXXXXX','YYYYYY','ZZZZZZ' & Sign with 'XXXXXX' --
echo TTTTTTTTTTT | gpg --sign --default-key XXXXXX --passphrase-fd 0 --batch -r XXXXXX -r YYYYYY -r ZZZZZZ --status-fd 1 -o /tmp/duply.16477.1486599392_ENC -e /usr/bin/duply 2>&1
-- Run cmd -- Test - Decrypt --
echo TTTTTTTTTTT | gpg --passphrase-fd 0 --batch -o /tmp/duply.16477.1486599392_DEC -d /tmp/duply.16477.1486599392_ENC 2>&1
-- Run cmd -- Test - Compare --
test "$(cat '/usr/bin/duply')" = "$(cat '/tmp/duply.16477.1486599392_DEC')" 2>&1
Cleanup - Delete '/tmp/duply.16477.1486599392_*'(FAILED)

--- Start running command PRE at 21:16:32.315 ---
. /root/.duply/ispconfig_s3/pre
--- Finished state OK at 21:16:32.436 - Runtime 00:00:00.121 ---

--- Start running command BKP at 21:16:32.451 ---
TMPDIR='/tmp' PASSPHRASE=TTTTTTTTTTTTTT AWS_ACCESS_KEY_ID='AAAAAAAAAAAAAAA' AWS_SECRET_ACCESS_KEY='BBBBBBBBBBBBBBBBB' duplicity --name duply_ispconfig_s3 --encrypt-key XXXXXX --encrypt-key YYYYYY --encrypt-key ZZZZZZZ --sign-key XXXXXX --verbosity '4' --exclude-if-present '.duplicity-ignore' --full-if-older-than 1M --volsize 250 --exclude-filelist '/root/.duply/ispconfig_s3/exclude' '/' 's3://s3-us-west-2.amazonaws.com/bkp/t'
--- Finished state OK at 21:16:32.561 - Runtime 00:00:00.110 ---

--- Start running command POST at 21:16:32.573 ---
. /root/.duply/ispconfig_s3/post
--- Finished state OK at 21:16:32.669 - Runtime 00:00:00.095 ---

Only about 40 Incremental backups.

Thanks

Please do a full backup and see if the memory problem persists.

...Ken

On Wed, Feb 8, 2017 at 6:27 PM, juniorfga <
<email address hidden>> wrote:

> Question #451493 on Duplicity changed:
> https://answers.launchpad.net/duplicity/+question/451493
>
> Status: Answered => Open
>
> juniorfga is still having a problem:
> Hello Ken
> Sorry for the delay
>
> duply ispconfig_s3 backup --preview
> Start duply v1.9.2, time is 2017-02-08 21:16:32.
> Using profile '/root/.duply/ispconfig_s3'.
> Using installed duplicity version 0.7.03, python 2.7.3, gpg 1.4.12 (Home:
> ~/.gnupg), awk 'mawk 1.3.3 Nov 1996, Copyright (C) Michael D. Brennan',
> grep '(GNU grep) 2.12', bash '4.2.37(1)-release (x86_64-pc-linux-gnu)'.
> Autoset found secret key of first GPG_KEY entry 'XXXXX' for signing.
> -- Run cmd -- Checking TEMP_DIR '/tmp' is a folder --
> test -d /tmp 2>&1
> -- Run cmd -- Checking TEMP_DIR '/tmp' is writable --
> test -w /tmp 2>&1
> -- Run cmd -- Test - Encrypt to 'XXXXXX','YYYYYY','ZZZZZZ' & Sign with
> 'XXXXXX' --
> echo TTTTTTTTTTT | gpg --sign --default-key XXXXXX --passphrase-fd 0
> --batch -r XXXXXX -r YYYYYY -r ZZZZZZ --status-fd 1 -o
> /tmp/duply.16477.1486599392_ENC -e /usr/bin/duply 2>&1
> -- Run cmd -- Test - Decrypt --
> echo TTTTTTTTTTT | gpg --passphrase-fd 0 --batch -o
> /tmp/duply.16477.1486599392_DEC -d /tmp/duply.16477.1486599392_ENC 2>&1
> -- Run cmd -- Test - Compare --
> test "$(cat '/usr/bin/duply')" = "$(cat '/tmp/duply.16477.1486599392_DEC')"
> 2>&1
> Cleanup - Delete '/tmp/duply.16477.1486599392_*'(FAILED)
>
> --- Start running command PRE at 21:16:32.315 ---
> . /root/.duply/ispconfig_s3/pre
> --- Finished state OK at 21:16:32.436 - Runtime 00:00:00.121 ---
>
> --- Start running command BKP at 21:16:32.451 ---
> TMPDIR='/tmp' PASSPHRASE=TTTTTTTTTTTTTT AWS_ACCESS_KEY_ID='AAAAAAAAAAAAAAA'
> AWS_SECRET_ACCESS_KEY='BBBBBBBBBBBBBBBBB' duplicity --name
> duply_ispconfig_s3 --encrypt-key XXXXXX --encrypt-key YYYYYY --encrypt-key
> ZZZZZZZ --sign-key XXXXXX --verbosity '4' --exclude-if-present
> '.duplicity-ignore' --full-if-older-than 1M --volsize 250
> --exclude-filelist '/root/.duply/ispconfig_s3/exclude' '/' 's3://
> s3-us-west-2.amazonaws.com/bkp/t'
> --- Finished state OK at 21:16:32.561 - Runtime 00:00:00.110 ---
>
> --- Start running command POST at 21:16:32.573 ---
> . /root/.duply/ispconfig_s3/post
> --- Finished state OK at 21:16:32.669 - Runtime 00:00:00.095 ---
>
> Only about 40 Incremental backups.
>
> Thanks
>
> You received this question notification because your team duplicity-team
> is an answer contact for Duplicity.
>
> _______________________________________________
> Mailing list: https://launchpad.net/~duplicity-team
> Post to : <email address hidden>
> Unsubscribe : https://launchpad.net/~duplicity-team
> More help : https://help.launchpad.net/ListHelp
>

Can you help with this problem?

Provide an answer of your own, or ask juniorfga for more information if necessary.

To post a message you must log in.