Comment # 6 on bug 1211799 from Dead Mozay
(In reply to Valentin Lefebvre from comment #5)
> (In reply to Dmitry Markov from comment #0)
> > all environments in files /etc/environment.d/* & /etc/environment are
> > ignored by the system.
> 
> Hello, Thanks for your message.
> 
> pam_env.so will only check environment variable in /etc/environment file not
> in directory /etc/environment.d/*. If you want to use multiple environment
> files you need to add the argument "envfile" in the line wher pam_env.so is
> called in some pam configuration files. To knwo where pam_env is called you
> can run the following command:
> 
> `grep "pam_env" /usr/lib/pam.d/* /etc/pam.d/*`
> 
> But it looks like your /etc/environment  file is skipped. From my test, I
> don't get any issue with that with Tumbleweed image. Could it be possible to
> have the content of your file /etc/environment please ?
> 
> 
> (In reply to Dead Mozay from comment #2)
> > > kernel:   with environment:
> > > plymouthd[508]: 00:00:05.290 main.c:2017:initialize_environment                            : source built on May 22 2023
> > > plymouthd[990]: 00:00:08.299 main.c:2017:initialize_environment                            : source built on May 22 2023
> > > (systemd)[2073]: pam_env(systemd-user:session): Unable to read configuration file /usr/etc//environment line 8: Missing delimiter
> > > lightdm[1996]: pam_env(lightdm-autologin:session): Unable to read configuration file /usr/etc//environment line 8: Missing delimiter
> > > sudo[5576]: pam_env(sudo:setcred): Unable to read configuration file /usr/etc//environment line 8: Missing delimiter
> > > sudo[5576]: pam_env(sudo:session): Unable to read configuration file /usr/etc//environment line 8: Missing delimiter
> > 
> > This happens with any variable.
> > But if you do
> > > source /usr/etc/environment
> > 
> > then the variable works without problems
> 
> Thanks for your feedback too.
> 
> Your /usr/etc/environment file looks to be not well formatted to the pam_env
> library. Especially at the line 8 where it should miss the delimiter "=".
> Same, should it be possible to have the content of your /usr/etc/environment
> file please ?

Everything is fine with variables, if you execute source /usr/etc/environment,
then the variable starts working without problems and errors. I used these
variables long before the error appeared. After some update, the ENV="foobar"
variant worked, only in normal quotes, ENV=' foobar' and ENV=foobar, etc. In
addition, a non-working option breaks various units, for example, ssh stops
working despite the fact that the variable does not concern it at all

And it also seems that scripts from /etc/profile.d/* and /usr/etc/profile.d/*
stopped working because of this


You are receiving this mail because: