LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   How to modify the root path at boot time (https://www.linuxquestions.org/questions/slackware-14/how-to-modify-the-root-path-at-boot-time-356156/)

jayhel 08-23-2005 11:16 AM

How to modify the root path at boot time
 
Hi!

I would like to modify the root path at boot time to add /usr/lib/jdk1.5.0_4/bin/

How can I achieve this?

Jayhel
Slackware 10.1
Linux 2.6.10-1

samac 08-23-2005 11:42 AM

Normally to modify the path you just run the following as root:
Code:

export PATH=$PATH:/usr/lib/jdk.1.5.0_4/bin
Samac

zhy2111314 08-23-2005 11:55 AM

or you can type the commands as follows to make it effect for ever:
Code:

$echo 'export PATH=$PATH:/usr/lib/jdk.1.5.0_4/bin' >> ~/.bashrc
$source ~/.bashrc


jayhel 08-27-2005 12:40 AM

How to modify the root path at boot time
 
Hi folks!

I am posting this reply to my own question for the benefice of everybody:
=========================================================
Where can I change the default PATH used by Slackware?

The default PATH is defined in the file /etc/profile along with a lot of other environment variables. By default separate PATH's are set for the root user and everyone else. To change the default PATH for all users or root, simply edit /etc/profile with PICO and change the PATH values. If you only want to modify a single user's PATH, then you can set the desired PATH in the .bash_profile file in the user's homedir.

Scripts that modify the PATH can be found also in /etc/profile.d
=========================================================

Best rgds,

JL


All times are GMT -5. The time now is 09:04 PM.