List Info

Thread: how to run root cmds when starting xorg?




how to run root cmds when starting xorg?
country flaguser name
Hungary
2007-02-24 17:24:49
how do i exec a kldload script when starting ttyv8 kdm (or
xorg) ?
_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

Re: how to run root cmds when starting xorg?
country flaguser name
United States
2007-02-25 16:43:00
On Sun, 25 Feb 2007 00:24:49 +0100
deeptech71gmail.com wrote:

> From: deeptech71gmail.com
> To: freebsd-questionsfreebsd.org
> Subject: how to run root cmds when starting xorg?
> Date: Sun, 25 Feb 2007 00:24:49 +0100
> Sender: owner-freebsd-questionsfreebsd.org
> User-Agent: Thunderbird 1.5.0.9 (Windows/20061207)
> 
> how do i exec a kldload script when starting ttyv8 kdm
(or xorg) ?

modify the xorg or kdm  startup script? 

why do you need such thing?

_________________________
{Beto|Norberto|Numard} Meijome

"The greater danger for most of us is not that our aim
is too high and we miss
it. But that it is too low... and we reach it."
   Michelangelo (1475-1564)

I speak for myself, not my employer. Contents may be hot.
Slippery when wet.
Reading disclaimers makes you go blind. Writing them is
worse. You have been
Warned.
_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

Re: how to run root cmds when starting xorg?
country flaguser name
Hungary
2007-02-25 17:28:16
Norberto Meijome wrote:
> On Sun, 25 Feb 2007 00:24:49 +0100
> deeptech71gmail.com wrote:
> 
>> From: deeptech71gmail.com
>> To: freebsd-questionsfreebsd.org
>> Subject: how to run root cmds when starting xorg?
>> Date: Sun, 25 Feb 2007 00:24:49 +0100
>> Sender: owner-freebsd-questionsfreebsd.org
>> User-Agent: Thunderbird 1.5.0.9 (Windows/20061207)
>>
>> how do i exec a kldload script when starting ttyv8
kdm (or xorg) ?
> 
> modify the xorg or kdm  startup script? 

Xorg's xinitrc is a user script. Or does one of the X server
or client thing 
start as root? If so, which script runs? xinitrc didnt
work..
"...../kdm -nodaemon": exactly which one (if any)
executed as root?

> why do you need such thing?

I want to load sound support only when in a desktop
environment, and 
auto-disable it when moving back to a console. That is, I
need a script that 
loads sound when starting, and unloads when exiting kdm.
_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

Re: how to run root cmds when starting xorg?
country flaguser name
Norway
2007-02-25 18:02:14
"deeptech71gmail.com wrote:
> Norberto Meijome wrote:
>> On Sun, 25 Feb 2007 00:24:49 +0100
>> deeptech71gmail.com wrote:
>>
>>> From: deeptech71gmail.com
>>> To: freebsd-questionsfreebsd.org
>>> Subject: how to run root cmds when starting
xorg?
>>> Date: Sun, 25 Feb 2007 00:24:49 +0100
>>> Sender: owner-freebsd-questionsfreebsd.org
>>> User-Agent: Thunderbird 1.5.0.9
(Windows/20061207)
>>>
>>> how do i exec a kldload script when starting
ttyv8 kdm (or xorg) ?
>> modify the xorg or kdm  startup script? 
> 
> Xorg's xinitrc is a user script. Or does one of the X
server or client thing 
> start as root? If so, which script runs? xinitrc didnt
work..
> "...../kdm -nodaemon": exactly which one (if
any) executed as root?

The startup script is /usr/X11R6/lib/X11/xdm/Xsetup_0.  You
may also
want to have a look at /usr/X11R6/lib/X11/xdm/Xsession. 
This latter
file will call up ~/.xsession, which is where we normally
put commands
at the beginning of an X session called up through xdm. 
What I do in
that file is to call nvidia-settings and display a
background image.  I
guess ~/.xsession is the right place to put a kldload - this
file may be
simply a symlink to .xinitrc (if the setup you want is in
this file).

>> why do you need such thing?
> 
> I want to load sound support only when in a desktop
environment, and 
> auto-disable it when moving back to a console. That is,
I need a script that 
> loads sound when starting, and unloads when exiting
kdm.

Okay, when you revert to the console,
/usr/X11R6/lib/X11/xdm/Xreset may
be the right place to put a kldunload.  Or maybe you could
use
GiveConsole and TakeConsole (in the same directory) to
accomplish these
tasks.  I hope more expert users will chime in with more
information
about the difference between these various command files.

Have a look at "man xdm" as well as
/usr/X11R6/lib/X11/xdm/xdm-config.

For some reason, not many users appear to use xdm.  The
majority
apparently prefer kdm or gdm or just .xinitrc.  I find that
odd myself.
-- 
    Tore


_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

Re: how to run root cmds when starting xorg?
country flaguser name
Norway
2007-02-25 18:20:24
Tore Lund wrote:
> The startup script is /usr/X11R6/lib/X11/xdm/Xsetup_0. 
You may also
> want to have a look at /usr/X11R6/lib/X11/xdm/Xsession.
 This latter
> file will call up ~/.xsession, which is where we
normally put commands
> at the beginning of an X session called up through xdm.
 What I do in
> that file is to call nvidia-settings and display a
background image.  I
> guess ~/.xsession is the right place to put a kldload -
this file may be
> simply a symlink to .xinitrc (if the setup you want is
in this file).

Correction:  The file where I call nvidia-settings and
display a
background image is /usr/X11R6/lib/X11/xdm/Xsetup_0.
-- 
    Tore

_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

Re: Quanta+ freezes after upgrading
country flaguser name
United Kingdom
2007-02-26 07:33:02
On Monday 26 February 2007 05:32, Rico Secada wrote:
> Since I upgraded KDE to 3.5.5 Quanta+ always freezes
when I try to start it
> up. It doesn't do anything. No errors, just a freeze,
and a CPU usage of
> 97%.
>
> Has anyone else experienced problems with Quanta+ since
KDE 3.5.5?


No, as I've not upgraded yet, but to help those who might be
able to help you, 
open a shell window and run quanta from there so you can see
all the output 
as the program loads up.  Odds are you'll see it stuck in a
loop of some kind 
looking for files or trying to find backups.


-- 
Dave
_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

Re: Quanta+ freezes after upgrading
country flaguser name
Denmark
2007-02-26 19:46:04
On Mon, 26 Feb 2007 13:33:02 +0000
dgmm <freebsd01dgmm.net> wrote:

> On Monday 26 February 2007 05:32, Rico Secada wrote:
> > Since I upgraded KDE to 3.5.5 Quanta+ always
freezes when I try to start it
> > up. It doesn't do anything. No errors, just a
freeze, and a CPU usage of
> > 97%.
> >
> > Has anyone else experienced problems with Quanta+
since KDE 3.5.5?
> 
> 
> No, as I've not upgraded yet, but to help those who
might be able to help you, 
> open a shell window and run quanta from there so you
can see all the output 
> as the program loads up.  Odds are you'll see it stuck
in a loop of some kind 
> looking for files or trying to find backups.
> 

I wish!  There is
no output.

> -- 
> Dave
> _______________________________________________
> freebsd-questionsfreebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
> To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"
> 
_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

Re: how to run root cmds when starting xorg?
country flaguser name
United States
2007-02-27 08:30:15
On Saturday 24 February 2007 17:24, deeptech71gmail.com
wrote:
> how do i exec a kldload script when starting ttyv8 kdm
(or xorg) ?

Another idea not yet mentioned is to create two wrapper
scripts like so:

$ cat /usr/local/bin/loadsound
#!/bin/sh
kldload whatever.ko
$ cat /usr/local/bin/unloadsound
#!/bin/sh
kldunload whatever.ko

and the install sudo and configure it to give your user the
ability to run 
those two commands without entering your password.  Finally,
add "sudo 
loadsound" and "sudo unloadsound" to your
startup and exit scripts.
-- 
Kirk Strauser
Re: Quanta+ freezes after upgrading
country flaguser name
United Kingdom
2007-02-27 19:10:03
On Tuesday 27 February 2007 01:46, Rico Secada wrote:
> On Mon, 26 Feb 2007 13:33:02 +0000
>
> dgmm <freebsd01dgmm.net> wrote:
> > On Monday 26 February 2007 05:32, Rico Secada
wrote:
> > > Since I upgraded KDE to 3.5.5 Quanta+ always
freezes when I try to
> > > start it up. It doesn't do anything. No
errors, just a freeze, and a
> > > CPU usage of 97%.
> > >
> > > Has anyone else experienced problems with
Quanta+ since KDE 3.5.5?
> >
> > No, as I've not upgraded yet, but to help those
who might be able to help
> > you, open a shell window and run quanta from there
so you can see all the
> > output as the program loads up.  Odds are you'll
see it stuck in a loop
> > of some kind looking for files or trying to find
backups.
>
> I wish!  There is
no output.

Odd.  If I run quanta from a shell window I see all sort of
status info etc 
scrolling up the window including output from various KDE
modules, Kate and 
Quanta.  I installed from ports with the default settings.

-- 
Dave
_______________________________________________
freebsd-questionsfreebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-que
stions
To unsubscribe, send any mail to
"freebsd-questions-unsubscribefreebsd.org"

[1-9]

about | contact  Other archives ( Real Estate discussion Medical topics )