FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Ubuntu > Edubuntu User

 
 
LinkBack Thread Tools
 
Old 09-11-2008, 08:35 PM
Pierre Yann Baco
 
Default ldm numlock

Jordan Erickson a écrit :

> Apparently the reason numlockx doesn't work for LDM is that it gets
> launched AFTER LOGIN (xsession.d script). This was the issue that halted
> my own research.
>
That's what I realized too. With GDM (used with LTSP4.2), you could edit
/etc/gdm/Init/Default to start numlockx BEFORE the greeter. But
/etc/X11/Xsession.d/scripts are only launched AFTER a successful login.

I guess there was some misunderstanding about WHEN I'd like to get
NumLock on: right BEFORE ldm greeter is displayed (user unknown at this
stage) and not AFTER (session started).

BTW, I've just tried Scott' suggestion (adding a numlockx script in
/opt/ltsp/i386/usr/share/ldm/rc.d/, like "S20-numlockx-on") but no success.


Pierre




--
edubuntu-users mailing list
edubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/edubuntu-users
 
Old 09-11-2008, 08:40 PM
Scott Balneaves
 
Default ldm numlock

On Thu, Sep 11, 2008 at 01:18:55PM -0700, Jordan Erickson wrote:
> Jeez.. Sorry for confusion, Scott you weren't the one I talked to, it
> was vagrantc.
>
> Apparently the reason numlockx doesn't work for LDM is that it gets
> launched AFTER LOGIN (xsession.d script). This was the issue that halted
> my own research.

So, it does work, but just after the user logs in? You want it enabled while
the user is still sitting at the login prompt?

If that's the case, then just shoehorn it into the ldm screen script somewhere.

Say, in ${CHROOT}/usr/lib/ltsp/screen.d/ldm, around line 110, just before the
call to ldm itself:

you could do the

if [ -n "${LDM_NUMLOCK}" ]; then
numlockx "${LDM_NUMLOCK}"
fi

there. Like I say, you'll just need to install numlockx in the chroot, and
ltsp-update-image on it.

Hmmm....
A quick bit of giggling has revealed that setleds is already installed, and
appears to work.

So, perhaps the ldm screen script could do a:

if [ -n "${LDM_NUMLOCK}" ]; then
setleds -D +num
fi

and of course, rebuild the image.

I'll try this tonight. It wouldn't require a new package to be added.

Cheers,
Scott
(who never, ever uses the numlock key)

--
Scott L. Balneaves | "There are many causes I am prepared to die for,
Systems Department | but no causes I am prepared to kill for."
Legal Aid Manitoba | -- Mohandas Karamchand Gandhi

--
edubuntu-users mailing list
edubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/edubuntu-users
 
Old 09-11-2008, 08:42 PM
Scott Balneaves
 
Default ldm numlock

On Thu, Sep 11, 2008 at 10:35:41PM +0200, Pierre Yann Baco wrote:

> BTW, I've just tried Scott' suggestion (adding a numlockx script in
> /opt/ltsp/i386/usr/share/ldm/rc.d/, like "S20-numlockx-on") but no success.

Since you seem to be there live right now, care to try the setleds thing I just
posted in the ldm screen script?

Cheers,
Scott

--
Scott L. Balneaves | "There are many causes I am prepared to die for,
Systems Department | but no causes I am prepared to kill for."
Legal Aid Manitoba | -- Mohandas Karamchand Gandhi

--
edubuntu-users mailing list
edubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/edubuntu-users
 
Old 09-11-2008, 09:45 PM
Jordan Erickson
 
Default ldm numlock

Hey Scott,

Thanks for looking into this. Let us know how it turns out!


- Jordan


Scott Balneaves wrote:
> On Thu, Sep 11, 2008 at 01:18:55PM -0700, Jordan Erickson wrote:
>
>> Jeez.. Sorry for confusion, Scott you weren't the one I talked to, it
>> was vagrantc.
>>
>> Apparently the reason numlockx doesn't work for LDM is that it gets
>> launched AFTER LOGIN (xsession.d script). This was the issue that halted
>> my own research.
>>
>
> So, it does work, but just after the user logs in? You want it enabled while
> the user is still sitting at the login prompt?
>
> If that's the case, then just shoehorn it into the ldm screen script somewhere.
>
> Say, in ${CHROOT}/usr/lib/ltsp/screen.d/ldm, around line 110, just before the
> call to ldm itself:
>
> you could do the
>
> if [ -n "${LDM_NUMLOCK}" ]; then
> numlockx "${LDM_NUMLOCK}"
> fi
>
> there. Like I say, you'll just need to install numlockx in the chroot, and
> ltsp-update-image on it.
>
> Hmmm....
> A quick bit of giggling has revealed that setleds is already installed, and
> appears to work.
>
> So, perhaps the ldm screen script could do a:
>
> if [ -n "${LDM_NUMLOCK}" ]; then
> setleds -D +num
> fi
>
> and of course, rebuild the image.
>
> I'll try this tonight. It wouldn't require a new package to be added.
>
> Cheers,
> Scott
> (who never, ever uses the numlock key)
>
>

--
edubuntu-users mailing list
edubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/edubuntu-users
 
Old 09-12-2008, 10:22 AM
Pierre Yann Baco
 
Default ldm numlock

Scott Balneaves a écrit :
> On Thu, Sep 11, 2008 at 10:35:41PM +0200, Pierre Yann Baco wrote:
>
>> BTW, I've just tried Scott' suggestion (adding a numlockx script in
>> /opt/ltsp/i386/usr/share/ldm/rc.d/, like "S20-numlockx-on") but no success.
>
> Since you seem to be there live right now, care to try the setleds thing I just
> posted in the ldm screen script?
>
> Cheers,
> Scott
>
1°) I've tried your suggestion, i.e. adding a call to numlockx in
${CHROOT}/usr/lib/ltsp/screen.d/ldm script, right before the call the
ldm binary.

It does not work, as X is not started yet at this stage. X starts AFTER
the ldm binary.

2°) Replacing the call to numlockx by a call to "setleds -D +num" does
work....for 1/2 second: as soon as the ldm binary takes control, NumLock
led goes off.

I guess the only solution would be to call numlockx or setleds from the
ldm binary...

Pierre



--
edubuntu-users mailing list
edubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/edubuntu-users
 
Old 09-12-2008, 03:14 PM
Scott Balneaves
 
Default ldm numlock

On Fri, Sep 12, 2008 at 12:22:49PM +0200, Pierre Yann Baco wrote:
> 1°) I've tried your suggestion, i.e. adding a call to numlockx in
> ${CHROOT}/usr/lib/ltsp/screen.d/ldm script, right before the call the
> ldm binary.
>
> It does not work, as X is not started yet at this stage. X starts AFTER
> the ldm binary.

Ah, right, I was thinking of the new way we've decided to do things, where we
start X first, and LDM simply runs under X, as opposed to ldm starting X.

> 2°) Replacing the call to numlockx by a call to "setleds -D +num" does
> work....for 1/2 second: as soon as the ldm binary takes control, NumLock
> led goes off.

Hmm, so X itself resets the numlock state. You'd like to think it would
read/honour the state of the meta keys before it starts up. OK.

> I guess the only solution would be to call numlockx or setleds from the
> ldm binary...

Well, this is a bit on the gross side. Gadi's got some patches where we can
call out rc.d scripts AFTER the X starts up, but before the greeter runs. I
think I'll backport those, then we can call setleds/numlockx from that. I hate
to hardcode a call to a binary within the program, I'd rather abstract it out
to a startup script, which is easier for a sysadmin to modify.

Cheers,
Scott

--
Scott L. Balneaves | "There are many causes I am prepared to die for,
Systems Department | but no causes I am prepared to kill for."
Legal Aid Manitoba | -- Mohandas Karamchand Gandhi

--
edubuntu-users mailing list
edubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/edubuntu-users
 

Thread Tools




All times are GMT. The time now is 10:08 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org