Zypper Repository type can't be determined

When attempting to upgrade to leap 16.0 beta I encountered the errors shown below.

The repoindex.xml linked to opensuse-leap-repoindex.xml is from openSUSE-repos-Leap-20250303.

Why is this happening?

USS-Liberty:~ # zypper dup
Refreshing service 'openSUSE'.
Retrieving repository 'repo-non-oss ()' metadata ..............................................................................................................................................................................................[error]
Repository 'repo-non-oss ()' is invalid.
[openSUSE:repo-non-oss|http://cdn.opensuse.org/distribution/leap//repo/non-oss?mediahandler=curl2] Failed to retrieve new repository metadata.
History:
 - [openSUSE:repo-non-oss|http://cdn.opensuse.org/distribution/leap//repo/non-oss?mediahandler=curl2] Repository type can't be determined.
Please check if the URIs defined for this repository are pointing to a valid repository.
Warning: Skipping repository 'repo-non-oss ()' because of the above error.
Retrieving repository 'repo-oss ()' metadata ..................................................................................................................................................................................................[error]
Repository 'repo-oss ()' is invalid.
[openSUSE:repo-oss|http://cdn.opensuse.org/distribution/leap//repo/oss?mediahandler=curl2] Failed to retrieve new repository metadata.
History:
 - [openSUSE:repo-oss|http://cdn.opensuse.org/distribution/leap//repo/oss?mediahandler=curl2] Repository type can't be determined.
Please check if the URIs defined for this repository are pointing to a valid repository.
Warning: Skipping repository 'repo-oss ()' because of the above error.
Retrieving repository 'update-backports ()' metadata ..........................................................................................................................................................................................[error]
Repository 'update-backports ()' is invalid.
[openSUSE:update-backports|http://cdn.opensuse.org/update/leap//backports?mediahandler=curl2] Failed to retrieve new repository metadata.
History:
 - [openSUSE:update-backports|http://cdn.opensuse.org/update/leap//backports?mediahandler=curl2] Repository type can't be determined.
Please check if the URIs defined for this repository are pointing to a valid repository.
Warning: Skipping repository 'update-backports ()' because of the above error.
Retrieving repository 'update-non-oss ()' metadata ............................................................................................................................................................................................[error]
Repository 'update-non-oss ()' is invalid.
[openSUSE:update-non-oss|http://cdn.opensuse.org/update/leap//non-oss?mediahandler=curl2] Failed to retrieve new repository metadata.
History:
 - [openSUSE:update-non-oss|http://cdn.opensuse.org/update/leap//non-oss?mediahandler=curl2] Repository type can't be determined.
Please check if the URIs defined for this repository are pointing to a valid repository.
Warning: Skipping repository 'update-non-oss ()' because of the above error.
Retrieving repository 'update-oss ()' metadata ................................................................................................................................................................................................[error]
Repository 'update-oss ()' is invalid.
[openSUSE:update-oss|http://cdn.opensuse.org/update/leap//oss?mediahandler=curl2] Failed to retrieve new repository metadata.
History:
 - [openSUSE:update-oss|http://cdn.opensuse.org/update/leap//oss?mediahandler=curl2] Repository type can't be determined.
Please check if the URIs defined for this repository are pointing to a valid repository.
Warning: Skipping repository 'update-oss ()' because of the above error.
Retrieving repository 'update-sle ()' metadata ................................................................................................................................................................................................[error]
Repository 'update-sle ()' is invalid.
[openSUSE:update-sle|http://cdn.opensuse.org/update/leap//sle?mediahandler=curl2] Failed to retrieve new repository metadata.
History:
 - [openSUSE:update-sle|http://cdn.opensuse.org/update/leap//sle?mediahandler=curl2] Repository type can't be determined.
Please check if the URIs defined for this repository are pointing to a valid repository.
Warning: Skipping repository 'update-sle ()' because of the above error.
Some of the repositories have not been refreshed because of an error.

    dist-upgrade: Due to the treatment of orphaned packages dist-upgrade depends on a proper
    repository setup more than any other command. It must not continue if enabled repositories fail
    to refresh. This may severely damage the system. If a failing repository is actually not needed,
    it must be disabled. See 'man zypper' for more information about this command.
USS-Liberty:~ # 

I am not using Leap 16 in any form, but I would expect that the URLs of the standard repos would mention “16” somewhere. I do not see that in your code above.

Maybe better start is to check/post your repo list (including URLs)?

Sorry if my post is confusing. I haven’t gotten that far. I just figured someone else might have encountered the problem while attempting the upgrade. This is a problem with 15.6.

The version number is missing.

That’s not my fault. At least I don’t think it is. the version number should come from:

USS-Liberty:~ # cat /etc/os-release
NAME="SLES" 
VERSION="15-SP6" 
VERSION_ID="15.6"
PRETTY_NAME="SUSE Linux Enterprise Server 15 SP6"
ID="sles"
ID_LIKE="suse"
ANSI_COLOR="0;32" 
CPE_NAME="cpe:/o:suse:sles:15:sp6"
DOCUMENTATION_URL="https://documentation.suse.com/"
USS-Liberty:~ # 

It should be used when parsing this:

USS-Liberty:~ # cat /usr/share/zypp/local/service/openSUSE/repo/opensuse-leap-repoindex.xml 
<repoindex ttl="0"
    disturl="http://cdn.opensuse.org"
    distsub="leap"
    distver="${releasever}"
    debugenable="false"
    sourceenable="false">

<repo url="%{disturl}/distribution/%{distsub}/%{distver}/repo/oss?mediahandler=curl2"
    alias="repo-oss"
    name="%{alias} (%{distver})"
    enabled="true"
    autorefresh="true"/>

<repo url="%{disturl}/debug/distribution/%{distsub}/%{distver}/repo/oss?mediahandler=curl2"
    alias="repo-oss-debug"
    name="%{alias} (%{distver})"
    enabled="false"
    autorefresh="true"/>

<repo url="%{disturl}/source/distribution/%{distsub}/%{distver}/repo/oss?mediahandler=curl2"
    alias="repo-oss-source"
    name="%{alias} (%{distver})"
    enabled="false"
    autorefresh="true"/>

<repo url="%{disturl}/distribution/%{distsub}/%{distver}/repo/non-oss?mediahandler=curl2"
    alias="repo-non-oss"
    name="%{alias} (%{distver})"
    enabled="true"
    autorefresh="true"/>

<repo url="%{disturl}/debug/distribution/%{distsub}/%{distver}/repo/non-oss?mediahandler=curl2"
    alias="repo-non-oss-debug"
    name="%{alias} (%{distver})"
    enabled="false"
    autorefresh="true"/>

<repo url="http://codecs.opensuse.org/openh264/openSUSE_Leap?mediahandler=curl2"
    alias="repo-openh264"
    name="%{alias} (%{distver})"
    enabled="true"
    autorefresh="true"/>

<repo url="%{disturl}/update/%{distsub}/%{distver}/oss?mediahandler=curl2"
    alias="update-oss"
    name="%{alias} (%{distver})"
    enabled="true"
    autorefresh="true"/>

<repo url="%{disturl}/debug/update/%{distsub}/%{distver}/oss?mediahandler=curl2"
    alias="update-oss-debug"
    name="%{alias} (%{distver})"
    enabled="false"
    autorefresh="true"/>

<repo url="%{disturl}/update/%{distsub}/%{distver}/non-oss?mediahandler=curl2"
    alias="update-non-oss"
    name="%{alias} (%{distver})"
    enabled="true"
    autorefresh="true"/>

<repo url="%{disturl}/debug/update/%{distsub}/%{distver}/non-oss?mediahandler=curl2"
    alias="update-non-oss-debug"
    name="%{alias} (%{distver})"
    enabled="false"
    autorefresh="true"/>

<repo url="%{disturl}/update/%{distsub}/%{distver}/backports?mediahandler=curl2"
    alias="update-backports"
    name="%{alias} (%{distver})"
    enabled="true"
    autorefresh="true"/>

<repo url="%{disturl}/update/%{distsub}/%{distver}/backports_debug?mediahandler=curl2"
    alias="update-backports-debug"
    name="%{alias} (%{distver})"
    enabled="false"
    autorefresh="true"/>

<repo url="%{disturl}/update/%{distsub}/%{distver}/sle?mediahandler=curl2"
    alias="update-sle"
    name="%{alias} (%{distver})"
    enabled="true"
    autorefresh="true"/>

<repo url="%{disturl}/debug/update/%{distsub}/%{distver}/sle?mediahandler=curl2"
    alias="update-sle-debug"
    name="%{alias} (%{distver})"
    enabled="false"
    autorefresh="true"/>

</repoindex>

Of of that is off the shelf.

It is openSUSE forums, not SLES forums.

That’s what’s in the file. I have never used SLES.

As long as you do not post the repo list as it is

zypper lr -d

people can not say much about correctness.

Also, you just show a zypper dup command without explaining what it is supposed to do. Depending on the way you try to upgrade to 16.0 (which you also did not communicate to us) this may be an incorrect command (e.g. for on-line upgrade you need a --releasever 16.0 global option, or you need manual updated repo URLs).

Strange. This is my fully updated Leap 15.6 system:

henk@boven:~> cat /etc/os-release 
NAME="openSUSE Leap"
VERSION="15.6"
ID="opensuse-leap"
ID_LIKE="suse opensuse"
VERSION_ID="15.6"
PRETTY_NAME="openSUSE Leap 15.6"
ANSI_COLOR="0;32"
CPE_NAME="cpe:/o:opensuse:leap:15.6"
BUG_REPORT_URL="https://bugs.opensuse.org"
HOME_URL="https://www.opensuse.org/"
DOCUMENTATION_URL="https://en.opensuse.org/Portal:Leap"
LOGO="distributor-logo-Leap"
henk@boven:~> 

You definitely have one reporting SLES.

Mayebe even a better check of the URLs will be

cd /etc/zypp/repos.d
grep base *.repo

That will show if your repos are correct with $releasever (and thus your SLES is to blame), or that you repolist is broken.

I think one reason all this is puzzling is because an important (missing) piece is found in your other recent thread about this subject matter.

In that other post is Preformatted Text output … I think that is where your configuration got botched … the link:
.

I did not really read the other thread, but glanced through it. I am unaware of any “upgrade too”, but whatever it says

zypper dup --releasever 16.0

is wrong. --releasever is a global option and thus should be before the zypper command:

zypper --releasever 16.0 dup

This comment without any further valuation of what was done there or if the zypper command as shown now is what I would use on a Leap version upgrade.

The result is the same for zipper refresh. YaST also gives errors. It might be from trying to migrate to slowroll. I gave up when I had close to 5000 conflicts to resolve by hand.

--releasever is unrecognized by zypper.

As long as you do not show real life code, I at least will not comment.

That is utter nonsense. When you put the parameter in the wrong place (as you did in the other thread), it will not function of course

@Ljosalfr it’s zypper --releasever=16.0

https://en.opensuse.org/SDB:System_upgrade

Hmm. There’s obviously some disconnect with the use of
zypper with arg:
–releasever

And the proper format and arrangement.

We see three versions:

  1. zypper dup --releasever 16.0
  2. zypper --releasever 16.0 dup
  3. zypper releasever=16.0 (equal sign used)

The cited document shows #1 … so my guess is two of the three are rwong.

If #1 is rwong, then the documentation link is incorrect.

That’s what I started with. But now the configuration is fubar. For some reason zipper lost track of the releasever setting it uses by default. When I try to change the repositories I get

“Repository ‘repo-oss ()’ is managed by service ‘openOUSE’. Your manual changes might be reset by the next service refresh!”

15.6 should be in the parentheses.