NixOS / nixpkgs

Nix Packages collection & NixOS
MIT License
17.34k stars 13.58k forks source link

Pantheon not working #57327

Closed aaronjanse closed 5 years ago

aaronjanse commented 5 years ago

Issue description

I've tried several times in the past to get pantheon working, to no avail.

Until this morning, I booted to a very old generation and was pleasantly surprised with a working installation of Pantheon. Once I rebooted, booting into the same generation, it no longer worked.

Every time I've attempted to boot Pantheon, except for that one time this morning, I am greeted by a black/light-gray screen, a cursor, and nothing else.

I've shrunk down my config to the smallest I could reasonably make it, and the problem has not gone away. I don't have any other hardware to test this on.

Steps to reproduce

  1. sudo nixos-rebuild boot using my configuration.nix
  2. Boot into generation
  3. Enter password into login manager
  4. Say hello to a black/gray screen, cursor, and nothing else.

Technical details

configuration.nix

/var/log/lightdm/seat0-greeter.log

worldofpeace commented 5 years ago

Weird, the seat0-greeter.log says we're starting an old session plasma5 https://gist.github.com/aaronduino/9a446ce47d0ba5b6e7024b514c43b649#file-seat0-greeter-log-L26

I think there's a bug in the greeter, and unfortunately we won't be able to fix it because of their recent rewrite on master.

Running the following in a tty

dbus-send --system --type=method_call --print-reply --dest=org.freedesktop.Accounts /org/freedesktop/Accounts/User$UID org.freedesktop.Accounts.User.SetXSession string:

and then running sudo systemctl restart display-manager.service might fix it for you.

aaronjanse commented 5 years ago

I did as you instructed. After logging in, I was greeted with a light grey screen with cursor instead of a black screen with cursor.

/var/log/lightdm/seat0-greeter.log (after running your commands and logging into the latter light grey screen with cursor)

worldofpeace commented 5 years ago

I've been able to reproduce this everytime in a vm when using pantheon's greeter. This would be a pretty nasty problem for anyone wanting to switch to using this.

The quickest fix that I could produce was just not using their greeter

services.xserver.displayManager.lightdm.greeters.pantheon.enable = false;

Or you could do

dbus-send --system --type=method_call --print-reply --dest=org.freedesktop.Accounts /org/freedesktop/Accounts/User$UID org.freedesktop.Accounts.User.SetXSession string:pantheon

Which will force the default to pantheon.

hedning commented 5 years ago

Looks like lightdm really prefers the last used session stored in ~/.dmrc, choosing it even if it doesn't exist (and dosen't bother invalidating it either when things fails).

Remove ~/.dmrc and start up pantheon again, that should make it work (at least it ran without any problems in a VM after I cleared out an old dmrc).

worldofpeace commented 5 years ago

Right, forgot about the .dmrc. Even mentioned that in the op of https://github.com/NixOS/nixpkgs/pull/48637

I think maybe we could patch lightdm to forget about .dmrc? Think fedora has one too.

worldofpeace commented 5 years ago

Testing if using that patch does the trick now, probably should though.

aaronjanse commented 5 years ago

Just a heads up: on my machine, I don't have a .dmrc in my home directory.

I even tried removing .gtk* and that didn't work either.

aaronjanse commented 5 years ago

/var/log/lightdm/seat0-greeter.log

** Message: 14:11:32.256: Starting lightdm-gtk-greeter 2.0.6 (Sep 10 2018, 09:58:27)
** Message: 14:11:32.258: [Configuration] Reading file: /etc/lightdm/lightdm-gtk-greeter.conf

** (lightdm-gtk-greeter:2775): WARNING **: 14:11:32.333: [PIDs] Failed to execute command: /usr/lib/at-spi2-core/at-spi-bus-launcher

** (lightdm-gtk-greeter:2775): WARNING **: 14:11:32.334: [PIDs] Failed to execute command: upstart
worldofpeace commented 5 years ago

Just a heads up: on my machine, I don't have a .dmrc in my home directory. I even tried removing .gtk* and that didn't work either.

Seems that the problem with the .dmrc is just another one that came out of the fountain of issues :smile:

And one that could be most easily be produced.

@aaronduino Are you on IRC/Freenode or Matrix? I could be more help to you there, where passing around logs like this might not produce results in a timely matter for the both of us.


Notice to maintainers

Completely unrelated to this, but I caught it from the latest lightdm-gtk-greeter logs.

we should probably add these flags to lightdm-gtk-greeter

--disable-indicator-services-command
--disable-at-spi-command

or instead of --disable-at-spi-command

 --enable-at-spi-command=${at-spi2-core}/libexec/at-spi-bus-launcher  --launch-immediately

But that would change the current behavior to actually starting it, and maybe it shouldn't.

jtojnar commented 5 years ago

Is not starting the accessibility bus necessary to allow accessibility functions in the greeter? I would consider the unavailability of a11y bus to be a bug.

worldofpeace commented 5 years ago

Is not starting the accessibility bus necessary to allow accessibility functions in the greeter? I would consider the unavailability of a11y bus to be a bug.

I can enable the Large Font and High Contrast features in that greeter. Are their other one's for that greeter?

aaronjanse commented 5 years ago

@worldofpeace my matrix account is @aaronduino:matrix.org

worldofpeace commented 5 years ago

Ok found out there was an .xsession script so it took precedence and failed in a particularly interesting appearance.

So it seems a lot of our users like a lightweight windowmanager, (i3 in this case) and DE.

Also noticed that org.freedesktop.Accounts.User.Session was == plasma5 from a last session? Don't know about that, but not using an .xsesison script fixed this, so I think it's safe to close.

erobl commented 5 years ago

I just updated to 19.03 and tried to set up both pantheon.elementary-greeter and lightdm-enso-os-greeter. It keeps freezing whenever they load up. I deleted .dmrc and made sure to not have any .xsession scripts or any startup scripts other than whatever i3 does. I am using i3, if that is relevant.

worldofpeace commented 5 years ago

I've disabled pantheon's greeter because it's problematic when switching desktopManagers

Do you have those commits, and have you tried just using the default gtk lightdm greeter?

Beyond that I can't help much more without logs.

aaronjanse commented 5 years ago

Heads up I've never been able to get Pantheon to work with i3.

If it's not expected to work, maybe there should a nix assertion that says so?

-------- Original Message -------- On Apr 15, 2019, 12:31, worldofpeace wrote:

I've disabled pantheon's greeter because it's problematic when switching desktopManagers

Do you have those commits, and have you tried just using the default gtk lightdm greeter?

Beyond that I can't help much more without logs.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

worldofpeace commented 5 years ago

Yeah there's no configuration for i3+pantheon. Someone could do gnome-flashback and i3. but we can't use it without gnome-shell yet #54415

If it's not expected to work, maybe there should a nix assertion that says so?

I don't think there's anything to assert on. If someone enables pantheon and also i3 windowmanager they could start either session interchangeably. Wasn't made to intersect.

Though it seems a lot of nixos users want things like https://github.com/NixOS/nixpkgs/blob/2fcb11a2442b27834db87b2f62511037c31b5e36/pkgs/desktops/gnome-3/misc/gnome-flashback/default.nix so maybe we should make that generic to make any gnome-session.

erobl commented 5 years ago

Do you have those commits No idea, I'm on the 19.03 channel with nonlocal nixpkgs have you tried just using the default gtk lightdm greeter? That's what I'm using currently, I wanted to try out something that looked a bit nicer, but gtk works fine.