What is the best remedy for running the script automatically at boot time? >Should the rc.local entry have a "&" on the end so it runs in the
background? Is it a problem with the script expecting to run in a Terminal >window that continues to have stdout?
However the web interface that the app presents (for displaying graphs of electricity usage) fails to locate smart plug devices.
Starting the script manually works fine:
(start a Terminal window)
sudo /home/pi/tplink/tplink-energy-monitor/tplink-start.sh &
What is the best remedy for running the script automatically at boot time? Should the rc.local entry have a "&" on the end so it runs in the
background?
Is it a problem with the script expecting to run in a Terminal
window that continues to have stdout?
NY <me@privacy.invalid> wrote:
However the web interface that the app presents (for displaying graphs of
electricity usage) fails to locate smart plug devices.
Starting the script manually works fine:
(start a Terminal window)
sudo /home/pi/tplink/tplink-energy-monitor/tplink-start.sh &
Does it work if you start it as the root user instead of using
sudo? When you use sudo, environment variables such as $HOME remain
set to the value for the user who runs the sudo command. If you
"sudo su" and then run the command, that is the same environment
where rc.local will start the script, where $HOME will be "/root".
What is the best remedy for running the script automatically at boot time? >> Should the rc.local entry have a "&" on the end so it runs in the
background?
No, because tplink-start.sh appears to background the main task
itself.
Is it a problem with the script expecting to run in a Terminal
window that continues to have stdout?
Maybe, I don't know anything about Node JS. The fact that looking
up "npm" finds descriptions of it as a package manager confuses me
already.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 371 |
Nodes: | 16 (2 / 14) |
Uptime: | 37:34:34 |
Calls: | 7,932 |
Calls today: | 2 |
Files: | 12,998 |
Messages: | 5,805,631 |