Results 1 to 5 of 5

Thread: Unable to install or update via terminal and Yast.

  1. #1

    Default Unable to install or update via terminal and Yast.

    Hello,
    I am new to OpenSUSE, my experience as a user is just three days and I have already bounced into trouble. I am unable to install anything or update via terminal and Yast both. Whenever I am trying to do an update by
    "sudo zypper up"
    or
    "sudo zypper in vlc"
    terminal its giving back the following result :
    linux-v0l3:/home/rahul # sudo zypper up
    terminate called after throwing an instance of 'zypp:: parser:: ParseException'
    what(): /etc/zypp/zypp.conf: Section []: Line 2 contains garbage (no '=' or ',|/\' in key)
    and

    sudo zypper in vlc
    terminate called after throwing an instance of 'zypparserparseException'
    what(): /etc/zypp/zypp.conf: Section []: Line 2 contains garbage (no '=' or ',|/\' in key)
    .
    Output is same while trying to do the same via Yast. When I am clicking online update or software management its showing
    Accessing the software management failed. /etc/zypp/zypp.conf: Section []: Line 2 contains garbage (no '=' or ',|/\' in key)
    .
    This problem has started after I made a change in
    etc/zypp/zypp.conf
    and changed the value from 'false' to 'true' in
    solver.allowVendorChange = true
    in the terminal via 'VIM'.
    I will be grateful if any kind of help regarding this is provided to me, thanks in advance.

  2. #2
    Join Date
    May 2012
    Location
    Finland
    Posts
    2,004

    Default Re: Unable to install or update via terminal and Yast.

    Well, could you copy paste the first 5 lines of your zypp.conf? :-)

    It's pretty clear there are some extra characters in the configuration file - perhaps you did a :wq or similar and ended up adding some characters to the start of the file.
    .: miuku #suse @ irc.freenode.net
    :: miuku@opensuse.org

    .: h​ttps://download.opensuse.org/repositories/home:/Miuku/

  3. #3

    Default Re: Unable to install or update via terminal and Yast.

    Thanks for replying Miuku, :)
    Well here is the first part of my /etc/zypp/zypp.conf as follows :
    ## Configuration file for software management## /etc/zypp/zypp.conf
    ##
    ## Boolean values are 0 1 yes no on off true false




    [main]




    ##
    ## Override the detected architecture
    ##
    ## Valid values: i586, i686, x86_64, ppc, ppc64, ia64, s390, s390x, ..
    ## Default value: Autodetected
    ##
    ## ** CAUTION: Only set if you know what you're doing !
    ## ** Changing this needs a full refresh (incl. download)
    ## ** of all repository data.
    ##
    # arch = s390




    ##
    ## Path where the caches are kept.
    ##
    ## Valid values: A directory
    ## Default value: /var/cache/zypp
    ##
    # cachedir = /var/cache/zypp




    ##
    ## Path where the repo metadata is downloaded and kept.
    ##
    ## Valid values: A directory
    ## Default value: {cachedir}/raw
    ##
    ## Changing this needs a full refresh (incl. download) of all repository data
    ##
    # metadatadir = /var/cache/zypp/raw




    ##
    ## Path where the repo solv files are created and kept.
    ##
    ## Valid values: A directory
    ## Default value: {cachedir}/solv
    ##
    # solvfilesdir = /var/cache/zypp/solv




    ##
    ## Path where the repo packages are downloaded and kept.
    ##
    ## Valid values: A directory
    ## Valid values: A directory
    ## Default value: {cachedir}/packages
    ##
    # packagesdir = /var/cache/zypp/packages




    ##
    ## Path where the configuration files are kept.
    ##
    ## Valid values: A directory
    ## Default value: /etc/zypp
    ##
    # configdir = /etc/zypp


    ##
    ## Path where the known repositories .repo files are kept
    ##
    ## Valid values: A directory
    ## Default value: {configdir}/repos.d
    ##
    ## Changing this invalidates all known repositories
    ##
    # reposdir = /etc/zypp/repos.d


    ##
    ##
    ## Path where the known services .service files are kept
    ##
    ## Valid values: A directory
    ## Default value: {configdir}/services.d
    ##
    ## Changing this invalidates all known services
    ##
    # servicesdir = /etc/zypp/services.d




    ##
    ## Whether repository urls should be probed when added


    ## Valid values: boolean
    ## Default value: false
    ##
    ## If true, accessability of repositories is checked immediately (when added)
    ## (e.g. 'zypper ar' will check immediately)
    ## If false, accessability of repositories is checked when refreshed
    ## (e.g. 'zypper ar' will delay the check until the next refresh)
    ##
    # repo.add.probe = false
    ##
    ## Amount of time in minutes that must pass before another refresh.
    ##
    ## Valid values: Integer
    ## Default value: 10
    ##
    ## If you have autorefresh enabled for a repository, it is checked for
    ## up-to-date metadata not more often than every <repo.refresh.delay>
    ## minutes. If an automatic request for refresh comes before <repo.refresh.delay>
    ## minutes passed since the last check, the request is ignored.
    ##
    ## A value of 0 means the repository will always be checked. To get the oposite
    ## effect, disable autorefresh for your repositories.
    ##
    ## This option has no effect for repositories with autorefresh disabled, nor for
    ## user-requested refresh.
    ##
    # repo.refresh.delay = 10


    ##
    ## Translated package descriptions to download from repos.
    ##
    ## A list of locales for which translated package descriptions should
    ## be downloaded, in case they are availavble and the repo supports this.
    ## Not all repo formats support downloading specific translations only.
    ##
    ## Valid values: List of locales like 'en', 'en_US'...
    ## Default value: RequestedLocales
    ##
    ## If data for a specific locale are not available, we try to find some
    ## fallback. Translations for 'en' are always downloaded.
    ##
    # repo.refresh.locales = en, de


    ##
    ## Maximum number of concurrent connections to use per transfer
    ##
    ## Valid values: Integer
    ## Default value: 5
    ##
    ## This setting is only used if more than one is possible
    ## Setting it to a reasonable number avoids flooding servers
    ##
    # download.max_concurrent_connections = 5


    ##
    ## Sets the minimum download speed (bytes per second)
    ## until the connection is dropped
    ## This can be useful to prevent security attacks on hosts by
    ## providing updates at very low speeds.
    ##
    ## 0 means no limit
    ##
    # download.min_download_speed = 0


    ## Maximum download speed (bytes per second)
    ## 0 means no limit
    # download.max_download_speed = 0


    ## Number of tries per download which will be
    ## done without user interaction
    ## 0 means no limit (use with caution)
    # download.max_silent_tries = 5


    ##
    ## Maximum time in seconds that you allow a transfer operation to take.
    ##
    ## This is useful for preventing your batch jobs from hanging for hours due
    ## to slow networks or links going down. Limiting operations to less than a
    ## few minutes risk aborting perfectly normal operations.
    ##
    ## Valid values: [0,3600]
    ## Default value: 180
    ##
    # download.transfer_timeout = 180


    ##
    ## Whether to consider using a .delta.rpm when downloading a package
    ##
    ## Valid values: boolean
    ## Default value: true
    ##
    ## Using a delta rpm will decrease the download size for package updates
    ## since it does not contain all files of the package but only the binary
    ## diff of changed ones. Recreating the rpm package on the local machine
    ## is an expensive operation (memory,CPU). If your network connection is
    ## not too slow, you benefit from disabling .delta.rpm.
    ##
    # download.use_deltarpm = true


    ##
    ## Whether to consider using a deltarpm even when rpm is local
    ##
    ## Valid values: boolean
    ## Default value: false
    ##
    ## This option has no effect unless download.use_deltarpm is set true.
    ##
    # download.use_deltarpm.always = false
    #
    ## Hint which media to prefer when installing packages (download vs. CD).
    ##
    ## Valid values: download, volatile
    ## Default value: download
    ##
    ## Note that this just a hint. First of all the solver will choose the 'best'
    ## package according to its repos priority, version and architecture. But if
    ## there is a choice, we will prefer packages from the desired media.
    ##
    ## Packages available locally are always preferred. The question is whether
    ## you prefer packages being downloaded via FTP/HTTP/HTTPS (download), rather
    ## than being prompted to insert a CD/DVD (volatile), in case they are available
    ## on both media.
    ##
    ## Name | Priority | URI
    ## openSUSE-11.1 99 dvd:///
    ## openSUSE-11.1-Oss 99 http://download.opensuse.org/distribution/11.1/repo/oss
    ##
    ## In the above example 2 repositories with similar content are used. Rather
    ## than raising the priority of one of them to 'prefer' a certain media, you
    ## should use the same priority for both and set download.media_preference
    ## instead.
    ##
    ## download.media_preference = download
    ##
    ## Commit download policy to use as default.
    ##
    ## DownloadOnly, Just download all packages to the local cache.
    ## Do not install. Implies a dry-run.
    ##
    ## DownloadInAdvance, First download all packages to the local cache.
    ## Then start to install.
    ##
    ## DownloadInHeaps, Similar to DownloadInAdvance, but try to split
    ## the transaction into heaps, where at the end of
    ## each heap a consistent system state is reached.
    ##
    ## DownloadAsNeeded Alternating download and install. Packages are
    ## cached just to avid CD/DVD hopping. This is the
    ## traditional behaviour.
    ##
    ## <UNSET> If a value is not set, empty or unknown, we pick
    ## some sane default.
    ##
    ## commit.downloadMode =


    ##
    ## Defining directory which contains vendor description files.
    ##
    ## One file in this directory reflects a group of equivalent vendors. e.G.:
    ## (filename is "nvidia" but could be any other name):
    ## ------------------------- file contains begin -----------------------
    ## [main]
    ##
    ## vendors = nvidia,suse,opensuse
    ##
    ## ------------------------- file contains end --------------------------

  4. #4
    Join Date
    May 2012
    Location
    Finland
    Posts
    2,004

    Default Re: Unable to install or update via terminal and Yast.

    The first few lines clearly contain something that makes zypper choke - mainly line 2.

    Make a copy of the zypp.conf and delete the first 3 lines and see if it fixes the issue.
    .: miuku #suse @ irc.freenode.net
    :: miuku@opensuse.org

    .: h​ttps://download.opensuse.org/repositories/home:/Miuku/

  5. #5

    Default Re: Unable to install or update via terminal and Yast.

    Hi,

    I always tell folks to make a backup of anything/everything before they do some modification/editing regardless how/what type of editor you are using. That being said you can compare
    something.

    Assuming diff is installed you can do this to compare your zypp.conf to my default zypp.conf
    Code:
    diff -u /etc/zypp/zypp.conf <(curl -Lsf http://paste.opensuse.org/view/raw/97198435)
    Note that diff has many options, try it without an option as well.

    You can replace your zypp.conf also

    This needs to be run as root directly and it will replace your zypp.conf at once.
    Code:
    curl -Lsf http://paste.opensuse.org/view/raw/97198435 > /etc/zypp/zypp.conf
    If you don't wan to run curl as root then you can just redirect it to a temp file probably in /tmp.

    As a normal user run.
    Code:
    curl -Lsf http://paste.opensuse.org/view/raw/97198435 > /tmp/zypp.conf
    Then just copy it to your zypp.conf

    Code:
    cp -v /tmp/zypp.conf /etc/zypp/zypp.conf
    "Unfortunately time is always against us" -- [Morpheus]

    .:https://github.com/Jetchisel:.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •