LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Synaptic Package Manager (https://www.linuxquestions.org/questions/linux-newbie-8/synaptic-package-manager-642605/)

kiwipete 05-16-2008 05:58 AM

Synaptic Package Manager
 
Hello all. I am a relative noob at linux, having installed Ubuntu Hardy Heron on my Laptop as a clean install some 3 weeks ago.
I have been experimenting with many different commands I have come across on the forums etc with the Terminal program.
Now my problem is this.
If I go to System, Administration, Synaptic Package Manager or Software Sources, they both try to open and then quit on loading.
I can however use the sudo apt-get install command from Terminal ok, but it displays this wierd text; kiwipete@Ubuntu-laptop:~$ sudo apt-get update
sudo: unable to resolve host Ubuntu-laptop
[sudo] password for kiwipete:
After I type my password everything seems ok.
Finally on the command bar at the top of the screen the package manager displays a red downward pointing arrow with an exclamation mark in it.
When I select to install packages, it hangs and I need to go to System Monitor to end the process.

Any help will be gratefully received.

Thanks, Kiwipete.

masonm 05-17-2008 08:10 AM

Try running the command

sudo dpkg --configure -a

See if that helps.

If not, you'll need to boot into recovery mode and edit your /etc/hosts file as something may be wrong there.

Playing around with various command you find on forums without knowing what they actually do is dangerous to your system. Enter the wrong command you can trash your system or create problems.

Only enter a command that you actually need, and make sure to read the man page for it to fully understand exactly what it does and how to use it.

kiwipete 05-17-2008 05:57 PM

Hello Mason, thanks for the reply. I tried that command and it diddnt seem to make any difference.
I will now try your suggestion of re-booting into recovery mode and have a look at the /etc/hosts file.
Is there something specific I should look for here?

syg00 05-17-2008 07:45 PM

Just do a "cat /etc/hosts" from a terminal. Should have an entry for localhost and your PC name - presumably kiwipete.

kiwipete 05-17-2008 07:54 PM

This is what is displayed.........

kiwipete@Ubuntu-laptop:~$ cat /etc/hosts
127.0.0.1 localhost
127.0.1.1 Ubuntu-laptop.Kiwipetes Wireless Network

# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts
kiwipete@Ubuntu-laptop:~$

syg00 05-17-2008 08:06 PM

Presumably /etc/hostname has "Ubuntu-laptop" - I think the hosts file has to agree (line 2).

kiwipete 05-17-2008 08:12 PM

I think I have it sorted now thanks.
I edited the text below and took out the .Kiwipetes Wireless Network. It all seems to be working just fine and dandy now.:D
I have no idea how I mucked it up:scratch:, tweaking too many things I assume and poking my nose in where it shouldnt be.:o

kiwipete@Ubuntu-laptop:~$ cat /etc/hosts
127.0.0.1 localhost
127.0.1.1 Ubuntu-laptop.Kiwipetes Wireless Network


Here is the thread that helped me solve it. http://ubuntuforums.org/showthread.php?t=797442


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