TypeError: argument must be an int, or have a fileno() method #440

Closed
opened 2021-08-06 12:45:43 +00:00 by bjo · 1 comment

What I'm trying to do and why

Steps to reproduce (if a bug)

borgmatic -v2 --progress

Actual behavior (if a bug)

Ensuring legacy configuration is upgraded
/etc/borgmatic.d/borgbase.yaml: No commands to run for pre-everything hook
/etc/borgmatic.d/rsync.yaml: No commands to run for pre-everything hook
/etc/borgmatic.d/borgbase.yaml: No commands to run for pre-prune hook
/etc/borgmatic.d/borgbase.yaml: Running command for pre-backup hook
echo "`date` - Starting a backup job."
Thu Jul 29 01:02:13 PM CEST 2021 - Starting a backup job.
/etc/borgmatic.d/borgbase.yaml: No commands to run for pre-check hook
somerepo@somerepo.repo.borgbase.com:repo: Pruning archives
borg prune --keep-daily 7 --keep-weekly 4 --keep-monthly 6 --keep-yearly 0 --prefix {hostname}- --stats --debug --show-rc somerepo@somerepo.repo.borgbase.com:repo
using builtin fallback logging configuration
35 self tests completed in 0.08 seconds
SSH command line: ['ssh', 'somerepo@somerepo.repo.borgbase.com', 'borg', 'serve', '--umask=077', '--debug']
Remote: using builtin fallback logging configuration
Remote: 35 self tests completed in 0.06 seconds
Remote: using builtin fallback logging configuration
Remote: Initialized logging system for JSON-based protocol
Remote: Resolving repository path b'repo'
Remote: Resolved repository path to '/srv/repos/somerepo/repo'
Remote: Verified integrity of /srv/repos/somerepo/repo/index.3247
TAM-verified manifest
security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo'
security: read manifest timestamp '2021-07-29T10:55:14.071287'
security: determined newest manifest timestamp as 2021-07-29T10:55:14.071287
security: repository checks ok, allowing access
Verified integrity of /root/.cache/borg/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5/chunks
security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo'
security: read manifest timestamp '2021-07-29T10:55:14.071287'
security: determined newest manifest timestamp as 2021-07-29T10:55:14.071287
security: repository checks ok, allowing access
Remote: Cleaned up 0 uncommitted segment files (== everything after segment 3247).
Remote: Verified integrity of /srv/repos/somerepo/repo/hints.3247
Remote: Storage quota: 80.15 GB out of 285.50 GB used.
Remote: check_free_space: required bytes 666484108, free bytes 13637487423488
Remote: Storage quota: 80.08 GB out of 285.50 GB used.
security: saving state for 76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5 to /root/.config/borg/security/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5
security: current location   ssh://somerepo@somerepo.repo.borgbase.com/./repo
security: key type           3
security: manifest timestamp 2021-07-29T11:02:18.132650
------------------------------------------------------------------------------
                       Original size      Compressed size    Deduplicated size
Deleted data:              -46.45 GB            -43.49 GB            -61.57 MB
All archives:              752.21 GB            700.82 GB             80.06 GB
                       Unique chunks         Total chunks
Chunk index:                  474266              1751543
------------------------------------------------------------------------------
RemoteRepository: 17.26 kB bytes sent, 3.33 MB bytes received, 290 messages sent
terminating with success status, rc 0
somerepo@somerepo.repo.borgbase.com:repo: Creating archive
somerepo@somerepo.repo.borgbase.com:repo: Calling postgresql_databases hook function remove_database_dumps
somerepo@somerepo.repo.borgbase.com:repo: Removing PostgreSQL database dumps
somerepo@somerepo.repo.borgbase.com:repo: Calling postgresql_databases hook function dump_databases
somerepo@somerepo.repo.borgbase.com:repo: Dumping PostgreSQL databases
somerepo@somerepo.repo.borgbase.com:repo: Dumping PostgreSQL database all to /root/.borgmatic/postgresql_databases/localhost/all
pg_dumpall --no-password --clean --if-exists --username postgres > /root/.borgmatic/postgresql_databases/localhost/all
borg create --exclude-from /tmp/tmpdqtytxi3 --exclude-caches --exclude-if-present .nobackup --compression zstd,16 --one-file-system --read-special --files-cache ctime,size,inode --stats --debug --show-rc --progress somerepo@somerepo.repo.borgbase.com:repo::{hostname}-{now:%Y-%m-%dT%H:%M:%S.%f} /data /etc /home /root/.borgmatic /var/lib/pacman /var/lib/prosody /var/lib/rspamd /var/lib/smokeping /var/lib/vaultwarden > 
using builtin fallback logging configuration
35 self tests completed in 0.07 seconds
SSH command line: ['ssh', 'somerepo@somerepo.repo.borgbase.com', 'borg', 'serve', '--umask=077', '--debug']
Remote: using builtin fallback logging configuration
Remote: 35 self tests completed in 0.06 seconds
Remote: using builtin fallback logging configuration
Remote: Initialized logging system for JSON-based protocol
Remote: Resolving repository path b'repo'
Remote: Resolved repository path to '/srv/repos/somerepo/repo'
Remote: Verified integrity of /srv/repos/somerepo/repo/index.3251
TAM-verified manifest
security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo'
security: read manifest timestamp '2021-07-29T11:02:18.132650'
security: determined newest manifest timestamp as 2021-07-29T11:02:18.132650
security: repository checks ok, allowing access
Creating archive at "somerepo@somerepo.repo.borgbase.com:repo::{hostname}-{now:%Y-%m-%dT%H:%M:%S.%f}"
Verified integrity of /root/.cache/borg/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5/chunks
Reading files cache ...
Verified integrity of /root/.cache/borg/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5/files
security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo'
security: read manifest timestamp '2021-07-29T11:02:18.132650'
security: determined newest manifest timestamp as 2021-07-29T11:02:18.132650
security: repository checks ok, allowing access
Processing files ...
Remote: Cleaned up 0 uncommitted segment files (== everything after segment 3251).                                                                                                            
Remote: Verified integrity of /srv/repos/somerepo/repo/hints.3251
Remote: Storage quota: 80.08 GB out of 285.50 GB used.
Traceback (most recent call last):9008 N root/.borgmatic/postgresql_databases/localhost/all                                                                                                   
  File "/usr/bin/borgmatic", line 33, in <module>
    sys.exit(load_entry_point('borgmatic==1.5.17', 'console_scripts', 'borgmatic')())
  File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 804, in main
    summary_logs = parse_logs + list(collect_configuration_run_summary_logs(configs, arguments))
  File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 702, in collect_configuration_run_summary_logs
    results = list(run_configuration(config_filename, config, arguments))
  File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 125, in run_configuration
    yield from run_actions(
  File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 318, in run_actions
    json_output = borg_create.create_archive(
  File "/usr/lib/python3.9/site-packages/borgmatic/borg/create.py", line 274, in create_archive
    return execute_command_with_processes(
  File "/usr/lib/python3.9/site-packages/borgmatic/execute.py", line 272, in execute_command_with_processes
    log_outputs(
  File "/usr/lib/python3.9/site-packages/borgmatic/execute.py", line 72, in log_outputs
    (ready_buffers, _, _) = select.select(output_buffers, [], [])
TypeError: argument must be an int, or have a fileno() method.

Expected behavior (if a bug)

No python error

Other notes / implementation ideas

Environment

borgmatic version: 1.5.17

borgmatic installation method: package

Borg version: 1.1.17

Python version: 3.9.6

Database version (if applicable): PostgreSQL 13.3

operating system and version: Arch Linux

#### What I'm trying to do and why #### Steps to reproduce (if a bug) `borgmatic -v2 --progress` #### Actual behavior (if a bug) ``` Ensuring legacy configuration is upgraded /etc/borgmatic.d/borgbase.yaml: No commands to run for pre-everything hook /etc/borgmatic.d/rsync.yaml: No commands to run for pre-everything hook /etc/borgmatic.d/borgbase.yaml: No commands to run for pre-prune hook /etc/borgmatic.d/borgbase.yaml: Running command for pre-backup hook echo "`date` - Starting a backup job." Thu Jul 29 01:02:13 PM CEST 2021 - Starting a backup job. /etc/borgmatic.d/borgbase.yaml: No commands to run for pre-check hook somerepo@somerepo.repo.borgbase.com:repo: Pruning archives borg prune --keep-daily 7 --keep-weekly 4 --keep-monthly 6 --keep-yearly 0 --prefix {hostname}- --stats --debug --show-rc somerepo@somerepo.repo.borgbase.com:repo using builtin fallback logging configuration 35 self tests completed in 0.08 seconds SSH command line: ['ssh', 'somerepo@somerepo.repo.borgbase.com', 'borg', 'serve', '--umask=077', '--debug'] Remote: using builtin fallback logging configuration Remote: 35 self tests completed in 0.06 seconds Remote: using builtin fallback logging configuration Remote: Initialized logging system for JSON-based protocol Remote: Resolving repository path b'repo' Remote: Resolved repository path to '/srv/repos/somerepo/repo' Remote: Verified integrity of /srv/repos/somerepo/repo/index.3247 TAM-verified manifest security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo' security: read manifest timestamp '2021-07-29T10:55:14.071287' security: determined newest manifest timestamp as 2021-07-29T10:55:14.071287 security: repository checks ok, allowing access Verified integrity of /root/.cache/borg/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5/chunks security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo' security: read manifest timestamp '2021-07-29T10:55:14.071287' security: determined newest manifest timestamp as 2021-07-29T10:55:14.071287 security: repository checks ok, allowing access Remote: Cleaned up 0 uncommitted segment files (== everything after segment 3247). Remote: Verified integrity of /srv/repos/somerepo/repo/hints.3247 Remote: Storage quota: 80.15 GB out of 285.50 GB used. Remote: check_free_space: required bytes 666484108, free bytes 13637487423488 Remote: Storage quota: 80.08 GB out of 285.50 GB used. security: saving state for 76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5 to /root/.config/borg/security/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5 security: current location ssh://somerepo@somerepo.repo.borgbase.com/./repo security: key type 3 security: manifest timestamp 2021-07-29T11:02:18.132650 ------------------------------------------------------------------------------ Original size Compressed size Deduplicated size Deleted data: -46.45 GB -43.49 GB -61.57 MB All archives: 752.21 GB 700.82 GB 80.06 GB Unique chunks Total chunks Chunk index: 474266 1751543 ------------------------------------------------------------------------------ RemoteRepository: 17.26 kB bytes sent, 3.33 MB bytes received, 290 messages sent terminating with success status, rc 0 somerepo@somerepo.repo.borgbase.com:repo: Creating archive somerepo@somerepo.repo.borgbase.com:repo: Calling postgresql_databases hook function remove_database_dumps somerepo@somerepo.repo.borgbase.com:repo: Removing PostgreSQL database dumps somerepo@somerepo.repo.borgbase.com:repo: Calling postgresql_databases hook function dump_databases somerepo@somerepo.repo.borgbase.com:repo: Dumping PostgreSQL databases somerepo@somerepo.repo.borgbase.com:repo: Dumping PostgreSQL database all to /root/.borgmatic/postgresql_databases/localhost/all pg_dumpall --no-password --clean --if-exists --username postgres > /root/.borgmatic/postgresql_databases/localhost/all borg create --exclude-from /tmp/tmpdqtytxi3 --exclude-caches --exclude-if-present .nobackup --compression zstd,16 --one-file-system --read-special --files-cache ctime,size,inode --stats --debug --show-rc --progress somerepo@somerepo.repo.borgbase.com:repo::{hostname}-{now:%Y-%m-%dT%H:%M:%S.%f} /data /etc /home /root/.borgmatic /var/lib/pacman /var/lib/prosody /var/lib/rspamd /var/lib/smokeping /var/lib/vaultwarden > using builtin fallback logging configuration 35 self tests completed in 0.07 seconds SSH command line: ['ssh', 'somerepo@somerepo.repo.borgbase.com', 'borg', 'serve', '--umask=077', '--debug'] Remote: using builtin fallback logging configuration Remote: 35 self tests completed in 0.06 seconds Remote: using builtin fallback logging configuration Remote: Initialized logging system for JSON-based protocol Remote: Resolving repository path b'repo' Remote: Resolved repository path to '/srv/repos/somerepo/repo' Remote: Verified integrity of /srv/repos/somerepo/repo/index.3251 TAM-verified manifest security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo' security: read manifest timestamp '2021-07-29T11:02:18.132650' security: determined newest manifest timestamp as 2021-07-29T11:02:18.132650 security: repository checks ok, allowing access Creating archive at "somerepo@somerepo.repo.borgbase.com:repo::{hostname}-{now:%Y-%m-%dT%H:%M:%S.%f}" Verified integrity of /root/.cache/borg/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5/chunks Reading files cache ... Verified integrity of /root/.cache/borg/76d68b7286175125f4a39488d9439ac68adfb03a3135b6da2665502dc398f5e5/files security: read previous location 'ssh://somerepo@somerepo.repo.borgbase.com/./repo' security: read manifest timestamp '2021-07-29T11:02:18.132650' security: determined newest manifest timestamp as 2021-07-29T11:02:18.132650 security: repository checks ok, allowing access Processing files ... Remote: Cleaned up 0 uncommitted segment files (== everything after segment 3251). Remote: Verified integrity of /srv/repos/somerepo/repo/hints.3251 Remote: Storage quota: 80.08 GB out of 285.50 GB used. Traceback (most recent call last):9008 N root/.borgmatic/postgresql_databases/localhost/all File "/usr/bin/borgmatic", line 33, in <module> sys.exit(load_entry_point('borgmatic==1.5.17', 'console_scripts', 'borgmatic')()) File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 804, in main summary_logs = parse_logs + list(collect_configuration_run_summary_logs(configs, arguments)) File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 702, in collect_configuration_run_summary_logs results = list(run_configuration(config_filename, config, arguments)) File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 125, in run_configuration yield from run_actions( File "/usr/lib/python3.9/site-packages/borgmatic/commands/borgmatic.py", line 318, in run_actions json_output = borg_create.create_archive( File "/usr/lib/python3.9/site-packages/borgmatic/borg/create.py", line 274, in create_archive return execute_command_with_processes( File "/usr/lib/python3.9/site-packages/borgmatic/execute.py", line 272, in execute_command_with_processes log_outputs( File "/usr/lib/python3.9/site-packages/borgmatic/execute.py", line 72, in log_outputs (ready_buffers, _, _) = select.select(output_buffers, [], []) TypeError: argument must be an int, or have a fileno() method. ``` #### Expected behavior (if a bug) No python error #### Other notes / implementation ideas #### Environment **borgmatic version:** 1.5.17 **borgmatic installation method:** package **Borg version:** 1.1.17 **Python version:** 3.9.6 **Database version (if applicable):** PostgreSQL 13.3 **operating system and version:** Arch Linux
Owner

Thank you for filing this one! I've just pushed a likely fix and released borgmatic 1.5.18 with it. Please let me know if that solves the issue for you.

Thank you for filing this one! I've just pushed a likely fix and released borgmatic 1.5.18 with it. Please let me know if that solves the issue for you.
witten added the
bug
label 2021-08-06 16:05:05 +00:00
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: borgmatic-collective/borgmatic#440
No description provided.