Hello,
I am running Barman on macOS Ventura (13.5), installed via MacPorts.
The backups and WAL archiving seems to be working ok, but when I try to recover a backup to a local drive, the barman command returns the following:
> sudo -u barman barman recover pg 20230829T103804 /Volumes/Disk2/RECOVERYTEST/
Starting local restore for server pg using backup 20230829T103804
Destination directory: /Volumes/Disk2/RECOVERYTEST/
Copying the base backup.
EXCEPTION: Can't pickle local object 'Command.make_logging_handler.<locals>.handler'
See log file for more details.
The barman log shows some more info:
2023-08-30 13:06:05,984 [95906] barman.command_wrappers DEBUG: Command stderr:
2023-08-30 13:06:05,991 [95906] barman.copy_controller INFO: Copy failed (safe before None)
2023-08-30 13:06:05,992 [95906] barman.cli ERROR: Can't pickle local object 'Command.make_logging_handler.<locals>.handler'
See log file for more details.
Traceback (most recent call last):
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/barman/cli.py", line 2101, in main
args.func(args)
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/barman/cli.py", line 993, in recover
server.recover(
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/barman/server.py", line 1882, in recover
return self.backup_manager.recover(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/barman/backup.py", line 777, in recover
recovery_info = executor.recover(
^^^^^^^^^^^^^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/barman/recovery_executor.py", line 189, in recover
self._backup_copy(
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/barman/recovery_executor.py", line 802, in _backup_copy
controller.copy()
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/barman/copy_controller.py", line 566, in copy
pool = Pool(
^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/context.py", line 119, in Pool
return Pool(processes, initializer, initargs, maxtasksperchild,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/pool.py", line 215, in __init__
self._repopulate_pool()
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/pool.py", line 306, in _repopulate_pool
return self._repopulate_pool_static(self._ctx, self.Process,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/pool.py", line 329, in _repopulate_pool_static
w.start()
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/process.py", line 121, in start
self._popen = self._Popen(self)
^^^^^^^^^^^^^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/context.py", line 288, in _Popen
return Popen(process_obj)
^^^^^^^^^^^^^^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/popen_spawn_posix.py", line 32, in __init__
super().__init__(process_obj)
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/popen_fork.py", line 19, in __init__
self._launch(process_obj)
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/popen_spawn_posix.py", line 47, in _launch
reduction.dump(process_obj, fp)
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/reduction.py", line 60, in dump
ForkingPickler(file, protocol).dump(obj)
AttributeError: Can't pickle local object 'Command.make_logging_handler.<locals>.handler'
Anyone have any idea what is causing this error and how to fix it?
The permissions for the destination directory are all in order. Barman creates the entire PGDATA structure, but the folder are empty.