OBS virtual camera broken in recent unstable

My OBS virtual camera failed to start after an update last week. I did the usual thing and just rolled back to the previous generation until I had time to look further.

It turns out that there was a v4l2loopback update from 0.13.2 to 0.15, and this is a breaking change for OBS. OBS has addressed this in version 31.1, but that’s yet to be released.

The v4l2loopback commit suggests that it is in turn needed to build newer kernels, so just rolling that back for everyone until OBS updates isn’t quite so easy.

So I did this override instead…

  boot.extraModulePackages = [
    (pkgs.linuxPackages.v4l2loopback.overrideAttrs
      ({
        version = "0.13.2-manual";
        src = (pkgs.fetchFromGitHub {
          owner = "umlaeute";
          repo = "v4l2loopback";
          rev = "v0.13.2";
          hash = "sha256-rcwgOXnhRPTmNKUppupfe/2qNUBDUqVb3TeDbrP5pnU=";
        });
      })
    )
  ];

The version is just a cheap hack to avoid pulling in the kernel to get the version in this particular module.

Have added the same note to the commit, but thought I’d post it here to make it easier to find.

1 Like

as of the latest unstable bump at 5c724ed, this is no longer necessary, as OBS has been updated (to a 31.0.4 patch release that includes the fix)

Hi @uep :slight_smile:

Need this fix too. Do you know when this will be avaible on 25.05 channel ? It’s look like it’s aleready the case on the NixOS website but it’s not :

nix-env -f "https://github.com/NixOS/nixpkgs/archive/refs/tags/25.05.tar.gz" -qaP obs-studio
unpacking 'https://github.com/NixOS/nixpkgs/archive/refs/tags/25.05.tar.gz' into the Git cache...

obs-studio  obs-studio-31.0.3

Thanks !

I’m using the OBS “Screen Capture (PipeWire)”, which seems ok. It was working, then I updated to the latest stable and it broke. After a bit of help from Cursor, I installed a few more packages and configured gnome a little bit better, and it’s back to working again.

the PR with the update is

The corresponding backport is

It looks like that’s just waiting for the next successful build cycle before the channel advances:
https://nixpk.gs/pr-tracker.html?pr=421198

Edit: caffeine hadn’t yet kicked in…
Edit2: Looks like it just landed

So strange, i force update and i expected to an update on 3.0.4. instead of that, update on 31.1.0 i don’t know why. But i get the fix and solve the problem with virtual cam :grinning:

the latest unstable, as of just a couple of hours ago, includes the 31.1 release… I just got it too.

1 Like