PDA

View Full Version : su: Command not found.




AmbitiousLemon
Mar 14, 2003, 06:31 PM
Well this is interesting. Any ideas?

sudo: Command not found.

su: Command not found.

ls: Command not found.


I recently started up apache, php4, sendmail, and mysql.

i used sudo and su during the installation and everything went fine and everything is working properly. i went back into the terminal to edit the httpd.conf file again and it told me sudo wasn't found. i soon found sudo wasn't the only command not found.

Any Ideas?


[EDIT] looks like the fault lies with part of the MySQL install. Editing the .tcshrc file.

The install read me said use:
setenv PATH "$PATH:/Library/MySQL/bin"

This didn't work.

So I used:
setenv PATH "/Library/MySQL/bin"

This worked... but lead to the problem described above.

breaking this by entering anything that doesn't work (either the recommended path or setenv PATH "/usr/local/bin:/bin:/sbin:/usr/bin:/usr/sbin:/Library/MySQL/bin") fixes the above problem but won't allow me to access mysql with just a command "mysql" without path (the purpose of the whole thing)

anyone know what is wrong with these paths and what is happening?



iJon
Mar 14, 2003, 07:10 PM
sounds like you may not even have bsd installed. go get your install cd, get tinkertool and tell it to show all folders. and find the bsd subsystem package and make sure you have it installed. you can also look in your receipts folder and see if it was ever installed.

iJon

AmbitiousLemon
Mar 14, 2003, 07:23 PM
bsd is installed. i use dev tools (in fact i needed dev tools to get sendmail up and running).

iJon
Mar 14, 2003, 07:25 PM
Originally posted by AmbitiousLemon
bsd is installed. i use dev tools (in fact i needed dev tools to get sendmail up and running).
hmm thats as far as i know. after i kept reading your post i figured that you did have it installed. oh well. someone who knows more about that part of os x will come to your rescue. have you tried logging into different names and seeing if that works, probablyt not but im just trying to help.

iJon

AmbitiousLemon
Mar 14, 2003, 07:32 PM
Originally posted by iJon
hmm thats as far as i know. after i kept reading your post i figured that you did have it installed. oh well. someone who knows more about that part of os x will come to your rescue. have you tried logging into different names and seeing if that works, probablyt not but im just trying to help.

iJon

i considered that but im the only user and i don't really want to create another.

right now everything works except my .tcshrc is whacked, so i cant access mysql without writing out the full path. i can fix it as described above, but then nothign else works. so i suppose i can leave it broken, its just annoying.

szark
Mar 14, 2003, 07:40 PM
Originally posted by AmbitiousLemon
The install read me said use:
setenv PATH "$PATH:/Library/MySQL/bin"


Try using:

setenv PATH "${PATH}:/Library/MySQL/bin"

or putting it at the end:

setenv PATH "/Library/MySQL/bin:$PATH"

AmbitiousLemon
Mar 14, 2003, 07:49 PM
Excellent.

Thanks so much.

The first path you suggested worked (didn't try the second sicne the first worked).

szark
Mar 14, 2003, 07:58 PM
Sometimes the shells aren't sure exactly where the environment variable name ends. The braces tell it exactly where the name of the variable begins and ends.

Glad I could help! :)