Bash commands
I'm Relatively new to Linux - getting there sloooowly:
In Redhat 6.5 I used to use commands such as shutdown . . . Now in Redhat 7.2 I have to su - to get access to those commands. This is causing a major problem at the moment because I'm trying to set environment variables for JDK systems but when I use setenv CLASSPATH . . . . The system comes back with Bash: command not known. Why can I no longer access these commands? Cheers in advance |
The shutdown binary is in the /sbin directory, under recent versions of Red Hat this is not placed in the default users path.
The simpliest way round this is to create a login shell when you su Code:
su - |
Not really what I want to do
I don't want to keep logging into su -
I need to be able to run some of the commands. For example I want to run the setenv command, even if I change to the sbin directory I can't run it. Likewise with other commands such as shutdown. |
Edit your path to include /sbin and
Code:
man chmod |
What shell are you using. setenv is a csh command for setting variables. If you're using sh, ksh or bash, you need to do:
export var_name=something -mk |
Excellent - Now all I need to know is. . .
You are a star!!
I got lost in Java Documentation - I tried set, setenv, . . . How do I remove that environment variable? unset myVariableName seems to work God that one bogged me down! [Linux is hard work for a newbie person but with the time I save in not rebooting and reinstalling because of M$ apps killing the machine it probably works out better - Damned nice system.] |
Seems you didn't have to ask this last question, since you seem to have gotten it. Yes, unset is the command you use. -mk
|
All times are GMT -5. The time now is 12:36 PM. |