[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: startx + ~/.xsession and no ~/.xinitrc, results in reduced functionality (xfce4, sid)



Zenaan Harkness wrote:
> My .xsession is mode 755 and contains:
> ---
> #!/bin/bash --login
> exec ck-launch-session startxfce4
> ---
> 
> When I run startx, ...

Because startx does not use .xsession.  You have things criss-crossed.

  $ grep xsession /usr/bin/startx
  ... nothing shown ...

The xsession script is only used by the xdm, gdm, gdm3, kdm, lightdm X
Display Manager graphical login manager programs because they all call
the /etc/X11/Xsession script.

  $ grep -rl xsession /etc/X11/Xsession*
  /etc/X11/Xsession
  /etc/X11/Xsession.d/40x11-common_xsessionrc
  /etc/X11/Xsession.d/50x11-common_determine-startup
  /etc/X11/Xsession.options

> my xfce4 session starts, but Restart, Shutdown,
> Suspend and Hibernate are all disabled, only Logout is enabled.

I remember reading about people complaining about that happening but I
don't remember the detail as to why.

> When I do:
> cd; cp .xsession .xinitrc
> startx
> 
> my xfce4 session starts, and all the Restart, Logout etc options are
> now enabled.

Yes, because startx does use xinitrc.

  $ grep xinitrc /usr/bin/startx
  # interface than xinit.  It looks for user .xinitrc and .xserverrc
  # files, then system xinitrc and xserverrc files, else lets xinit choose
  # its default.  The system xinitrc should probably do things like check
  userclientrc=$HOME/.xinitrc
  sysclientrc=/etc/X11/xinit/xinitrc

> What seemed like a good idea, at, the, time ... is longer looking so
> good. Any ideas why this odd behaviour would appear as it does?

Frankly it is exactly as I wrote in the previous message about this. :-)
Really!  :-)

> In the meantime, it looks like I'll have to go back to using .xinitrc

If you are using startx then yes you should use xinitrc.  Only use the
xsession or xsessionrc file (either one) if you are using one of the
graphical login managers such as xdm, gdm, gdm3, kdm, lightdm.

Bob

Attachment: signature.asc
Description: Digital signature


Reply to: