Results 1 to 8 of 8

Thread: How to autologin to i3?

  1. Default How to autologin to i3?

    Hi,

    The main thing I dislike about openSUSE is how system configs and systemd services are handled. On most distros if I want to autologin to a specific desktop or window manager I merely install the display manager I want (if not already installed), which is usually SDDM for me (mostly due to familiarity) and systemctl enable it, then edit its respective config in /etc (/etc/sddm.conf for SDDM) adding, for example:

    Code:
    [Autologin]
    # Whether sddm should automatically log back into sessions when they exit
    Relogin=false
    
    # Name of session file for autologin session (if empty try last logged in)
    Session=i3.desktop
    
    # Username for autologin session
    User=fusion809
    (which is what I use for SDDM) and then it is all done, on next boot I will automatically login to i3 with this config. On openSUSE you do not enable the specific display manager you're using's service using systemctl enable, rather you enable the more general displaymanager service, if not already enabled. Then instead of editing the display manager's specific config, you edit the general config for DMs, /etc/sysconfig/displaymanager (either manually or with YaST; my preference is manually). This file gives the option to enable autologin, but it won't allow you specify the DE/WM. To do this you edit /etc/sysconfig/windowmanager. Unfortunately, this file does not recognize i3 as a valid DE/WM, so it goes to its default of booting the last desktop you booted, that it views as a valid one (i.e. one you can actually specify in /etc/sysconfig/windowmanager), which for me is KDE Plasma 5. Is there a way of autologging into i3, that somehow works with this annoying method of configuration?

    If you take offence to me pointing out faults in openSUSE please don't, because I realize all distros, all operating systems for that matter, have faults, and the fact I'm still using openSUSE despite this says that I must think the benefits of it outweigh its shortcomings.

    Thanks for your time,
    Brenton
    Brenton Horne: Linux enthusiast and writer of ​The Hornery.
    Seven favourite distros
    : Arch, Fedora, Gentoo, openSUSE Tumbleweed and Void.

  2. #2
    Join Date
    Aug 2010
    Location
    Chicago suburbs
    Posts
    12,628
    Blog Entries
    3

    Default Re: How to autologin to i3?

    I am not familiar with "i3".

    Whether or not to auto-login is controlled by "/etc/sysconfig/displaymanager". What to set should be obvious enough if editing the file. Or use the Yast "/etc/sysconfig" editor to set autologin. You set it to the user that will be auto-logged in.

    You are out of date on displaymanager settings. For that, as root:
    Code:
    update-alternatives --config default-displaymanager
    to set which DM to use.

    As for desktop -- normally you set that in the displaymanager.

    If you are wanting to setup autologin right now, I would suggest that you first set the desired displaymanager. Then reboot to get to that displaymanager and login to the desktop of choice. And, finally, setup autologin for that user. And, after that, it should all work.
    openSUSE Leap 15.1; KDE Plasma 5;
    testing Leap 15.2Alpha

  3. Default Re: How to autologin to i3?

    i3 isn't a desktop environment mate, it's a window manager and it has no method to specify autologin. If it had one I wouldn't have asked this question. To set up autologin for it you need to do so via your display manager. That's why under other distros I edit /etc/sddm.conf to do so. That is why I asked this question, because I don't know how to do that on openSUSE, because of its irritatingly complicated method of specifying display manager and window manager settings.
    Brenton Horne: Linux enthusiast and writer of ​The Hornery.
    Seven favourite distros
    : Arch, Fedora, Gentoo, openSUSE Tumbleweed and Void.

  4. Default Re: How to autologin to i3?

    Oops nvm, I found it, adding those lines to /etc/sddm.conf, after setting it as the default display manager (using update-alternatives as you said) did the job.
    Brenton Horne: Linux enthusiast and writer of ​The Hornery.
    Seven favourite distros
    : Arch, Fedora, Gentoo, openSUSE Tumbleweed and Void.

  5. #5
    Join Date
    Aug 2010
    Location
    Chicago suburbs
    Posts
    12,628
    Blog Entries
    3

    Default Re: How to autologin to i3?

    Quote Originally Posted by fusion809 View Post
    i3 isn't a desktop environment mate, it's a window manager and it has no method to specify autologin.
    The same can be said of "fvwm", which I actually have installed here. And using "sddm" or "gdm" or "lightdm", there is an option to select "fvwm" as the session to which I login.

    As far as I know, the sessions that I can choose are defined by ".desktop" files in "/usr/share/xsessions". I don't need to edit "sddm.conf".

    In any case, I'm glad you have things working in a way that suits you.
    openSUSE Leap 15.1; KDE Plasma 5;
    testing Leap 15.2Alpha

  6. Default Re: How to autologin to i3?

    That's what I meant mate, I had edited /etc/sysconfig/windowmanager to specify i3 as the default WM and it didn't work it went to its default option, booting the last booted DE.
    Brenton Horne: Linux enthusiast and writer of ​The Hornery.
    Seven favourite distros
    : Arch, Fedora, Gentoo, openSUSE Tumbleweed and Void.

  7. Default Re: How to autologin to i3?

    Oh and when editing this file with YaST the drop-down menu doesn't mention i3 as a valid option.
    Brenton Horne: Linux enthusiast and writer of ​The Hornery.
    Seven favourite distros
    : Arch, Fedora, Gentoo, openSUSE Tumbleweed and Void.

  8. #8
    Join Date
    Aug 2010
    Location
    Chicago suburbs
    Posts
    12,628
    Blog Entries
    3

    Default Re: How to autologin to i3?

    Quote Originally Posted by fusion809 View Post
    That's what I meant mate, I had edited /etc/sysconfig/windowmanager to specify i3 as the default WM and it didn't work it went to its default option, booting the last booted DE.
    At that point, you should be able to logout. And then login again, but select the desired desktop environment. And it should remember your selection for the next login.
    openSUSE Leap 15.1; KDE Plasma 5;
    testing Leap 15.2Alpha

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •