Bug 63477

Summary: Environment file parser gets confused by comments
Product: systemd Reporter: Alain Kalker <a.c.kalker>
Component: generalAssignee: Zbigniew Jedrzejewski-Szmek <zbyszek>
Status: RESOLVED FIXED QA Contact: systemd-bugs
Severity: normal    
Priority: medium CC: a.c.kalker, philantrop, zbyszek
Version: unspecified   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments: service file used for debugging
output of `systemctl status lm_sensors.service` after failure
/etc/conf.d/lm_sensors failing
output of `systemctl status lm_sensors.service` after success
/etc/conf.d/lm_sensors working

Description Alain Kalker 2013-04-12 16:26:31 UTC
Created attachment 77894 [details]
service file used for debugging

After installing lm_sensors package, I discovered that lm_sensors.service wasn't picking up its environment variables from its EnvironmentFile= directive.
After some experimenting, I found that only the last environment variable defined in the environment file was non-blank.

I found that the only way to ensure that all variables are set is to remove all comments (preceded by '#') from the environment file.

As I'm not entirely sure what exactly in those comments is confusing systemd, I'm including a failing and a working environment file, as well as the service file I used for debugging.
Comment 1 Alain Kalker 2013-04-12 16:49:44 UTC
Created attachment 77899 [details]
output of `systemctl status lm_sensors.service` after failure
Comment 2 Alain Kalker 2013-04-12 16:50:49 UTC
Created attachment 77901 [details]
/etc/conf.d/lm_sensors failing
Comment 3 Alain Kalker 2013-04-12 16:54:29 UTC
Created attachment 77902 [details]
output of `systemctl status lm_sensors.service` after success
Comment 4 Alain Kalker 2013-04-12 16:55:02 UTC
Created attachment 77903 [details]
/etc/conf.d/lm_sensors working
Comment 5 Zbigniew Jedrzejewski-Szmek 2013-04-14 00:26:39 UTC
Fixed in http://cgit.freedesktop.org/systemd/systemd/commit/?id=d3b6d0c21.
Comment 6 aadil khan 2019-07-19 05:48:30 UTC
Thank's to sharing this news. if your want to entertain 
http://robloxfreerobuxgenerator.com your self then go to play this amazing robux online game, it is the best time taken place for all online user

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.