Open cxandru opened 3 weeks ago
Please nixos-rebuild boot
and then reboot.
Are you mixing nixpkgs revisions?
Please
nixos-rebuild boot
and then reboot.
I did that
Are you mixing nixpkgs revisions?
I'm pinning nixpgks the oldschool way:
pkgs.mkShell {
nixkpkgsUrl = "https://github.com/NixOS/nixpkgs/archive/27e30d177e57d912d614c88c622dcfdb2e6e6515.tar.gz";
shellHook = ''
rebuild () {
echo Copying config from ~/.cfg
sudo cp -rf ${config} ${extensions} /etc/nixos
sudo nixos-rebuild -I "nixpkgs=${nixkpkgsUrl}" $@
}
'';
}
So, the problem does go away when I comment out hardware.graphics.extraPackages = [ pkgs.mesa.drivers ];
, apparently I actually hadn't tried that. But, this means no Mesa support, which means e.g. I can't run blender (See Blender segfaults on start · Issue #75868 · NixOS/nixpkgs
(adding mesa, as suggested in this comment there had previously fixed that issue for me)
Examing the coredump log led me to this Archlinux Subreddit thread: Xorg segfault with xinit : r/archlinux. I have Intel HD Graphics 4000, which according to this answer should be supported by the crocus driver.
My question is: It seems that somehow the option Option "DRI" "crocus"
would need to be configured, but /etc/X11/xorg.conf.d/20-intel.conf
seems to be ignored under nixos, is there some package option where it can be added?
I tried adding it in services.xserver.deviceSection
in my configuration.nix
, but it didn't do anything there either.
when I comment out
hardware.graphics.extraPackages = [ pkgs.mesa.drivers ];
,
That is redundant because mesa is in the global graphics driver packages path by default. Doing this shouldn't break anything which is why I suspected you might be mixing nixpkgs revisions because adding a different version of Mesa here would indeed break things.
What actually must have helped for that person in the other thread was not running blender from a nix-shell that likely used a different revision to their mesa. I'll state again that mixing Nixpkgs revisions is not supported and will likely not work, especially not for graphics-related things. It's like doing a partial upgrade in Arch terms.
somehow the option
Option "DRI" "crocus"
would need to be configured
It shouldn't. The default modesetting
should work just fine but I don't know about these legacy drivers. Anyhow, the proper way to do this would be to set services.xserver.videoDrivers = [ "drivername" ];
. There doesn't appear to be an xf86video driver for crocus though, so I'm not entirely sure which one you should set. I'd start with intel
but perhaps it's actually intended to be used with modesetting?
cc @K900
@cxandru I had the same issue; I fixed it by swapping from services.xserver.videoDrivers = [ "intel" ];
to the "modesetting"
driver. Adding Option "DRI" "crocus"
to services.xserver.deviceSection
then also seems to have worked fine, judging by the xorg log:
[ 1584.081] (II) modeset(0): [DRI2] Setup complete
[ 1584.081] (II) modeset(0): [DRI2] DRI driver: crocus
...
[ 1584.103] (II) AIGLX: Loaded and initialized crocus
(although I guess it might have been using crocus to begin with)
Describe the bug
Nixos fails to start Xorg (at commit 27e30d177e57d912d614c88c622dcfdb2e6e6515, so
unstable
on October 1. Why am I not using the most recent one, you may ask? Well, because there I encounter https://github.com/NixOS/nixpkgs/issues/349816)).It either stays stuck at the systemd message "Starting Displaymanager", or on "Process Core Dump (In both cases there is a core dump).
coredumpctl
reveals:1447 0 0 SIGABRT inaccessible /nix/store/x9zy8n82bdi9aapgy6p3hiqvyv5iw6fa-xorg-server-21.1.13/bin/Xorg
The contents of/var/log/X.0.log
are:Expected behavior
Xorg doesn't segfault on startup
Additional context
This is my current xserver-related setup, though I've also tried it with commenting it all out and it doesn't make a difference:
I have Intel integrated graphics: (
hwinfo
output is: Intel 3rd Gen Core processor Graphics Controller)Metadata
(this is incomplete as I writing this issue from the rolled-back version of the OS, but I already mentioned the exact commit above)
"x86_64-linux"
yes
sandbox:
yes