
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 11.6K Views
I configured in /etc/yum.repos.d/http.repo file two http:// repositories. The URLs of the repositories were given. I did not add the gpgcheck and enabled directives as per man pages of yum.conf they are 0 (disabled), respectively 1 (enabled)
The dnf repolist shows the repositories id and name but does not show the Status column ( with number of packages each contain).
I cannot dnf install any package/module/package group but dnf search key_word and dnf list provide output.
resolv.conf file was checked and was updated with the nameserver configured.
What would be the reason I cannot dnf install ?
Thank you.
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 11.5K Views
Hi @Yeni84
1. Ensure both your repositories are enabled ( enabled=1 ) and checking with a "dnf repolist" command.
2. Ensure you have repodata directory in both the repository locations. This is important for yum/dnf to get information regarding the packages in your repository.
3. After step 1 & step 2, try passing " dnf install tree -y --nogpgcheck". The main yum.conf file has a definition of gpgcheck=1 which means it would do a gpgcheck but in your repositories, you haven't configured any gpg keys. ( Assuming that this is our testing env )
Hope this helps! :)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 11.6K Views
When you browse to the repository URL, do you see a directory called repodata?
What are the contents of /etc/redhat-release and /etc/yum.repos.d/http.repo?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 11.6K Views
Yes, I can see the directory called repodata.
[user1@base-server82 ~]$ cat /etc/redhat-release
Red Hat Enterprise Linux release 8.2 (Ootpa)
[root@server-base ~]# cat /etc/yum.repos.d/http.repo
[HTTP_BaseOS]
name=HTTPlocalrepo_BaseOS
baseurl=http://space1.serverbase.example.com/repo/BaseOS
# I did not add the enabled directive
# I did not add the gpgcheck directive
[HTTP_AppStream]
name=HTTPlocalrepo_AppStream
baseurl=http://space1.serverbase.example.com/repo/AppStream
# I did not add the enabled directive
# I did not add the gpgcheck directive
As a reminder, I cannot dnf install any package/module/package group BUT dnf search key_word and dnf list provide the correct output.
Update: I can see in /etc/yum.conf in [main] that gpgcheck is enabled but in my repo file from /etc/yum.repos.d I did not add this directive at all.
[root@base-server82 ~]# dnf --version
4.2.17
[root@base-server82 ~]# cat /etc/yum.conf
[main]
gpgcheck=1
installonly_limit=3
clean_requirements_on_remove=True
best=True
skip_if_unavailable=False
[root@base-server82 ~]#

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 11.5K Views
Hi @Yeni84
1. Ensure both your repositories are enabled ( enabled=1 ) and checking with a "dnf repolist" command.
2. Ensure you have repodata directory in both the repository locations. This is important for yum/dnf to get information regarding the packages in your repository.
3. After step 1 & step 2, try passing " dnf install tree -y --nogpgcheck". The main yum.conf file has a definition of gpgcheck=1 which means it would do a gpgcheck but in your repositories, you haven't configured any gpg keys. ( Assuming that this is our testing env )
Hope this helps! :)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 11.5K Views
The gpgcheck=0; this was the solution. After I added this in my repo files, I could dnf install and dnf list.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 11.5K Views
That's great! Good to know!
Keep querying in RHLC and help the community grow! :)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 8,896 Views
Hello
I passed exam ex200 but question a bout yum add repos not working
this are my config during this exam
in /etc/yum.repo/local.repo, i have added these information
[BaseOS]
name=Baseos
baseurl=http://xxxxxxxxxx/BaseOS
pgpcheck=0
enabled=1
my question what wrong in this file, could-you help me i lost my exam because this config not working

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 8,893 Views
on exam this config not working i'm sure if don't activate pgpcheck=1 and pgpkey=///etc/pki/xxx, you can't install anything, howover if u have any solution could-you say it please

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 8,897 Views
Hello
I passed exam ex200 but question a bout yum add repos not working
this are my config during this exam
in /etc/yum.repo/local.repo, i have added these information
[BaseOS]
name=Baseos
baseurl=http://xxxxxxxxxx/BaseOS
pgpcheck=0
enabled=1
my question what wrong in this file, could-you help me i lost my exam because this config not working


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- 8,870 Views
the directive is not pgpcheck, but gpgcheck