Change:
There is no Dbus service file in the derivation outputs. This prevents from starting on demand. It works if it was started manually beforehand. Steps to reproduce the behavior: There should be a message about device slot 0 not loaded. But instead there is an error: This is a regression from at least NixOS 20.09 where this file was present. Apparently some defaults were changed since then.
Thanks for the report, I've also already wondered what broke ... I think what may have changed is that cdemu has stopped installing a service file. See Section 14 in Fortunately, it still provides , so it shouldn't be too hard to generate a service file on our own. From a quick glance, I see two ways: 1) rely on the nixos module, to have dbus activate a systemd service, as in the example 2) come up with a dbus - only solution, similar as before
Yes, according to its git history it was removed in cdemu-daemon 3.2.5. I believe this should be the most straightforward and flexible solution. Also, this is actually recommended by upstream.
Also an issue on my machine. !
Experiencing this as well. New to NixOS, so I'm not sure how much I could contribute to resolve this.
Just in case somebody stumbles upon this, to whom the workaround is not apparent, before a contributor got around to fixing this: After running in a separate terminal, you can use CDEmu normally.
I just got this problem too, tried starting cdemu-deamon manually, but then got: Not really sure what to try next :sweat:
that looks like you don't have the cdemu kernel module loaded. Do you have  and yourself to the group? Also check
Hey! Yes, I have and And: Not sure what this tells me though? Does that look OK?
Interesting. shows the module to be loaded, that's fine. So the command already shows you as part of and also is owned by group cdrom? And you still get permission denied?
should be owned by group and_ also have group permissions .
would appreciate if anybody could test the PR. there are issues with the tray icon not showing, due to xdg resources, but the dbus service should be functional now.
I have this exact issue on the Steam Deck...
Aight, so I thought I might chime into this issue for all those poor souls that have problems with this exact problem: And when you check with : Notice that is empty when it should be mapped to: Solution that worked for me: Check if you have any .conf files in that block , , , , modules from loading. This is common problem nowadays, because of kernel hardening and stuff, so people/distro packagers could disable those for this reason. Sorry for necrobumping, but this is the only github issue that somewhat references this error above.

Discussion:
dbus.packages = [ pkgs.cdemu-daemon ]; }; <ins> users.groups.${config.programs.cdemu.group} = {}; # Systemd User service # manually adapted from example in source package: # https://sourceforge.net/p/cdemu/code/ci/master/tree/cdemu-daemon/service-example/cdemu-daemon.service systemd.user.services.cdemu-daemon.description = "CDEmu daemon"; systemd.user.services.cdemu-daemon.serviceConfig = { Type = "dbus"; BusName = "net.sf.cdemu.CDEmuDaemon"; ExecStart = "${pkgs.cdemu-daemon}/bin/cdemu-daemon --config-file "%h/.config/cdemu-daemon""; Restart = "no"; }; </ins> environment.systemPackages = [ pkgs.cdemu-daemon pkgs.cdemu-client ] ++ optional cfg.gui pkgs.gcdemu

<del> { callPackage, glib, libao, intltool, libmirage }: </del> <ins> { callPackage, glib, libao, intltool, libmirage, coreutils }: </ins> let pkg = import ./base.nix { version = "3.2.5"; pname = "cdemu-daemon";

in callPackage pkg { nativeBuildInputs = [ intltool ]; buildInputs = [ glib libao libmirage ]; <ins> drvParams.postInstall = '' mkdir -p $out/share/dbus-1/services cp -R ../$pname-$version/service-example $out/share/cdemu substitute  $out/share/cdemu/net.sf.cdemu.CDEmuDaemon.service  $out/share/dbus-1/services/net.sf.cdemu.CDEmuDaemon.service  --replace /bin/true ${coreutils}/bin/true ''; </ins> }