Go Back   openSUSE Forums > Archives > SF Archives > ARCHIVES - Software
Forums FAQ Members List Search Today's Posts Mark Forums Read

ARCHIVES - Software Questions about use, installation, or configuration of software running on SUSE Linux

 
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 14-Mar-2005, 16:10
harryc
Guest
 
Posts: n/a
Default

Ok, so this is definately a newbie question, but I can't put my finger on the answer after many hours of research. My $PATH looks like the following;

Code:
harryc@linux:~> echo $PATH
/home/harryc/bin:/usr/local/bin:/usr/bin:/usr/X11R6/bin:/bin:/usr/games:/opt/gnome/bin:/opt/kde3/bin:/usr/lib/jvm/jre/bin
Lets say that I want to change a part of it to point to another location for JAVA. How do I do that, and how do I make it permanent? I know I can issue this command to add to $PATH. As follows;

Code:
export PATH=/usr/share/j2re1.4.2/bin:$PATH
...and I believe I can make it permanent by adding it to /etc/profile.local. But how do I delete
Code:
/usr/lib/jvm/jre/bin
  #2 (permalink)  
Old 14-Mar-2005, 19:15
Snakedriver
Guest
 
Posts: n/a
Default

d*** good question! Glad you asked it. Being that I have made a number of symlinks based on howto's & guidance received, one would think that one should know how to undo them. I didn't, so, started looking. I read that it's important to remove them if you have symlinked to the kernel (which I have done) and want to update to a new kernel.

As best as I can report, run "ls -l" & this will give you a list of all your symlinks. Mine was 492 (in root) which was a supprise as I had only created 3 or 4. Evidently every package you load creates its required symlinks -- that's why so many.

Also, as best as I can report, you treat a symlink just as you do any other file & once you find it, just "rm" it.

Let us know how you fare.
  #3 (permalink)  
Old 14-Mar-2005, 19:38
Snakedriver
Guest
 
Posts: n/a
Default

Found one more with a little help:

1. Change Directory To /usr/src

cd /usr/src

2. Check for symlink (ex. /usr/src/linux->/usr/src/linux-2.4.18)

ls -alc

3. Double check with this command (output ex.) linux: symbolic link to linux-2.4.18-14

file linux

4. Remove the symlink

rm linux
---------------------------------
Here's what it did for me:

im@linux:~> cd /usr/src
jim@linux:/usr/src> ls -alc
total 1
drwxr-xr-x 7 root root 272 2005-02-20 12:44 .
drwxr-xr-x 13 root root 368 2005-02-23 14:13 ..
drwxr-xr-x 23 root root 696 2005-02-23 19:07 kernel-modules
lrwxrwxrwx 1 root root 17 2005-02-19 16:51 linux -> linux-2.6.8-24.11
drwxr-xr-x 3 root root 72 2005-02-19 16:51 linux-2.6.8-24
drwxr-xr-x 20 root root 712 2005-02-20 12:44 linux-2.6.8-24.11
drwxr-xr-x 3 root root 72 2005-02-20 12:44 linux-2.6.8-24.11-obj
lrwxrwxrwx 1 root root 21 2005-02-19 16:51 linux-obj -> linux-2.6.8-24.11-obj
drwxr-xr-x 7 root root 168 2005-02-19 15:22 packages
jim@linux:/usr/src> file linux
linux: symbolic link to `linux-2.6.8-24.11'
jim@linux:/usr/src>


If I wanted to get rid of this symlink = rm linux & then I would have to go and shoot myself.
Hope this helps.
  #4 (permalink)  
Old 14-Mar-2005, 19:40
harryc
Guest
 
Posts: n/a
Default

SnakeDriver, thanks for the reply. Are we talking about the same thing? I need to make a change to $PATH, and my symlinks (ls -l) don't look like they have much to do with that. Am I way off here? .
  #5 (permalink)  
Old 14-Mar-2005, 19:57
Shatrat
Guest
 
Posts: n/a
Default

I think he means move or remove /usr/lib/jvm/jre/bin and symmlink it to the one you wish to use instead.

Im sure there is an easy way to remove something from your path, I cant remember what it is. I read a really good $PATH how-to guide thingy on the linux documentation project years ago, wish I remembered more from it.
  #6 (permalink)  
Old 14-Mar-2005, 20:30
Snakedriver
Guest
 
Posts: n/a
Default

harryc. " Are we talking about the same thing? I need to make a change to $PATH"

Sorry about that, I read
"But how do I delete
CODE
/usr/lib/jvm/jre/bin " and jumped to symlink conclusion.

Well it was a good drill for me anyway; something that I should/need to know. I apologize for wasting your time though.

IMHO whatever suse executes last is what is going to rule. At least it seems that way to me when I read my boot log. So one way is to put you PATH code in the proper config file near the end. Saying that, I looked for /etc/profile.local & I do beleive that I do not have it, although /etc/profile says to use it.

I got some help earlier with nano, I was using "export PATH=$Paath:/usr/local/bin" and asked for help to make it permanent & was recommended a symlink solution = "ln -s /usr/local/bin/nano /usr/bin/nano which worked like a charm.

If you are using j2re1.4.2 have you tried removing jre in yast?

let us know how it turns out.
  #7 (permalink)  
Old 14-Mar-2005, 20:31
harryc
Guest
 
Posts: n/a
Default

Ah..(slaps self upside of head). I see. I didn't think of that. Good one SnakeDriver. Thanks Shatrat

I ended up creating /etc/profile.local (yes it did not exist) and added the following;

export PATH=/usr/java/jre1.5.0_02/bin:$PATH
export JAVA_HOME=/usr/java/jre1.5.0_02/bin

Worked like a charm on reboot. I was going to use jre 1.4.2, but it did not work with the latest Azureus, so I installed 1.5.0. Both Azureus and jre are 32 bit, and this on an x86_64 install. I also left the 64 bit jre 1.4.2 installed because OO had a dependancy on it. It all works, but don't ask me how .
  #8 (permalink)  
Old 14-Mar-2005, 20:53
Snakedriver
Guest
 
Posts: n/a
Default

Well Done!
  #9 (permalink)  
Old 12-Apr-2005, 08:02
E@zyVG
Guest
 
Posts: n/a
Default

Where is PATH file saved. or where can it be edited directly?
  #10 (permalink)  
Old 12-Apr-2005, 10:28
harryc
Guest
 
Posts: n/a
Default

Quote:
Originally posted by E@zyVG@Apr 12 2005, 08:02 AM
Where is PATH file saved. or where can it be edited directly?
[snapback]75338[/snapback]
Good question that I never got answered myself.
 

Bookmarks

Thread Tools
Display Modes

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




 

Search Engine Friendly URLs by vBSEO 3.3.0 RC2