[redhat] error "/usr/local/share/backupninja/sys: ligne 265 : [: too many arguments"
Hello,
I ran into errors testing backupninja on RedHat (RHEL7):
/usr/local/share/backupninja/sys: ligne 265 : [: too many arguments
/usr/local/share/backupninja/sys: ligne 270 : [: too many arguments
This patch on handlers/sys
seems to solve this issue:
--- handlers/sys 2018-09-10 11:40:34.781597844 +0200
+++ /usr/local/share/backupninja/sys 2018-09-10 12:14:48.270597844 +0200
@@ -310,7 +310,7 @@
if [ $os = "redhat" ]; then
catifexec "/sbin/chkconfig" "--list"
STATUS="Collecting information about /etc/rc.d:"
- catiffile "/bin/ls /etc/rc.d/rc*.d/"
+ catiffile $(/bin/ls /etc/rc.d/rc*.d/)
elif [ $os = "debian" ]; then
for level in 0 1 2 3 4 5 6 S; do
Regards,