LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 07-08-2003, 03:46 PM   #1
bruce64
LQ Newbie
 
Registered: Jul 2003
Posts: 11

Rep: Reputation: 0
Setting java path for normal user


Good afternoon everyone,
I have set java up as a root user and have run some simple java programs. However, when I return to a regular user I can no longer run java programs. Where should I set the path? I know I am supposed to edit the bash profile but I'm not sure where in the file I should put the information. Thanks in advance for your replies!

Bruce
 
Old 07-08-2003, 04:07 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,973
Blog Entries: 11

Rep: Reputation: 877Reputation: 877Reputation: 877Reputation: 877Reputation: 877Reputation: 877Reputation: 877
Put a file named java.sh that sets the
paths into /etc/profile.d

Cheers,
Tink
 
Old 07-08-2003, 04:07 PM   #3
jpbarto
Senior Member
 
Registered: Mar 2003
Location: Pittsburgh, PA
Distribution: Gentoo / NetBSD
Posts: 1,251

Rep: Reputation: 45
in your .bash_profile file add the following lines

** NOTE: the following assumes that Java is installed in /usr/local/j2sdk1.4 **

JAVA_HOME=/usr/local/j2sdk1.4
PATH=$PATH:$JAVA_HOME/bin
CLASSPATH=$CLASSPATH:$JAVA_HOME/lib:./

export JAVA_HOME PATH CLASSPATH

if java is installed somewhere other than /usr/local/j2sdk1.4 simply change the value of JAVA_HOME

after you make these changes to .bash_profile logout and log back in. problem should be solved.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Setting Java Path gtkmike Suse/Novell 1 05-09-2005 04:05 PM
add path to normal user acbenny Linux - General 6 08-07-2004 10:24 PM
Setting the PATH for Java bruce64 Linux - Software 9 09-22-2003 11:19 AM
setting path for java ahernaiz Programming 4 03-25-2003 04:30 PM
Setting Java path issues... jmizza Linux - Newbie 8 02-27-2002 08:23 PM


All times are GMT -5. The time now is 05:06 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration