EPEL can not be used in Rocky9

I have a fresh installation of Rocky9 and want to download some packages from EPEL, so I’ve done these operations to set up the repository, but it is still unusable as outputs shows:

dnf config-manager --set-enabled crb
dnf install epel-release
dnf clean all
[root@brown ~]# dnf check-update
DigitalOcean Agent                                                                                                                                                                                             11 kB/s | 5.7 kB     00:00
DigitalOcean Droplet Agent                                                                                                                                                                                    3.0 kB/s | 2.9 kB     00:00
Extra Packages for Enterprise Linux 9 - x86_64                                                                                                                                                                 14 MB/s |  15 MB     00:01
Killed

as you see I can not use it, what is the problem, and how can I fix it?

Hey!
That’s very weird, because I just have been using it :thinking:

Seeing the Killed there, anything running on your side that kills dnf? Or is it running that long that dnf times out?

DNF working ok when i disable epel, but before showing Killed, dnf freezes for a few seconds. also checked memory usage but everything looks normal

Update: during the freeze it’s not possible to kill the process by ctrl + c

Can you do:

dnf repolist

so we can see all the repositories that you have enabled? I also use EPEL on Rocky 9 and it’s not a problem for me either. So there’s something weird on your machine I think.

here it is

[root@brown ~]# dnf repolist
repo id                                                                                                  repo name
appstream                                                                                                Rocky Linux 9 - AppStream
baseos                                                                                                   Rocky Linux 9 - BaseOS
crb                                                                                                      Rocky Linux 9 - CRB
digitalocean-agent                                                                                       DigitalOcean Agent
droplet-agent                                                                                            DigitalOcean Droplet Agent
epel                                                                                                     Extra Packages for Enterprise Linux 9 - x86_64
extras                                                                                                   Rocky Linux 9 - Extras

also tried disabling DigitalOcean Agent and DigitalOcean Droplet Agent but nothing changed, still same error

That was the same as what I was going to suggest. If you do this, is it any better?

dnf clean all
dnf update
1 Like

Tbh that’s really odd, because it’s really just another repo with a metalink as path,
maybe it helps to do --verbose or increase the debug level.

1 Like

solution:
Apparently, the problem was the amount of server RAM, i had 0.5 GB ram in total so added 2 GB swap file, and now it’s working with no problem.

grumbling:
Which is interesting how much ram one single repository might need!
Also it doesn’t make sense that this process was killed after the RAM consumption exceeded 80%. which left 20 percent unused

2 Likes

Hmm yeah, minimum requirements are actually 2GB ram, so you were way way down there. You can get away with 1GB if you remove all the ssd* packages. 512MB is not enough for Rocky to run.

3 Likes

The issue is not going to be EPEL specifically, but rather just adding one more repository at that stage was enough to push you OOM, think of it as the straw that broke the camel’s back.

512M is not enough to run EL9 in, you really need more. DO should not be selling EL9 instances with only 512M, that is madness.

2 Likes

Me too, spun up a 512MB RAM on DigitalOcean to test things, dnf just died on me without showing proper error.

Not surprising since min spec for Rocky is 2GB. Why do people constantly try with specs less than the requirements?

1 Like

Interestingly, we’ve had complaints from folks who want to use our AWS AMIs, e.g., with 512MB of RAM. We (the Cloud SIG) have specifically chosen to not enable these instance types because you need to take special care in order to use them (namely: ensuring SWAP is available, which is a bit of an antipattern in the cloud).

We try to aim for ‘least astonishment’ and, to me, that means users who wish to use these instance types with RL9 will have to clone the AMI and make it available on those instance types. Better (IMO) than vague failures like the above!

With any hope, dnf5 in EL10 will bring back a smaller memory foot print, but I’m not holding my breath for 512MB boots. As a data point, though, I can boot debian on as little as 256MB :wink:

1 Like

Because those specs can be overkill in a minumal setup. The amount of memory needed for an install can easily be more than is needed to run the thing; e.g. I build with 3073Mb of RAM but then drop to 512M once the build is complete. A test machine running postfix and apache doesn’t need much memory!


# free -h
               total        used        free      shared  buff/cache   available
Mem:           460Mi        96Mi       155Mi       3.0Mi       228Mi       364Mi
Swap:             0B          0B          0B

# dnf makecache
Extra Packages for Enterprise Linux 9 - x86_64  101 kB/s |  29 kB     00:00
Rocky Linux 9 - BaseOS                           17 kB/s | 4.1 kB     00:00
Rocky Linux 9 - AppStream                       9.6 kB/s | 4.5 kB     00:00
Rocky Linux 9 - Extras                          9.8 kB/s | 2.9 kB     00:00
Metadata cache created.

# dnf check-update
Last metadata expiration check: 0:00:12 ago on Mon Jul 24 12:04:37 2023.

# free -h
               total        used        free      shared  buff/cache   available
Mem:           460Mi        96Mi       155Mi       3.0Mi       228Mi       363Mi
Swap:             0B          0B          0B