bash: No such file or directory
If you see an error similar to one of the following, then it means that the remote system cannot find the program that you are trying to run on the remote system:
- bash: line 1: /usr/X11R6/bin/xterm: No such file or directory
- xterm: No such file or directory
- dtterm: No such file or directory
- /usr/bin/xterm: No such file or directory
This error usually results because the path to the command is incorrect.
Typically, our users will start a terminal (e.g. xterm, dtterm, konsole, gnome-terminal) as the program that is run by their X-Win32 session, then they will start the programs that they actually want to use from this terminal (e.g. ‘mozilla &’, ‘firefox &’, ‘oowrite &’, etc.). If you are starting a terminal from your X-Win32 session, then we have steps below to help you find the location of the terminal program that you are trying to run. However, if you are directly starting another application from your X-Win32 session, then you may want to consult your system administrator or use the steps below only as helpful tips to use in locating your application.
If you do not know the location of the remote terminal command, then try the following trouble shooting steps:
- Remove the full path from the command, that is, try setting the session command to xterm instead of /usr/X11R6/bin/xterm. Many Linux systems (e.g. Red Hat, SuSE, Ubuntu, Debian, etc.) ship with their terminal programs in the path, so specifying xterm as the command usually just works.
- If you are connecting to a Solaris machine, try starting dtterm instead of xterm. dtterm is generally present on Solaris, while xterm may be optional or in a strange location.
- If you simply cannot find the location of xterm, then use find to help you. Change your session command to find / -maxdepth 3 -name xterm 2>/dev/null, then check the Show Messages box on your session. When run, this session will cause the Messages window to open, and will show output similar to that below. The output below shows that xterm is located at /usr/bin/xterm, so you can change your session command to /usr/bin/xterm -ls [...] and it should work.
Sample output from using find as a session command
find: /dumps/lost+found: Permission denied<br> /usr/bin/xterm

Solutions