0

thanks in advance. i am running a fresh download of openscap on centos7 (patched). it produces a remediation script, but the script throws an error repeatedly. its the same syntax issue many times in the script

./x.sh: line 107: syntax error near unexpected token `<'
./x.sh: line 107: `     readarray -t matches < <(sed -s -n -e "\;${pattern};!d" -e "/${arch}/!d" -e "/${group}/!d;F" /etc/audit/rules.d/*.rules)'

it seems not to like the matches < <(sed portion.

can anyone help me out and let me know what i need to change to make this portion of the script work?

thanks again!

0

I think that your shell doesn't support process substitution. Some shells don't support this, eg. plain sh throws this error. It should work with Bash. Try to run the script as bash x.sh. If that doesn't help, check also if Bash isn't run in POSIX mode.

| improve this answer | |
  • that did it, i ran the script with bash and it worked...thanks again! – Tony Jul 1 at 12:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.