000017447 - Error message '/bin/bash^M: bad interpreter: No such file or directory' when running an RSA NetWitness script

Document created by RSA Customer Support Employee on Apr 14, 2017Last modified by RSA Customer Support on Feb 13, 2019
Version 2Show Document
  • View in full screen mode

Article Content

Article Number000017447
Applies ToRSA Product Set: NetWitness Logs and Packets (Security Analytics), NetWitness NextGen (Legacy)
RSA Product/Service Type: Core Appliance
Platform: CentOS

Error message "/bin/bash^M: bad interpreter: No such file or directory" when running an RSA NetWitness script.

Unable to execute the nwtech.sh script.

This error occurs because the script has been modified from a Windows workstation and has switched to DOS formatting. 
This can be confirmed by opening the script with the vi editor on the appliance, where [dos] will be seen in the bottom-left corner after the script name.


In order to revert the script to the appropriate formatting, open the script in the vi editor on the appliance

If you see ^M characters then delete the Windows Carriage Return (CR) characters from the end of the lines using the following command within vi:


Also run the following commands:

:set ff=unix

You will then be able to execute the script without any issue. If you require further assistance, please contact RSA Customer Support.

Legacy Article IDa65166