LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Fedora (http://www.linuxquestions.org/questions/fedora-35/)
-   -   How to change Fedora 19 login manager? (http://www.linuxquestions.org/questions/fedora-35/how-to-change-fedora-19-login-manager-4175485909/)

penyuan 11-26-2013 06:18 AM

How to change Fedora 19 login manager?
 
Hello,

I've been trying to change my Fedora 19 (running as a guest in VirtualBox 4.3.2) login manager from lightdm to SLiM and CDM to give them a try. So far, I've tried to change /etc/sysconfig/desktop so that the entire file is:

PREFERRED=/usr/bin/startxfce4
DISPLAYMANAGER=/usr/bin/slim

I've also tried DISPLAYMANAGER=/usr/bin/slim-dynwm, and DISPLAYMANAGER=/usr/bin/cdm, but non of that seem to do anything, and I still end up with the same lightdm login screen.

There was a post that mentioned /etc/X11/prefdm but the file does not exist on my system. Also, the posts I've seen so far are all years old, maybe the relevant files have changed?

Am I doing something wrong? What should I be doing? Is there documentation for this?

kbp 11-26-2013 04:00 PM

Just guessing here .. the slim package should provide a systemd service file located under /usr/lib/systemd/system/, then you could try linking display-manager.service to it:
Code:

ln -s -f /usr/lib/systemd/system/<slim?>.service /etc/systemd/system/display-manager.service
Take note of what /etc/systemd/system/display-manager.service currently points to before you relink it .. also, there's probably a cleaner way to do this but I haven't spent the time.

action_owl 11-26-2013 05:00 PM

Aw man, I recently battled with this in F19 too. I think enabling the systemd service of the new login manager was what I had to do as well, also had to disable the service of the old login manager IIRC.

penyuan 11-26-2013 10:54 PM

Quote:

Originally Posted by kbp (Post 5071041)
Just guessing here .. the slim package should provide a systemd service file located under /usr/lib/systemd/system/, then you could try linking display-manager.service to it:
Code:

ln -s -f /usr/lib/systemd/system/<slim?>.service /etc/systemd/system/display-manager.service
Take note of what /etc/systemd/system/display-manager.service currently points to before you relink it .. also, there's probably a cleaner way to do this but I haven't spent the time.

Thanks for your reply!

OK, so a few things happened:

(1) I managed to find /usr/lib/systemd/system/slim.service, but there is no cdm.service at that place. Is there another way to set up CDM?

(2) I ran:
Code:

ln -s -f /usr/lib/systemd/system/slim.service /etc/systemd/system/display-manager.service
And Fedora did reboot to show SLiM. But it no longer recognises my user!!! So now I can only get as far as SLiM, and can't login to my user.... Interestingly, using "reboot" as the username and using my root password as the password successfully reboots my system from SLiM as advertised. So it seems root works but not other users.... Is there anything I can do to troubleshoot this?

Thank you!

kbp 11-27-2013 03:38 PM

There should be a config file for slim, try running 'rpm -ql slim' and see what you can find .. maybe /etc/slim.conf or something similar. Take a look at the file and if it's not commented thoroughly you may be able to do a 'man 5 slim.conf'

Actually I'll see if I can get it working on mine and get back to you ...

kbp 11-27-2013 09:51 PM

Hmm .. I couldn't get it going in a reasonable amount of time but I did find that the correct way to enable slim is:
Code:

systemctl enable slim.service
..and to switch back (in my case):
Code:

systemctl enable lxdm.service
Good luck

penyuan 11-28-2013 09:19 AM

Quote:

Originally Posted by kbp (Post 5071773)
Hmm .. I couldn't get it going in a reasonable amount of time but I did find that the correct way to enable slim is:
Code:

systemctl enable slim.service

Hi I tried this but Fedora says:
Quote:

Failed to issue method call: File exists
I also checked /etc/slim.conf but don't see anything that might indicate how I can get this working..... just in case I've pasted it below:
Code:

# Path, X server and arguments (if needed)
# Note: -xauth $authfile is automatically appended
default_path        /bin:/usr/bin:/usr/local/bin
default_xserver    /usr/bin/X
#xserver_arguments  -dpi 75

# Commands for halt, login, etc.
halt_cmd            /sbin/shutdown -h now
reboot_cmd          /sbin/shutdown -r now
console_cmd        /usr/bin/xterm -C -fg white -bg black +sb -T "Console login" -e /bin/sh -c "/bin/cat /etc/issue | sed -e 's/\\\\r/`uname -r`/' -e 's/\\\\m/`uname -m`/'; exec /bin/login"
#suspend_cmd        /usr/sbin/suspend

# Full path to the xauth binary
xauth_path        /usr/bin/xauth

# Xauth file for server
authfile          /var/run/slim/slim.auth


# Activate numlock when slim starts. Valid values: on|off
numlock            on

# Hide the mouse cursor (note: does not work with some WMs).
# Valid values: true|false
hidecursor          false

# This command is executed after a succesful login.
# you can place the %session and %theme variables
# to handle launching of specific commands in .xinitrc
# depending of chosen session and slim theme
#
# NOTE: if your system does not have bash you need
# to adjust the command according to your preferred shell,
# i.e. for freebsd use:
# login_cmd          exec /bin/sh - ~/.xinitrc %session
login_cmd          if [ -r ~/.xinitrc ]; then exec /bin/bash -login ~/.xinitrc %session; else PREFERRED=%session exec /bin/bash -login /etc/X11/xinit/xinitrc; fi

# Commands executed when starting and exiting a session.
# They can be used for registering a X11 session with
# sessreg. You can use the %user variable
#
# sessionstart_cmd        some command
# sessionstop_cmd        some command

# Start in daemon mode. Valid values: yes | no
# Note that this can be overriden by the command line
# options "-d" and "-nodaemon"
# daemon        yes

# Available sessions (first one is the default).
# The current chosen session name is replaced in the login_cmd
# above, so your login command can handle different sessions.
# see the xinitrc.sample file shipped with slim sources
sessions            startxfce4,i3,custom

# Executed when pressing F11
screenshot_cmd      xwd -root > /slim.xwd

# welcome message. Available variables: %host, %domain
welcome_msg        Welcome to %host

# Session message. Prepended to the session name when pressing F1
# session_msg        Session:

# shutdown / reboot messages
shutdown_msg      The system is halting...
reboot_msg        The system is rebooting...

# default user, leave blank or remove this line
# for avoid pre-loading the username.
#default_user        simone

# Focus the password field on start when default_user is set
# Set to "yes" to enable this feature
#focus_password      no

# Automatically login the default user (without entering
# the password. Set to "yes" to enable this feature
#auto_login          no

# current theme, use comma separated list to specify a set to
# randomly choose from
current_theme      default

# Lock file
lockfile            /var/run/slim/slim.lock

# Log file
logfile            /var/log/slim.log

I also checked the log file at /var/log/slim.log and it only says:
Quote:

slim: waiting for X server to begin accepting connections
Giving up.
slim: unable to connect to X server
I don't even know when that log entry was entered...
Does anyone still have any ideas? Thanks!

kbp 11-28-2013 03:57 PM

Sorry .. I missed one param:
Code:

systemctl enable --force slim.service
I found the same issues, the slim log file is not particularly helpful or even timestamped. I ran it under strace then trawled through the ~20,000 lines, there were a few errors but nothing that stuck out as being the cause. Also looked through audit.log but all was good there, tried disabling selinux but still no change. Fiddled with /etc/pam.d/slim .. still no change.

penyuan 12-07-2013 06:25 AM

Quote:

Originally Posted by kbp (Post 5072149)
Sorry .. I missed one param:
Code:

systemctl enable --force slim.service
I found the same issues, the slim log file is not particularly helpful or even timestamped. I ran it under strace then trawled through the ~20,000 lines, there were a few errors but nothing that stuck out as being the cause. Also looked through audit.log but all was good there, tried disabling selinux but still no change. Fiddled with /etc/pam.d/slim .. still no change.

Finally had some time to try this again. I ran the command with the --force option and I was indeed able to get to the SLiM screen upon boot. However, non of my users are recognised. What happens is that after entering my username and password the screen briefly goes blank/black then goes back to the login screen.
What can I do to solve this? Thanks!

wmakowski 12-08-2013 10:31 AM

Not a lot of experience with slim, but have a few ideas. 1) Has the lightdm display manager been disabled with systemctl? Might be they are conflicting with each other. 2) other web posts I have seen on problems with login tend to be something with xauth or the authfile. Make sure what you have in slim.conf exists, in particular /usr/bin/xauth and /var/run/slim/slim.auth.

I did not find a bug in bugzilla, but found a known issue on the archlinux wiki. Might be worth a bug report.

frankzen 12-27-2013 09:57 AM

If you haven't found the solution to this you might signup for the Fedora user list and ask there. YMMV

edit: try this link: http://forums.fedoraforum.org/showthread.php?t=52

penyuan 12-27-2013 09:11 PM

I checked, and turns out that I really don't have /var/run/slim/slim.auth, maybe that is the problem? But I don't really know how to set up such a file. Mayble I will ask the Fedora forums.

I will report back if I manage to figure anything out. Thanks!


All times are GMT -5. The time now is 04:58 PM.