Problem:
I am trying to kickstart a centos 8. However it fails. It doesn’t seem to find the AppStream repository although it’s configured in the kickstart file.
Foreman and Proxy versions:
foreman 2.3.1
katello 3.18.1
Distribution and version:
CentOS 7.9.2009
Other relevant data:
The rendered kickstart template correctly contains the urls:
url --url http://foreman.example.com/pulp/repos/ORG/Production/centos8/custom/centos8/BaseOS_x86_64/
# renamed from "http://foreman.example.com/pulp/repos/ORG/Production/centos8/custom/centos8/AppStream_x86_64/" for CentOS Anaconda to work
repo --name AppStream --baseurl http://foreman.example.com/pulp/repos/ORG/Production/centos8/custom/centos8/AppStream_x86_64/
both URLs are correct and show the corresponding content. It’s also correctly on the kickstarting server at /run/install/ks.cfg.
However the anaconda log shows
ERR payload.manager: PayloadError: Failed to download metadata for repo 'AppStream': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
The httpd access logs on the foreman server shows these accessed URIs:
It’s a known issue and as far as I know it’s not fixed yet. There is a workaround though. This is my file paths and it might differ on your setup. Hope it helps.
# edit .treeinfo file
/var/lib/pulp/published/yum/https/repos/Default_Organization/Library/custom/CentOS/centos-8_2-baseos-x86_64/.treeinfo
# at bottom of file change from:
[variant-AppStream]
id = AppStream
name = AppStream
packages = ../../../AppStream/x86_64/os/Packages
repository = ../../../AppStream/x86_64/os/
type = variant
uid = AppStream
# Change to
[variant-AppStream]
id = AppStream
name = AppStream
packages = ../AppStream/x86_64/os/Packages
repository = ../AppStream/x86_64/os/
type = variant
uid = AppStream
I was having the same issue with provisioning from Satellite 6.8.2, but only with CentOS 8 Stream. CentOS 8 Linux worked fine. Changing the end of the .treeinfo file referenced above resolved the issue:
[variant-AppStream]
id = AppStream
name = AppStream
packages = Packages
repository = .
type = variant
uid = AppStream
After syncing the repo on my Satellite server, the relative pathname to the repository in the .treeinfo file was …/…/. Changing it to “repository = .” allowed provisioning to work.
Thanks for posting your video. I’ll watch it when I get a chance.