1

First post, y'all. Please be gentle ;)

I decided that whatever the default temperature thresholds at which i8kmon sets the fan speeds were inadequate. I would seem to kick the fan on under load, and then never shut off (probably because the lower threshold temperature is set too low?).

So I set off creating the custom config file (as described in the i8kmon manpages) in /etc/default/i8kmon. The contents of the file were exactly this:

set config(0) {{0 0}  "-"1  60  "-"1  65}
set config(1) {{1 0}  50  70  55  75}
set config(2) {{1 1}  60  80  65  85}
set config(3) {{2 2}  70 128  75 128}

This however, is not seemed to be liked by i8kmon, as it no longer works after placing the config file. Here's the output of systemctl status i8kmon.service:

systemctl status i8kmon.service 
● i8kmon.service - LSB: Dell fan/cpu-temperature monitor
   Loaded: loaded (/etc/init.d/i8kmon; bad; vendor preset: enabled)
   Active: failed (Result: exit-code) since Mon 2016-01-04 20:33:57 PST; 9s ago
     Docs: man:systemd-sysv-generator(8)
  Process: 3766 ExecStop=/etc/init.d/i8kmon stop (code=exited, status=2)
  Process: 3770 ExecStart=/etc/init.d/i8kmon start (code=exited, status=2)
    Tasks: 2 (limit: 512)
   CGroup: /system.slice/i8kmon.service
           └─3545 tclsh /usr/bin/i8kmon --daemon --nouserconfig --auto

Jan 04 20:33:57 notebook systemd[1]: i8kmon.service: Control process exited, code=exited status=2
Jan 04 20:33:57 notebook systemd[1]: Stopped LSB: Dell fan/cpu-temperature monitor.
Jan 04 20:33:57 notebook systemd[1]: i8kmon.service: Unit entered failed state.
Jan 04 20:33:57 notebook systemd[1]: i8kmon.service: Failed with result 'exit-code'.
Jan 04 20:33:57 notebook systemd[1]: Starting LSB: Dell fan/cpu-temperature monitor...
Jan 04 20:33:57 notebook i8kmon[3770]: /etc/init.d/i8kmon: 1: /etc/default/i8kmon: Syntax error: "(" unexpected
Jan 04 20:33:57 notebook systemd[1]: i8kmon.service: Control process exited, code=exited status=2
Jan 04 20:33:57 notebook systemd[1]: Failed to start LSB: Dell fan/cpu-temperature monitor.
Jan 04 20:33:57 notebook systemd[1]: i8kmon.service: Unit entered failed state.
Jan 04 20:33:57 notebook systemd[1]: i8kmon.service: Failed with result 'exit-code'.

But here's the line specifically that intrigues me, of course:

Jan 04 20:33:57 notebook i8kmon[3770]: /etc/init.d/i8kmon: 1: /etc/default/i8kmon: Syntax error: "(" unexpected

So. I am fairly confident I haven't made any syntax errors in the config file. (Note that it was copy-pasted verbatim into the config file).

Also would be interesting to note this; that I have successfully gotten this working in Fedora 23 (albeit the work was of a more manual nature). The key differences (that I can recall) are that 1), the file is placed in /etc/i8kmon.conf, rather than /etc/default/i8kmon (notice no .conf here in Ubuntu for some reason), and 2), the fedora manpage for i8kmon doesn't call for the weird quotation marks around the dashes.

Any thoughts on this?

1 Answers1

1

You should place the configuration file in /etc/i8kmon.conf instead of /etc/default/i8kmon. The i8kmon utility is a TK script which has a hardcoded path for the configuration file. See the output of grep sysconfig /usr/bin/i8kmon.

According to the below pages, /etc/default configuration files work with an incompatible logic of loading the configuration file into the executing shell's environment and therefore assuming that the configuration file syntax is that of the shell's. The i8kmon man page is in error because it doesn't mention the other (the original) configuration channel. What is the purpose of /etc/default? https://superuser.com/questions/46139/what-does-source-do

loop
  • 290
  • 2
  • 8