re yum troubles

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi list,
Still having problems with yum.
When doing $ yum update> the following lines show up:

$ yum update
Traceback (most recent call last):
  File "/usr/bin/yum", line 30, in ?
    yummain.main(sys.argv[1:])
  File "/usr/share/yum/yummain.py", line 163, in main
    (log, errorlog, filelog, conf, cmds) = parseCmdArgs(args)
  File "/usr/share/yum/yummain.py", line 75, in parseCmdArgs
    conf=yumconf(configfile=yumconffile)
  File "/usr/share/yum/config.py", line 48, in __init__
    self.cfg.read(configfile)
  File "/usr/lib/python2.3/ConfigParser.py", line 263, in read
    self._read(fp, filename)
  File "/usr/lib/python2.3/ConfigParser.py", line 456, in _read
    raise MissingSectionHeaderError(fpname, lineno, `line`)
ConfigParser.MissingSectionHeaderError: File contains no section headers.
file: /etc/yum.conf, line: 1
'\xef\xbb\xbf[main]\n'

Then I am asked to "update the headers on my system".

It suggests that there is something wrong with te first characters in line 1in yum.conf, which should be only [main]. But this is not the case as you can see.
$ less /etc/yum.conf


[main]
cachedir=/var/cache/yum
debuglevel=2
logfile=/var/log/yum.log
pkgpolicy=newest
distroverpkg=redhat-release
tolerant=1
exactarch=1
retries=20
[base]
name=Fedora Core $releasever - $basearch - Base
baseurl=http://download.fedora.redhat.com/pub/fedora/linux/core/$releasever/$basearch/os/
[updates-released]
name=Fedora Core $releasever - $basearch - Released Updates
baseurl=http://download.fedora.redhat.com/pub/fedora/linux/core/updates/$releasever/$basearch/
#[updates-testing]
#name=Fedora Core $releasever - $basearch - Unreleased Updates
#baseurl=http://download.fedora.redhat.com/pub/fedora/linux/core/updates/testing:
/$releasever/$basearch/


#[development]
#name=Fedora Core $releasever - Development Tree
#baseurl=http://download.fedora.redhat.com/pub/fedora/linux/core/development/$basearch/


[freshrpms]
name=Fedora Linux $releasever - $basearch - freshrpms
baseurl=http://ayo.freshrpms.net/fedora/linux/$releasever/$basearch/freshrpms/
gpgcheck=1


[dag]
name=Dag RPM Repository for Fedora Core
baseurl=http://apt.sw.be/fedora/$releasever/en/$basearch/dag/
gpgcheck=1


It must have something to do with missing headers.
In /usr/lib/python2.3/ConfigParser.py I found a text giving clues to the error message, but don't know what it all means.


class MissingSectionHeaderError(ParsingError):
"""Raised when a key-value pair is found before any section header."""
def __init__(self, filename, lineno, line):
Error.__init__(
self,
'File contains no section headers.\nfile: %s, line: %d\n%s' %
(filename, lineno, line))
self.filename = filename
self.lineno = lineno
self.line = line

How can I update the headers on my system?
Does anyone have a suggestion? Being a starter in Linux this is too complicated for me.
Thanks, Peter.





[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux