Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Whenever I try run a program like this "sudo mono Program.exe" or from a bash script. I get the error: mono: command not found.

I am running a VPS on CentOS 6 x64 bit.

Any ideas?

share|improve this question
4  
Well, mono is not in your PATH. How did you install it? –  slhck May 20 '12 at 18:13
add comment

1 Answer

Try the command

which mono

and see which path is returned. I'm not sure on how Mono is installed, but it's possible that you could be running the executable from your home directory, instead of somewhere like '/usr/bin'.

Try creating a new temporary user and executing mono then and see if you get the same error. It seems likely that the program isn't in a location that is included in your Path variable, so it's possible that it didn't install correctly and/or you or the installer didn't move the program to /usr/bin or /usr/local/bin

share|improve this answer
    
Ran the which command. Received this: /usr/local/bin/mono –  Skowt May 23 '12 at 17:18
1  
Change the path from /usr/local/bin/mono to /usr/bin/mono using the above answer. Here's the actual command for anyone else: mv /usr/local/bin/mono /usr/bin/mono Thanks very much Joe! :D –  Skowt May 23 '12 at 17:31
    
No problem :) Please, mark my answer as accepted if it's correct! –  Joe Bentley May 23 '12 at 18:32
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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