From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.1) Gecko/20021003 Description of problem: When I run the up2date program I get an error message. Note: I think this started after I had the same problem discribed at: http://www.rpm.org/hintskinks/repairdb/ and followed the directions there to fix that problem, but now I get this error message when I run up2date: Traceback (most recent call last): File "/usr/sbin/up2date", line 20, in ? from up2date_client import rpcServer File "/usr/share/rhn/up2date_client/rpcServer.py", line 10, in ? import up2dateAuth File "/usr/share/rhn/up2date_client/up2dateAuth.py", line 6, in ? import rpmSource File "/usr/share/rhn/up2date_client/rpmSource.py", line 11, in ? import up2dateUtils File "/usr/share/rhn/up2date_client/up2dateUtils.py", line 15, in ? import rpmUtils File "/usr/share/rhn/up2date_client/rpmUtils.py", line 261, in ? rpm_version = getRpmVersion() File "/usr/share/rhn/up2date_client/rpmUtils.py", line 257, in getRpmVersion raise up2dateErrors.RpmError("Couldn't determine what version of rpm you are running.\nIf you get this error, try running \n\n\t\trpm --rebuilddb\n\n") up2date_client.up2dateErrors.RpmError: RPM error. The message was: Couldn't determine what version of rpm you are running. If you get this error, try running rpm --rebuilddb I tryed running the rpm --rebuilddb which just returned back to the prompt with no message. Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1.just have to run up2date 2. 3. Actual Results: Traceback (most recent call last): File "/usr/sbin/up2date", line 20, in ? from up2date_client import rpcServer File "/usr/share/rhn/up2date_client/rpcServer.py", line 10, in ? import up2dateAuth File "/usr/share/rhn/up2date_client/up2dateAuth.py", line 6, in ? import rpmSource File "/usr/share/rhn/up2date_client/rpmSource.py", line 11, in ? import up2dateUtils File "/usr/share/rhn/up2date_client/up2dateUtils.py", line 15, in ? import rpmUtils File "/usr/share/rhn/up2date_client/rpmUtils.py", line 261, in ? rpm_version = getRpmVersion() File "/usr/share/rhn/up2date_client/rpmUtils.py", line 257, in getRpmVersion raise up2dateErrors.RpmError("Couldn't determine what version of rpm you are running.\nIf you get this error, try running \n\n\t\trpm --rebuilddb\n\n") up2date_client.up2dateErrors.RpmError: RPM error. The message was: Couldn't determine what version of rpm you are running. If you get this error, try running rpm --rebuilddb Expected Results: The up2date should have run to get the system updates. Additional info: RPM version 4.1
One of the first things that up2date does is attempt to determine what release the system is, and what version it is. It does this by queriying the database for the version-release of packages that provide "redhat-release" and the "rpm" package. It sounds like your database doesnt include one of these (they are both prereqs for up2date, so should always be installed...)
also, the traceback should be fixed in 3.0.21 or higher versions (not released yet), and instead just a error message printed.
With up2date-3.1.15-7, getting this message when redhat-release has been removed from the system and I attempt to register: Traceback (most recent call last): File "gui.py", line 733, in onProfilePagePrepare label.set_text(up2dateUtils.getVersion()) File "/usr/share/rhn/up2date_client/up2dateUtils.py", line 151, in getVersion release, version = getOSVersionAndRelease() File "/usr/share/rhn/up2date_client/up2dateUtils.py", line 144, in getOSVersionAndRelease raise up2dateErrors.RpmError( up2date_client.up2dateErrors.RpmError: RPM error. The message was: Could not determine what version of Red Hat Linux you are running. If you get this error, try running rpm --rebuilddb Reporting this only because you stated that the traceback was gone and therefore I was expecting an error message.
should be fixed in 3.1.18 (gui error dialog now instead of traceback)
rpm -q up2date up2date-3.1.23-1 I didn't get gui error, I got the same traceback.
OK so ... I get the same error message after I have created a NEW database (ie .rpm --initdb /tmp/RH9 ) .. which of course will not have RPM or redhat-release packages in it because of course its a NEW database. so I have a catch 22 here ?? what do I do so I can load this new database ? thanks up2date-nox --justdb --dbpath /tmp/RH9 --dry-run --nosig Traceback (most recent call last): File "/usr/sbin/up2date-nox", line 993, in ? main() File "/usr/sbin/up2date-nox", line 612, in main up2dateAuth.updateLoginInfo() File "up2dateAuth.py", line 112, in updateLoginInfo File "up2dateAuth.py", line 96, in login File "up2dateAuth.py", line 48, in maybeUpdateVersion File "/usr/share/rhn/up2date_client/up2dateUtils.py", line 151, in getVersion release, version = getOSVersionAndRelease() File "/usr/share/rhn/up2date_client/up2dateUtils.py", line 144, in getOSVersionAndRelease raise up2dateErrors.RpmError( up2date_client.up2dateErrors.RpmError: RPM error. The message was: Could not determine what version of Red Hat Linux you are running. If you get this error, try running rpm --rebuilddb