Getting an amd egpu working

I’m running a setup with a framework laptop and a razer core x egpu with an amd card.

I used to use a nvidia card where I simply told prime to use the egpu while pointing at the right pcie and that was that but I cannot seem figure out how to get NixOS to use the amd card (so far I have simply setup the amd gpu as if it wasnt external). The fans start spinning when I expect them to (when running games mostly) but based on what games crash and the performance in the ones that do run the games dont seem to be using the card and I am lost as to how to make them use it.

external pci…


I found this

so it’s just a matter of hotwiring your X configuration, as long as nixos is loading the kernel drivers (if it needs them).

don’t forget to restart X and your machine after those change.

are you a new nixnewbie, a nixpert, a nixinator?

I see I will see what I can get working and share if I succeed or not. I’d say I’m still a nixnewbie while I do have a nice flake configuration and my homeserver running nixos which some services on it it seems there is still allot to learn which is fun

1 Like

we were all newbies once, and because nix isn’t exactly Unix, even unix graybeards have to learn something new with nix .

Don’t be afraid to share, because i find this community when it comes to code and new users pretty welcoming…

because nix is a language, it’s very open ended, there is not one right way to do something, but there are best practises…

keep nixxing…

1 Like

Using an AMD card but with the rendering done on the laptop screen, you need something like virtualGL.

If it was an NVIDIA card, you could use PRIME rendering which basically just requires a few environment variables to be set to make it work when working as a discrete card, unfortunately AMD doesn’t offer this :frowning:

If you connect a screen to the card output, it should just works when rendering on that screen.