[LightDM] Setting environment variables the correct way for lightdm/XFCE4
OmegaPhil
OmegaPhil at startmail.com
Thu Feb 4 12:37:35 PST 2016
I currently need to set LD_PRELOAD systemwide in order to work around an
aufs kernel memory allocation problem - '/etc/environment' LD_PRELOAD is
obeyed by shells launched outside a GUI, however anything launched
through lightdm doesn't get this. I can add the export to '~/.bashrc',
however I need it also present for any GUI program launched from the X
session.
Fiddling with '/etc/profile.d/' scripts and adding it to lightdm's
init.d script didn't work, looking through lightdm's source (e.g.
seat.c) suggests it gets stripped unless LIGHTDM_TEST_ROOT is set,
however setting this in '/etc/environment' or in the init.d script still
doesn't cause LD_PRELOAD to be honoured.
The only thing that 'works' is adding the exports to
'/etc/xdg/xfce4/xinitrc', just above the '# run xfce4-session if
installed' block.
Is there a recommended way (other than this) for a sysadmin to set
LD_PRELOAD that is respected by lightdm/XFCE4/etc?
Thanks for any help
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freedesktop.org/archives/lightdm/attachments/20160204/d9c60b24/attachment.sig>
More information about the LightDM
mailing list