LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (https://www.linuxquestions.org/questions/ubuntu-63/)
-   -   Trouble with add/remove programs (https://www.linuxquestions.org/questions/ubuntu-63/trouble-with-add-remove-programs-473263/)

leupi 08-12-2006 10:51 AM

Trouble with add/remove programs
 
I tried to use 'Add/Remove Programs' to install Java JRE as per these instructions:

https://jdk-distros.dev.java.net/ubuntu.html

But the process hung at the 'EULA'(Boo, Hiss...) prompt so I had to kill it. I tried to restart 'Add/Remove Programs to try agian but I am getting this error message:
Code:

ps -ef | grep adept
and
Code:

ps -ef |grep apt
and killed whatever processes there were and tried again but still got the same message. I have even rebooted but no change. Any ideas?

I also find that when I try to use Adept Package Manager I get the message:
Quote:

Read Only Mode, Database Locked
You will not be able to change your system settings in any way (install, remove or upgrade software), because another process is using the packaging system database (probably some other Adept application or apt-get or aptitude). Please close the other application before using this one.
Thanks for any ideas.

BTW, I also posted this in ubuntuforums.org. I hope that that is not a breach of etiquite; I'm sure that if it is someone will let me know :)

robbbert 08-12-2006 11:21 AM

Starting with Dapper, Sun Java is now in the repositories ("j2sdk1.5-sun" or "sun-java5-jre"). Use Synaptic or APT to install it.
Please come back if the are additional issues. - I'm already through most of them. ;)
Quote:

Read Only Mode, Database Locked
As root (or by sudo'ing), you would need to delete the file /var/lib/dpkg/lock. That file might remain after some crash.

leupi 08-12-2006 08:52 PM

Thanks for the ideas.

I deleted the file just as you said; howerver, I am still having an issue. I delete the file and then I try to start the Package Manager but I just get that KDE 'bouncing ball' for a minute and then nothing. I then try and start it again and this time I get a password prompt but get the same 'database locked' message and when I check the 'lock' file returns and I am right back to where I started.

robbbert 08-12-2006 09:27 PM

OK, it's clear why the "locked message" appears.

But why is the package manager not starting?
Quote:

I try to start the Package Manager but I just get that KDE 'bouncing ball' for a minute and then nothing
What are you doing exactly to start the program?
- The screenshots in your link are taken from Ubuntu/GNOME, while you should be on Kubuntu/KDE. Your graphical package manager should be Adept. - You might try running
Code:

sudo adept
from a terminal.

You can always use the command line ("apt-get") to install software, without ever using a graphical package manager, but I think this issue should be solved.

leupi 08-12-2006 09:43 PM

I try to start the Package Manager from the K Menu > System > Adept Package Manager and that is where I just get the KDE 'bouncing ball' and then nothing. I tried what you said and opened it by:
Code:

sudo adept
and that worked, I was able to install software no problem. Now whenever I try to start up either Adept or the Add/Remove Programs I get the 'bouncing ball' and then nothing. I then restart it, get the password prompt, and this time it works. Kind of a convoluted way, but at least now it works. Thanks for the suggestion.

robbbert 08-13-2006 03:05 PM

When you edit this menu item, you'll find the underlying command is "kdesu adept". You could type this into a terminal, and look at the output.
When I do this, I get some (cryptic to me) warnings (too) (and adept will start OK). Maybe you're lucky and get some console output that includes a pointer to the base error.

leupi 08-26-2006 09:46 AM

Suddenly everything started working OK again. Must have been the Kubuntu autofixanything applet that I downloaded... :)

augsod 08-27-2006 06:45 PM

Solution
 
I just ran into this problem and found an apparent cause and solution. Apparently Sun changed the download URL of their J2RE documentation from what adept and apt-get usually use to this: (http s: //sdlc4b.sun. com:443/ECom/EComActionServlet;jsessionid=B99022DA1BEB3B60657F56F476570243). If you download this and copy it to your /tmp folder (don't bother unzipping it) [dpkg --configure -a] to finish up the installation.

Thank you to _Dave_ from the thread http :// www .ubuntuforums. org/showthread.php?t=235016 for providing this fix.

gstrait 08-27-2006 08:25 PM

Quote:

Originally Posted by robbbert
OK, it's clear why the "locked message" appears.

But why is the package manager not starting?

What are you doing exactly to start the program?
- The screenshots in your link are taken from Ubuntu/GNOME, while you should be on Kubuntu/KDE. Your graphical package manager should be Adept. - You might try running
Code:

sudo adept
from a terminal.

You can always use the command line ("apt-get") to install software, without ever using a graphical package manager, but I think this issue should be solved.

I have the same problem, also from trying to install the jdk.
I get the same error message.
I've tried deleting the lock file in /var/lib/dpkg
But even when i try
sudo adept
the lock file reappears.

Do you have any sugestions?
Thanks.

augsod 08-28-2006 01:55 PM

Try the solution I posted in the post previous yours. It will allow the adept manager to find the missing files and finsih up the installation. It should then automatically delete the lock file for you.

gstrait 08-30-2006 04:37 PM

Okay, I got that trick to work for the java-docs.

Installing the jdk and jre still isn't working.
Are there any tricks for that?

Thanks.

dwnichols 08-30-2006 10:47 PM

Same type of problem with PostgreSQL
 
I had the same type of problem but while installing postgreSQL using adept. I made my configuration requests, clicked "Apply Changes", walked away, and when I came back an hour later it said something to the effect that it couldn't connect to the download server.

I reran adept, cursed, rebooted, reran adept, cursed some more (felt like Windows) but always the "Read Only Mode, Database Locked You will not be able to change your system settings..." message. Finally found this thread and tried to delete the /var/lib/dpkg/lock as suggested. Still no luck.

Finally decided to try the apt-get command as root. Specifically: 'apt-get check'. It's reply was "E: dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the problem."

Running 'dpkg --configure -a' completed the interrupted install of postgreSQL and all is happy again with adept.

Hope this helps

gstrait 08-31-2006 10:42 AM

Thanks for the suggestion.
That's the trick that helped me get the java-docs package working.

I'm still trying to install the jdk.

My understanding is that Sun changed the address of the neccessary files, so I can't fully download it through adept, or even apt-get.

Does anyone know where I can find the jdk installion files so that I can trick dpkg and apt into installing them?

Thanks.

robbbert 09-01-2006 09:23 AM

Edit the sources.list, i.e., by:
Quote:

sudo kate /etc/apt/sources.list
Uncomment (remove the # sign before) the lines that include the term "universe multiverse". <-- If you've already searched for "sun java" in adept, and there were no direct matches, this should be the key.
Update apt by:
Quote:

sudo apt-get update
Install the JDK:
Quote:

sudo apt-get install sun-java5-jdk
As there are several versions of Java on your system, configure Sun Java to be the default one:
Quote:

sudo update-alternatives --config java
Confirm by entering:
Quote:

which java


All times are GMT -5. The time now is 12:30 PM.