You are not logged in.

#1 2008-03-24 22:12:32

solarwind
Member
From: Toronto
Registered: 2008-03-18
Posts: 546

Simple SLIM Question

How do I get slim to show shutdown/reboot buttions? Is it possible?

Offline

#2 2008-03-24 22:15:20

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: Simple SLIM Question

It doesn't have buttons. You type "shutdown" or "reboot" for the username.

Offline

#3 2008-03-24 22:16:46

Misbah
Member
Registered: 2008-02-27
Posts: 218

Re: Simple SLIM Question

deleted

Last edited by Misbah (2012-02-14 05:50:10)

Offline

#4 2008-03-24 22:32:31

solarwind
Member
From: Toronto
Registered: 2008-03-18
Posts: 546

Re: Simple SLIM Question

Thanks guys!

Offline

#5 2008-08-07 09:48:24

uastasi
Member
From: Salento - Italy
Registered: 2007-11-27
Posts: 247

Re: Simple SLIM Question

Nothing happens neither with 'halt' nor with 'reboot' and root password. Should it be connected to disabling root account?
I've checked /var/log/slim.log but there's no mention about these two events.


Till the last battle, till the last bottle.
aur - twitter

Offline

#6 2008-08-07 10:25:15

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Simple SLIM Question

A nice trick would be to make a username with the name "shutdown" and put a shutdown command in .xinitrc or something else and leave the password blank. Then you'd just type shutdown wink


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#7 2008-08-07 23:22:42

uastasi
Member
From: Salento - Italy
Registered: 2007-11-27
Posts: 247

Re: Simple SLIM Question

moljac024 wrote:

A nice trick would be to make a username with the name "shutdown" and put a shutdown command in .xinitrc or something else and leave the password blank. Then you'd just type shutdown wink

It sounds as a workaround... I'd prefer a kiss solution if possible wink


Till the last battle, till the last bottle.
aur - twitter

Offline

#8 2008-08-08 00:17:37

.:B:.
Forum Fellow
Registered: 2006-11-26
Posts: 5,819
Website

Re: Simple SLIM Question

The kiss solution is to press your laptop/desktop's power button and have it shut down smile. ACPI shutdown for life baby cool


Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy

Offline

#9 2008-08-08 10:42:55

uastasi
Member
From: Salento - Italy
Registered: 2007-11-27
Posts: 247

Re: Simple SLIM Question

B wrote:

The kiss solution is to press your laptop/desktop's power button and have it shut down smile. ACPI shutdown for life baby cool

Sure but you're forgetting reboot... roll


Till the last battle, till the last bottle.
aur - twitter

Offline

#10 2008-08-08 17:00:28

thayer
Fellow
From: Vancouver, BC
Registered: 2007-05-20
Posts: 1,560
Website

Re: Simple SLIM Question

I've got a better idea...disable SLiM entirely and use the standard login prompt.  Ctrl-Alt-Del reboots and you can bind a key combination to shutdown too--in my case, I use Ctrl-Alt-End.  Problem solved.

Alternatively, you might be able to tweak who runs what within SLiM by modifying this portion of /etc/slim.conf:

# 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; exec /bin/login"

thayer williams ~ cinderwick.ca

Offline

#11 2008-08-12 15:19:43

uastasi
Member
From: Salento - Italy
Registered: 2007-11-27
Posts: 247

Re: Simple SLIM Question

thayer wrote:

Alternatively, you might be able to tweak who runs what within SLiM by modifying this portion of /etc/slim.conf:

# 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; exec /bin/login"

That's what I've done from the beginning, but with no results hmm:/


Till the last battle, till the last bottle.
aur - twitter

Offline

#12 2008-09-03 12:05:09

Cosay
Member
From: United States
Registered: 2008-08-12
Posts: 82
Website

Re: Simple SLIM Question

thayer wrote:

I've got a better idea...disable SLiM entirely and use the standard login prompt.  Ctrl-Alt-Del reboots and you can bind a key combination to shutdown too--in my case, I use Ctrl-Alt-End.  Problem solved.

Sorry to resurrect this thread but that sounds really cool. How did you implement this Thayer?

Offline

#13 2008-09-03 14:25:21

thayer
Fellow
From: Vancouver, BC
Registered: 2007-05-20
Posts: 1,560
Website

Re: Simple SLIM Question

Cosay wrote:
thayer wrote:

I've got a better idea...disable SLiM entirely and use the standard login prompt.  Ctrl-Alt-Del reboots and you can bind a key combination to shutdown too--in my case, I use Ctrl-Alt-End.  Problem solved.

Sorry to resurrect this thread but that sounds really cool. How did you implement this Thayer?

IIRC it took a shed load of googling, so I kept notes smile

First, add the following line to /etc/inittab:

kb:12345:kbrequest:/sbin/shutdown -t1 -h now

As root, edit the currently used keymap, usually:

/usr/share/kbd/keymaps/i386/qwerty/us.map.gz

I believe you'll need to use vim for this, since it can open, modify and recompress gz files on the fly.
Now proceed to the bottom of the file, and paste ONE of the following:

For CTRL+ALT+END:

keycode 107 = Select
        altgr   control keycode 107 = KeyboardSignal
        control alt     keycode 107 = KeyboardSignal

Or, if you'd prefer to use CTRL+ALT+INSERT to shutdown:

keycode 110 = Insert
  altgr   control keycode 110 = KeyboardSignal
  control alt     keycode 110 = KeyboardSignal

Save and exit.

You'll need to restart the system after making these changes. Then, just CTRL+ALT+F{1,2,3,4,5,6} into a VC and test it out.

If for some reason the keymap isn't being loaded at startup, edit /etc/rc.local and add:

  # load keymap for ctrl+alt+end/insert shutdown
  loadkeys /usr/share/kbd/keymaps/i386/qwerty/<keymapfile>

Where <keymapfile> is the name of the keymap file you modified above.

Last edited by thayer (2008-09-03 14:28:02)


thayer williams ~ cinderwick.ca

Offline

#14 2008-09-03 14:37:47

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Simple SLIM Question

If you really want a graphical login manager with buttons for shutdown and reboot (but most importantly not requiring the root password to do this!!) you'll have to say goodbye to slim. It's been a good ride but I too, have parted ways with it and switched over to GDM. It's just more powerful and it has those nice buttons wink

Also, strange as it is, GDM is much faster than slim for me.


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#15 2008-09-05 16:05:25

thayer
Fellow
From: Vancouver, BC
Registered: 2007-05-20
Posts: 1,560
Website

Re: Simple SLIM Question

moljac024 wrote:

If you really want a graphical login manager with buttons for shutdown and reboot (but most importantly not requiring the root password to do this!!) you'll have to say goodbye to slim.

Login managers are overrated. I find it just as easy/simple to login at the console.


thayer williams ~ cinderwick.ca

Offline

#16 2008-09-05 16:22:03

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Simple SLIM Question

thayer wrote:
moljac024 wrote:

If you really want a graphical login manager with buttons for shutdown and reboot (but most importantly not requiring the root password to do this!!) you'll have to say goodbye to slim.

Login managers are overrated. I find it just as easy/simple to login at the console.

I can theme my login manager, can you theme yours ? tongue


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#17 2008-09-05 17:09:57

thayer
Fellow
From: Vancouver, BC
Registered: 2007-05-20
Posts: 1,560
Website

Re: Simple SLIM Question

moljac024 wrote:
thayer wrote:
moljac024 wrote:

If you really want a graphical login manager with buttons for shutdown and reboot (but most importantly not requiring the root password to do this!!) you'll have to say goodbye to slim.

Login managers are overrated. I find it just as easy/simple to login at the console.

I can theme my login manager, can you theme yours ? tongue

Oh, well now you're just talkin' fluff smile

Seriously though, I know what ya mean...but I've always been a 'function over form' kind of guy.


thayer williams ~ cinderwick.ca

Offline

#18 2008-09-05 17:17:38

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Simple SLIM Question

thayer wrote:
moljac024 wrote:
thayer wrote:

Login managers are overrated. I find it just as easy/simple to login at the console.

I can theme my login manager, can you theme yours ? tongue

Oh, well now you're just talkin' fluff smile

Seriously though, I know what ya mean...but I've always been a 'function over form' kind of guy.

One more thing: Can you change what window manager you will load after logging in ? See, not just form but also more function wink


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#19 2008-09-05 17:24:49

fflarex
Member
Registered: 2007-09-15
Posts: 466

Re: Simple SLIM Question

Actually, a SLiM style .xinitrc file will let you choose your window manager. For instance if I run startx on my system it will run awesome by default, but 'startx xfce4' will run xfce.

Offline

#20 2008-09-05 17:47:40

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Simple SLIM Question

fflarex wrote:

Actually, a SLiM style .xinitrc file will let you choose your window manager. For instance if I run startx on my system it will run awesome by default, but 'startx xfce4' will run xfce.

I know that. But thayer is not using a graphical login manager at all. Try to select a session with that wink


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#21 2008-09-05 18:02:06

fflarex
Member
Registered: 2007-09-15
Posts: 466

Re: Simple SLIM Question

No, I mean you can do that without a graphical login manager, using the same technique that SLiM uses to do it...

GDM and KDM have a different method that confuses me, though...

Last edited by fflarex (2008-09-05 18:04:38)

Offline

#22 2008-09-05 21:07:05

thayer
Fellow
From: Vancouver, BC
Registered: 2007-05-20
Posts: 1,560
Website

Re: Simple SLIM Question

fflarex wrote:

No, I mean you can do that without a graphical login manager, using the same technique that SLiM uses to do it...

You're absolutely right, though it does add another step in the login process (having to type startx<Enter>).  I had forgotten about that though--thanks for the reminder!  For the record, it'd look something like this in ~/.xinitrc

DEFAULT_SESSION=xmonad
case $1 in
xfce)
  exec startxfce4
  ;;
awesome)
  exec awesome
  ;;
dwm)
  exec dwm
  ;;
*)
  $HOME/bin/dzonky &
  sleep 1
  stalonetray -bg '#1a1a1a' -d none --geometry 64x16+560-1036 &
  exec $DEFAULT_SESSION
  ;;
esac

Last edited by thayer (2008-09-05 21:09:59)


thayer williams ~ cinderwick.ca

Offline

#23 2008-09-05 22:11:09

moljac024
Member
From: Serbia
Registered: 2008-01-29
Posts: 2,676

Re: Simple SLIM Question

Yes, but you guys are missing the point. You can't select the session prior to logging in. Bah, should just drop it wink


The day Microsoft makes a product that doesn't suck, is the day they make a vacuum cleaner.
--------------------------------------------------------------------------------------------------------------
But if they tell you that I've lost my mind, maybe it's not gone just a little hard to find...

Offline

#24 2008-09-06 01:14:49

fflarex
Member
Registered: 2007-09-15
Posts: 466

Re: Simple SLIM Question

Okay, fair enough. I can think of at least one solution to getting around that limitation, but it's fairly hack-ish and messy. You win.

Although I was never really arguing against graphical login managers. I use SLIM myself...

Offline

Board footer

Powered by FluxBB