HELP: Made a HUGE ERROR with ROOT installing JAVA
--------------------------------------------------------------------------------
After two days and many failed attempts, I finally figured out how to install JRE-6u2-linux-xxx.bin. I needed the AMD64 version for two new linux boxes. The java.com instructions would not work for me, so I used some from SnapBackup.
The first linux box installed flawlessly, but I got mixed up installing on the second and logged in as ROOT superuser. Thus, all the instructions were followed from the root location. The box squealed on reboot, but is up and running. Gave me lots of troubleshooting lines including something that would not mount after 21 attempts and was force mounted.
I am attaching the instructions on installing jre here in hope that someone can tell me how to undo this mess. I did exactly as follows on the snapbackup instructions EXCEPT that I logged in as ROOT, so all actions occurred from root@linuxboxname:~$ instead of <username>@linuxboxname:~$
Here is what I did:
A: Install Java on Ubuntu
1) Go to the Java Download Page
Open
http://www.java.com and click on Download NOW! Now click the Download button for "Linux (self-extracting file)".
2) Save Installer to "~/java" Folder
From the save window in your web browser, create a folder called java in your home folder. Download the installer file to this new folder (/home/<username>/java).
3) Launch Terminal
You need to run the Java installer from the command-line, which you access with Terminal. In the Applications menu, go into Accessories and select Terminal.
4) Run Installer
From the Terminal, enter these commands:
$ cd java
$ ls -l
$ chmod +x jre*.bin
$ ./jre*.bin
$ ln -s jre*/bin bin
The chmod command makes the file executable so you can run it. The ln command creates a symbolic link to the bin folder so it's easier to access.
5) Add Java to Your PATH
While still in the Terminal, enter these commands:
$ cd ~
$ echo 'PATH=~/bin:$PATH' >> .gnomerc
$ cat .gnomerc
$ mkdir bin
$ cd bin
$ ln -s ~/java/bin/java java
The echo command tells the GNOME desktop startup script to add your bin folder to the PATH. The cat command displays the startup script so you can verify your update. If the mkdir command reports that the folder already exists, that's ok.
6) Log Back On
Because the PATH variable is set on startup, you need to log out and then log back in for the Java installation to be complete.
___
Perhaps this is not a disaster? Does it all need to be undone? Or do I remove just parts of the install? Whatever... tell me what to do, gently and step by step, please.
BTW I understand fully how dangerous it is to log in as root and would never have done it, except that the instructions at java.com said to do so during the install, and I got mixed up (forgetting I was no longer using those instructions) after so many attempts.
__________________
Dual boot box with Windows NTFS 35GB, FAT32 Shared Data Partition 80GB, and Ubuntu-FF 7.04 Ext3 31GB