This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 1479222 - 'command' is a bash builtin
'command' is a bash builtin
Status: NEW
Product: Fedora
Classification: Fedora
Component: barman (Show other bugs)
26
Unspecified Linux
unspecified Severity unspecified
: ---
: ---
Assigned To: Dale Macartney
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2017-08-08 02:52 EDT by Reto Zingg
Modified: 2017-08-08 02:52 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Reto Zingg 2017-08-08 02:52:27 EDT
Description of problem:

With bash 4.4 barman can't handle the WALs any more correctly while compressing, it fails with:

2017-08-06 14:58:01,774 [2344] barman.cli ERROR: {'ret': 2, 'out': '', 'err': "/bin/sh: `command': is a special builtin\n"}
See log file for more details.
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/barman/cli.py", line 1041, in main
    p.dispatch(pre_call=global_config)
  File "/usr/lib/python3.6/site-packages/argh/helpers.py", line 55, in dispatch
    return dispatch(self, *args, **kwargs)
  File "/usr/lib/python3.6/site-packages/argh/dispatching.py", line 174, in dispatch
    for line in lines:
  File "/usr/lib/python3.6/site-packages/argh/dispatching.py", line 277, in _execute_command
    for line in result:
  File "/usr/lib/python3.6/site-packages/argh/dispatching.py", line 231, in _call
    result = function(namespace_obj)
  File "/usr/lib/python3.6/site-packages/barman/cli.py", line 672, in archive_wal
    server.archive_wal()
  File "/usr/lib/python3.6/site-packages/barman/server.py", line 1408, in archive_wal
    self.backup_manager.archive_wal(verbose)
  File "/usr/lib/python3.6/site-packages/barman/backup.py", line 468, in archive_wal
    archiver.archive(fxlogdb, verbose)
  File "/usr/lib/python3.6/site-packages/barman/wal_archiver.py", line 196, in archive
    self.archive_wal(compressor, wal_info)
  File "/usr/lib/python3.6/site-packages/barman/wal_archiver.py", line 324, in archive_wal
    compressor.compress(src_file, tmp_file)
  File "/usr/lib/python3.6/site-packages/barman/compression.py", line 153, in compress
    return self._compress(src, dst)
  File "/usr/lib/python3.6/site-packages/barman/command_wrappers.py", line 260, in __call__
    self.get_output(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/barman/command_wrappers.py", line 292, in get_output
    return self._get_output_once(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/barman/command_wrappers.py", line 357, in _get_output_once
    self.check_return_value(allowed_retval)
  File "/usr/lib/python3.6/site-packages/barman/command_wrappers.py", line 371, in check_return_value
    ret=self.ret, out=self.out, err=self.err))
barman.exceptions.CommandFailedException: {'ret': 2, 'out': '', 'err': "/bin/sh: `command': is a special builtin\n"}


Version-Release number of selected component (if applicable):
barman-2.1-2.fc26.noarch

How reproducible:
Enable streaming_archiver = on

Steps to Reproduce:
1. run 'barman cron'


Actual results:
see stack trace above

Expected results:
it works, and compresses the wal file

Additional info:
Upstream issue:
https://github.com/2ndquadrant-it/barman/issues/118

Upstream pull-request:
https://github.com/2ndquadrant-it/barman/pull/119

I open this bug in the hope as soon as upstream fixed it, it can also be fixed in the Fedora release.

Even tough the underlying bug is the following bash bug #1479220 I think it makes sense to avoid to use possible builtin command names in scripts and it should be fixed.

Note You need to log in before you can comment on or make changes to this bug.