LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Can't install/update the packages on newly installed CentOS6 (http://www.linuxquestions.org/questions/linux-software-2/cant-install-update-the-packages-on-newly-installed-centos6-916673/)

sura2k 12-01-2011 10:19 PM

Can't install/update the packages on newly installed CentOS6
 
I installed CentOS6 and it is the first time that I use CentOS. I tried to install/update packages. Here is the output when I try to run
Code:

yum update
.

Code:

[root@localhost suranga]# yum update
Loaded plugins: fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
 * base: mirror.nus.edu.sg
 * extras: mirror.nus.edu.sg
 * updates: mirror.nus.edu.sg
base                                                    | 3.7 kB    00:00   
http://mirror.nus.edu.sg/centos/6.0/os/i386/repodata/2b014e1fcde80ec1cc69d6a048f260f712b1ae2d83d1fc04d3b3c00ade817ec9-primary.sqlite.bz2: [Errno 12] Timeout on http://mirror.nus.edu.sg/centos/6.0/os/i386/repodata/2b014e1fcde80ec1cc69d6a048f260f712b1ae2d83d1fc04d3b3c00ade817ec9-primary.sqlite.bz2: (28, '')
Trying other mirror.
http://centosmirror.go4hosting.in/centos/6.0/os/i386/repodata/2b014e1fcde80ec1cc69d6a048f260f712b1ae2d83d1fc04d3b3c00ade817ec9-primary.sqlite.bz2: [Errno 12] Timeout on http://centosmirror.go4hosting.in/centos/6.0/os/i386/repodata/2b014e1fcde80ec1cc69d6a048f260f712b1ae2d83d1fc04d3b3c00ade817ec9-primary.sqlite.bz2: (28, '')
Trying other mirror.

This won't stop.

I tried these things. But no results

1.
Code:

yum clean all
2.edit
Code:

/etc/repos.d
comment
Code:

mirrors
and uncomment
Code:

baseurl
3.edit
Code:

edit /etc/resolve.conf
nameserver into 8.8.8.8

4.
Code:

cd /var/lib/rpm
rm -f __db*
rpmdb -v --rebuilddb

5.edit
Code:

/etc/yum.conf
timeout=300

6. stop the
Code:

ip6tables
I tried lot of things more than these.
But still I have the same problem.

When I start the OS, it always changes the
Code:

/etc/resolve.conf
and adds
Code:

nameserver 10.16.32.1
(10.16.32.1 is my router) and there may be some things that I don't know.

And Internet works fine.
Please help me to get rid of this.

Thank You!

kbscores 12-02-2011 08:59 AM

I had this same issue when I first installed Centos. Most likely your proxy server isn't correct. -- or try updating yum.

Also - NetworkManager is most likely what is causing your resolv.conf to reset.
May need to switch to network
run
Code:

# chkconfig --list |grep -i etw
to see which network program you are using

Set the DNS in the IP V4 Tab for the connection in Network Manager:

Network Manager has control of etc/resolv.conf
Using Network Manager just select the IPv4 tab and set it to (dhcp addresses only).
The DNS entries can be set here and they will not be reset.

Other option:
If you want to use that DNS all the time then set it in the router.
You can forgo what I just mentioned.


All times are GMT -5. The time now is 08:28 PM.