Koozali.org formerly Contribs.org

Cannot find a valid baseurl for repo: base

Cannot find a valid baseurl for repo: base
« on: February 21, 2010, 02:52:57 PM »
Hi Leute,

ich habe vor ein paar Tagen von Cron folgende E-Mail bekommen:

Quote
From: root@bauphysik-dahlem.local (Cron Daemon)
To: root@bauphysik-dahlem.local
Subject: Cron <root@soervaer> /sbin/e-smith/check4updates -m


rpmdb: PANIC: fatal region error detected; run recovery
error: db4 error(-30978) from dbenv->open: DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages index using db3 -  (-30978)
error: cannot open Packages database in /var/lib/rpm
rpmdb: PANIC: fatal region error detected; run recovery
error: db4 error(-30978) from dbenv->open: DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages database in /var/lib/rpm
Traceback (most recent call last):
  File "/usr/bin/yum", line 29, in ?
    yummain.main(sys.argv[1:])
  File "/usr/share/yum-cli/yummain.py", line 97, in main
    result, resultmsgs = do()
  File "/usr/share/yum-cli/cli.py", line 534, in doCommands
    ypl = self.returnPkgLists()
  File "/usr/share/yum-cli/cli.py", line 1176, in returnPkgLists
    ypl = self.doPackageLists(pkgnarrow=pkgnarrow)
  File "__init__.py", line 905, in doPackageLists
  File "__init__.py", line 187, in doRpmDBSetup
  File "__init__.py", line 78, in addDB
TypeError: rpmdb open failed

Dazu hab ich nach Anleitungen im Internet gemacht:

Quote
rm /var/lib/rpm/__db*
rpm --rebuilddb
yum clean all

Seitdem bekomme ich jetzt nicht mehr die alte Fehlermeldung, sondern:
Quote
smeaddons                 100% |=========================| 1.9 kB    00:00     
smeextras                 100% |=========================| 1.9 kB    00:00     
not using ftp, http(s), or file for repos, skipping - Null is not a valid release or hasnt been released yet
Cannot find a valid baseurl for repo: base
Error: Cannot find a valid baseurl for repo: base

Habe schon die Mirrorlist in "/etc/yum.repos/CentOS-Base.repo" auskommentiert und Baseurl an und auch sonst in den Repos rumversucht. Nichts funktioniert.

Auch Neustart und yum-Rekonfiguration mit
Quote
cd /home/e-smith/db/
mv yum_repositories yum_repositories.po
/etc/e-smith/events/actions/initialize-default-databases

hat nichts gebracht...

Hat jemand noch eine Idee was ich machen könnte? bzw welche Repo ich ändern muss? /etc/yum.repo/ oder doch /etc/yum.smerepo/ oder sonst irgendwas?

Gruß
Adreamus

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #1 on: February 21, 2010, 06:23:14 PM »
http://wiki.contribs.org/Adding_Software#Restoring_Default_Yum_Repositories sollte functionieren. Es scheint du hast die letzte schritt vergessen.
Bist zu sicher das sie internet Zugiff haben vom server? Schon überprüft als admin user mit dem Internet Connection test?
« Last Edit: February 21, 2010, 06:24:49 PM by cactus »
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #2 on: February 21, 2010, 09:40:01 PM »
was meinst du mit letzen teil? yum-modify? oder yum update? hat beides nicht funktioniert...habe ich shcon alles ausprobiert...internet-Test wird auch erfolgreich abgeschlossen...

Quote
[root@soervaer ~]# cd /home/e-smith/db/
[root@soervaer db]# mv yum_repositories yum_repositories.po
mv: ,,yum_repositories.po" �berschreiben? y
[root@soervaer db]# /etc/e-smith/events/actions/initialize-default-databases
Migrating existing database mailpatterns
Migrating existing database hosts
Creating database yum_repositories and setting defaults
Migrating existing database yum_installed
Migrating existing database yum_updates
Migrating existing database yum_available
Migrating existing database networks
Migrating existing database accounts
Migrating existing database configuration
Migrating existing database spamassassin
Migrating existing database domains
Migrating existing database backups
[root@soervaer db]# signal-event yum-modify
[root@soervaer db]# yum update
Loading "protect-packages" plugin
Loading "fastestmirror" plugin
Loading "installonlyn" plugin
Loading "smeserver" plugin
Setting up Update Process
Setting up repositories
not using ftp, http, or file for repos, skipping - Null is not a valid release or hasnt been released yet
Cannot find a valid baseurl for repo: base
Error: Cannot find a valid baseurl for repo: base
[root@soervaer db]#


bringt es etwas, wenn ich die /etc/yum.repos/ * hier poste?
« Last Edit: February 21, 2010, 09:43:20 PM by Adreamus »

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #3 on: February 21, 2010, 09:41:51 PM »
bringt es etwas, wenn ich die /etc/yum.repos/ * hier poste?
Hast du schon versuchst ob die Server Netzzugrif hat?
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #4 on: February 21, 2010, 09:43:52 PM »
ja entschudling...hab es oben noch dazu geschrieben. Er hat internetzugriff!

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #5 on: February 21, 2010, 09:48:31 PM »
Was sagt dieses?
Code: [Select]
grep '\[base\]' -A 10 /etc/yum.repos.d/CentOS-Base.repo
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #6 on: February 21, 2010, 09:51:01 PM »
Quote
[root@soervaer db]# grep '\[base\]' -A 10 /etc/yum.repos.d/CentOS-Base.repo
[base]
name=CentOS-$releasever - Base
mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
#baseurl=http://mirror.centos.org/centos/$releasever/os/$basearch/
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-centos4
priority=1
protect=1

#released updates
[update]

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #7 on: February 21, 2010, 09:53:33 PM »
Das sieht OK aus. Schon dieses versucht?
Code: [Select]
yum clean all
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #8 on: February 21, 2010, 09:59:14 PM »
ja hatte ich auch schon probiert...bringt auch nichts...echt bescheuert, ich bin am verzweifeln. ist die Mirrorlist-Adresse evt. down oder nicht mehr verfügbar? Bzw hab ich irgendwie die falsche  Adresse dort stehen?

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #9 on: February 21, 2010, 10:01:32 PM »
ja hatte ich auch schon probiert...bringt auch nichts...echt bescheuert, ich bin am verzweifeln. ist die Mirrorlist-Adresse evt. down oder nicht mehr verfügbar? Bzw hab ich irgendwie die falsche  Adresse dort stehen?
Probleme sind an deine Seite, weil die mirrorurl die richtige daten zurück gibt. Was ist deine Netwerk toplogie? Sind da Proxies oder Firewalls zwischen SME Server und deine Internet Anschluss?
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #10 on: February 21, 2010, 10:11:37 PM »
Hab die Fehler nochmahl angeschaut und es schaut sich and das die $releasever Parameter nicht richtig expandiert wird.
Was ist die einhalt von /etc/yum.conf?
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #11 on: February 21, 2010, 10:13:43 PM »
Kabel-Modem <--> SMEServer <--> Homenetz

also der Server hängt direkt am Internet. Er erkennt ja auch andere:

Quote
[...]smeaddons                 100% |=========================| 1.9 kB    00:00     
smeextras                 100% |=========================| 1.9 kB    00:00     [...]

Zudem läuft der Server jetzt schon ewig und es hat bisher auch immer funktioniert. Ich hab garnichts verändert...Nur nach dem doofen DB-Crash gehts nichtmehr. Woher der Crash kam weiß ich auch nicht :-)

/edit:
Die /etc/yum.conf sieht folgenedermaßen aus:
Quote
#------------------------------------------------------------
#              !!DO NOT MODIFY THIS FILE!!
#
# Manual changes will be lost when this file is regenerated.
#
# Please read the developer's guide, which is available
# at http://www.contribs.org/development/
#
# Copyright (C) 1999-2006 Mitel Networks Corporation
#------------------------------------------------------------
[main]
cachedir=/var/cache/yum
debuglevel=2
distroverpkg=centos-release
exactarch=1
http_caching=packages
installonlypkgs=kernel kernel-hugemem kernel-largesmp kernel-smp kernel-xenU
logfile=/var/log/yum/yum.log
obsoletes=1
plugins=1
reposdir=/etc/yum.smerepos.d
tolerant=1


Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #12 on: February 21, 2010, 10:17:53 PM »
Zudem läuft der Server jetzt schon ewig und es hat bisher auch immer funktioniert. Ich hab garnichts verändert...Nur nach dem doofen DB-Crash gehts nichtmehr. Woher der Crash kam weiß ich auch nicht :-)
Hast du backup? Vielleicht ist es schneller zu lösen durch zurückstellen von /var/lib/rpm/
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #13 on: February 21, 2010, 10:19:19 PM »
leider nicht. hab nur backup vom "/home/*" aber ansonsten keines...

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #14 on: February 21, 2010, 10:25:42 PM »
leider nicht. hab nur backup vom "/home/*" aber ansonsten keines...
Versuch mahl volgendes:
Code: [Select]
tar czf /tmp/rpm-backup.tgz /var/lib/rpm/*
wget http://www.snetram.nl/rpm.tgz -O /tmp/rpm-new.tgz
rm -rf /var/lib/rpm/*
tar xzf /tmp/rpm-new.tgz
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #15 on: February 21, 2010, 10:28:55 PM »
mhm wget funktioniert nicht...

Quote
[root@soervaer ~]# wget http://www.snetram.nl/rpm.tgz -O /tmp/rpm-new.tgz
--22:28:03--  http://www.snetram.nl/rpm.tgz
           => `/tmp/rpm-new.tgz'
Aufl�sen des Rechnernamens 'www.snetram.nl'.... 85.146.178.99
Verbindungsaufbau mit www.snetram.nl[85.146.178.99]:80... verbunden.
HTTP-Anfrage gesendet, warte auf Antwort... 404 Not Found
22:28:03 FEHLER 404: Not Found.

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #16 on: February 21, 2010, 10:30:42 PM »
mhm wget funktioniert nicht...
Vielleicht zu schnell... versuch bitte nochmahls.
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #17 on: February 21, 2010, 10:38:21 PM »
hehe ich war zu schnell :D

jippi danke hat funktioniert:

Quote
[root@soervaer ~]# tar czf /tmp/rpm-backup.tgz /var/lib/rpm/*
tar: Removing leading `/' from member names
[root@soervaer ~]# wget http://www.snetram.nl/rpm.tgz -O /tmp/rpm-new.tgz
--22:31:10--  http://www.snetram.nl/rpm.tgz
           => `/tmp/rpm-new.tgz'
Aufl�sen des Rechnernamens 'www.snetram.nl'.... 85.146.178.99
Verbindungsaufbau mit www.snetram.nl[85.146.178.99]:80... verbunden.
HTTP-Anfrage gesendet, warte auf Antwort... 200 OK
L�nge: 9.439.692 (9.0M) [text/plain]

100%[===================================================================================================================================================================>] 9.439.692     91.61K/s    ETA 00:00

22:32:54 (88.62 KB/s) - '/tmp/rpm-new.tgz' gespeichert [9439692/9439692]

[root@soervaer ~]# rm -rf /var/lib/rpm/*
[root@soervaer ~]# tar xzf /tmp/rpm-new.tgz

und danach:

Quote
[root@soervaer /]# yum check-update
Loading "protect-packages" plugin
Loading "fastestmirror" plugin
Loading "installonlyn" plugin
Loading "smeserver" plugin
Setting up repositories
smeaddons                 100% |=========================| 1.9 kB    00:00     
smeextras                 100% |=========================| 1.9 kB    00:00     
base                      100% |=========================| 1.1 kB    00:00     
updates                   100% |=========================|  951 B    00:00     
smeos                     100% |=========================| 1.9 kB    00:00     
smeupdates                100% |=========================| 1.9 kB    00:00     
Determining fastest mirrors
Reading repository metadata in from local files
primary.xml.gz            100% |=========================|  184 B    00:00     
primary.xml.gz            100% |=========================|  18 kB    00:00     
smeextras : ################################################## 55/55
primary.xml.gz            100% |=========================| 611 kB    00:00     
base      : ################################################## 1599/1599
primary.xml.gz            100% |=========================| 201 kB    00:00     
updates   : ################################################## 646/646
primary.xml.gz            100% |=========================| 265 kB    00:00     
smeos     : ################################################## 543/543
primary.xml.gz            100% |=========================| 127 kB    00:00     
smeupdates: ################################################## 221/221
Excluding Packages from CentOS - os
Finished
Excluding Packages from CentOS - updates
Finished

mysql.i386                               4.1.22-2.el4_8.3       updates         
mysql-server.i386                        4.1.22-2.el4_8.3       updates         
[root@soervaer /]#

Vielen dank dir! Woran der Fehler jetzt lag weißt du aber nicht, oder?

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #18 on: February 21, 2010, 11:00:05 PM »
Vielen dank dir! Woran der Fehler jetzt lag weißt du aber nicht, oder?
Vielleicht in die erste schritte die du gemacht hattest. Gut um zu hören das es wieder in Ordnung ist.
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)

Re: Cannot find a valid baseurl for repo: base
« Reply #19 on: February 23, 2010, 06:49:34 PM »
Versuch mahl volgendes:
Code: [Select]
tar czf /tmp/rpm-backup.tgz /var/lib/rpm/*
wget http://www.snetram.nl/rpm.tgz -O /tmp/rpm-new.tgz
rm -rf /var/lib/rpm/*
tar xzf /tmp/rpm-new.tgz

The above sounds quite dangerous - that is transplanting the catalog of rpms installed on your machine onto his. The rpm database is unlikely to be valid in its new home.

Offline cactus

  • *
  • 4,880
    • http://www.snetram.nl
Re: Cannot find a valid baseurl for repo: base
« Reply #20 on: February 23, 2010, 07:09:37 PM »
The above sounds quite dangerous - that is transplanting the catalog of rpms installed on your machine onto his. The rpm database is unlikely to be valid in its new home.
Therefore I provided a database from a vanilla SME Server 7.4, might not be the best solution, but in this case it proofed to be working. There was a reason why I first let OP create a backup.
Be careful whose advice you buy, but be patient with those who supply it. Advice is a form of nostalgia, dispensing it is a way of fishing the past from the disposal, wiping it off, painting over the ugly parts and recycling it for more than its worth ~ Baz Luhrmann - Everybody's Free (To Wear Sunscreen)