archinstall icon indicating copy to clipboard operation
archinstall copied to clipboard

Sway does not work

Open nvidialinuxuser opened this issue 3 years ago • 6 comments

With the latest versions of archinstall, when installing Arch Linux with any NVIDIA driver (nouveau, open source, proprietary) sway will not start. A temporary solution to the problem is to run seatd. My gpu is gtx 1660 super. I think the problem is related to systemd/logind. Help please

More: https://bbs.archlinux.org/viewtopic.php?id=276875

nvidialinuxuser avatar Jun 02 '22 10:06 nvidialinuxuser

I'm not entirely sure but iirc then sway doesn't really support anything but nouveau, we should also already display a warning for that at the moment 🤔

svartkanin avatar Jun 04 '22 22:06 svartkanin

I used Sway for a while until it stopped working in Arch. Now I work on Void Linux with proprietary drivers and Sway works fine, so the problem is not with the drivers.

ghost avatar Jun 05 '22 07:06 ghost

I found a solution to the problem! You need to install the polkit package, which archinstall for some reason does not install by default when selecting SwayWM (it needs either polkit or seatd to run it).

ghost avatar Jun 05 '22 09:06 ghost

Off topic, but I noticed that the swaybg package, which is needed to show wallpaper is no longer installed via archinstall (wallpaper with color #404040 cannot be changed)

ghost avatar Jun 10 '22 23:06 ghost

Here are my solutions in VMware, I use seatd. 1.Enable 3D Acceleration 2.add WLR_NO_HARDWARE_CURSORS=1 to /etc/environment 3.sudo gpasswd -a $yourname seat 4.sudo systemctl start seatd && sudo systemctl enable seatd 5.add this to ~/.bashrc

export SWAYSOCK=/run/user/$(id -u)/sway-ipc.$(id -u).$(pgrep -x sway).sock
export XDG_RUNTIME_DIR=/run/user/$UID

jdonejdk avatar Aug 24 '22 01:08 jdonejdk

but I noticed that the swaybg package, which is needed to show wallpaper is no longer installed via archinstall

I'd just like to clarify that archinstall never installed swaybg. This was most likely an upstream change where it got removed from a package group or as a dependency of sway.

So seatd or polkit is a bit of a specific thing to sway, and to specific hardware. I might be off base here as I don't use sway myself - but this feels like one of those things that could be controversial if we choose for the user (even if seatd is already pulled in due to dependencies) as there's a few different options to start sway with this kind of hardware support that it needs.

But if we go for something, perhaps it should be seatd? Either way, this will be a bit of a larger change so I'm postponing this for the next version.

Torxed avatar Aug 28 '22 21:08 Torxed

seatd is a requirement because on Arch Linux it provides both seatd the daemon and libseat the client library. libseat is the actual hard requirement for sway, but libseat is capable of interacting with seatd or logind for operation. The problem is that logind's policy makes it useless to sway unless polkit is installed. It's a bit of a shame that logind requires polkit for this operation and I believe if anyone were so motivated it could probably be corrected in logind, or at least made a compile-time option because the default polkit rules for chvt are actually quite permissive in the first place.

In Arch Linux I think it makes the most sense to just bite the bullet and install polkit. The user is likely to need it for one reason or another as Arch tends to compile everything with all the options set and doesn't split packages for dependencies often. I think for a new Arch Linux user, as silly as logind can be, having the system configuration be a little more similar to other common setups is probably helpful, retaining the ability to use loginctl, set logind.conf options or use other applications that depend on the logind dbus api — these are referenced often enough in the wiki.

rpigott avatar Oct 23 '22 05:10 rpigott