Agent cannot be installed on Ubuntu 22.04 LTS

Hi,

I can’t install the Rapid7 agent on Ubuntu 22.04 LTS.

As indicated by Rapid7 Support, I’ve tried these commands but it doesn’t work:

  • chmod u+x agent_installer-x86_64.sh
  • sudo ./agent_installer-x86_64.sh install_start --token eu:xxxxxxxxxxxxxxxxxxxxxxxxxxxx

or

  • chmod u+x agent_installer-x86_64.sh
  • sudo ./agent_installer-x86_64.sh install_start

I get the following error: ./agent_installer-x86_64.sh: 19: Syntax error: “(” unexpected

Could one of you please tell me how to do this?

Thanks

Capture d’écran 2023-09-08 à 11.47.53

I would omit the sh when starting the script. imho this uses the sh bin explicitly, but you should use your “real shell” like bash or zsh.

I would take a look into the script and see what it is telling at the start which shell it “wants” and look into line 19 what ists doing there.