Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
smartpi manual install
#1
Hi,
I installed smartpi 1.0.0 manually as guided in the documentation, but it does not start measuring anything.
I want to use manual install because I use the system to collect temperature values with RuuviTag as well (ruuvi.com).
Below are some details, what might I have missed during installation?
One difference I noticed compared to the complete image - node-red has not been installed (although I do not need it).

Regards, Tapio


/boot/config.txt has the following lines, the upper one uncommented by me and the lower one as the default.
dtparam=i2c_arm=on
dtparam=i2c1=on


pi@smartpi:~ $ ps -ef | grep smartpi | grep -v grep
avahi      349     1  0 Jan01 ?        00:00:35 avahi-daemon: running [smartpi.local]
root       499     1  0 Jan01 ?        00:00:00 su pi -c /usr/local/bin/smartpiserver
root       501     1  0 Jan01 ?        00:00:02 /bin/bash /usr/local/bin/smartpi_check_umts.sh
pi         601   499  0 Jan01 ?        00:00:46 /usr/local/bin/smartpiserver


pi@smartpi:~ $ sudo systemctl status smartpi
● smartpi.service - SmartPi
   Loaded: loaded (/etc/systemd/system/smartpi.service; enabled; vendor preset: enabled)
   Active: active (running) since Wed 2020-01-01 17:34:44 EET; 15h ago
  Process: 480 ExecStart=/usr/local/bin/smartpi start (code=exited, status=0/SUCCESS)
    Tasks: 2 (limit: 2200)
   Memory: 4.9M
   CGroup: /system.slice/smartpi.service
           ├─  501 /bin/bash /usr/local/bin/smartpi_check_umts.sh
           └─13559 sleep 300

Jan 02 09:01:42 smartpi su[13477]: (to pi) root on none
Jan 02 09:01:42 smartpi su[13477]: pam_unix(suConfusedession): session opened for user pi by (uid=0)
Jan 02 09:01:42 smartpi su[13484]: (to root) root on none
Jan 02 09:01:42 smartpi su[13484]: pam_unix(suConfusedession): session opened for user root by (uid=0)
Jan 02 09:01:43 smartpi su[13484]: pam_unix(suConfusedession): session closed for user root
Jan 02 09:06:43 smartpi su[13549]: (to pi) root on none
Jan 02 09:06:43 smartpi su[13549]: pam_unix(suConfusedession): session opened for user pi by (uid=0)
Jan 02 09:06:43 smartpi su[13556]: (to root) root on none
Jan 02 09:06:43 smartpi su[13556]: pam_unix(suConfusedession): session opened for user root by (uid=0)
Jan 02 09:06:43 smartpi su[13556]: pam_unix(suConfusedession): session closed for user root
Reply
#2
Hi, Tapio,

the smartpireadout process is not running. 
Try starting it with:

Code:
sudo /usr/local/bin/smartpireadout

I suspect there will be an I2C error message. This indicates a faulty cable connection between Raspberry Pi and smartpi module.

Greetings Jens
Reply
#3
(08.01.2020, 11:20)jens Wrote: Hi, Tapio,

the smartpireadout process is not running. 
Try starting it with:

Code:
sudo /usr/local/bin/smartpireadout

I suspect there will be an I2C error message. This indicates a faulty cable connection between Raspberry Pi and smartpi module.

Greetings Jens

Hi,
after my SDHC card got corrupted again, I had to reinstall my Smartpi + Ruuvi collector combination once again. This time I selected USB memory instead. It should be more reliable I was told.

Now I was motivated to do deeper debugging on why smartpireadout process does not run. As the /usr/local/bin/smartpi starts it as user pi, I manually ran /usr/local/bin/smartpireadout and noticed that it exited (panic) with message "access denied". It was not able to write to /var/run/smartpi_values, which is the default setting in /etc/smartpi right after installation I was able to read the configuration that is defined in the zip image, and there was the difference. The package defines another directory where user pi has write access. Below is the summary to make the manual install work:

vi /etc/smartpi
# This is the default after installation (sudo apt-get install smartpi). User pi does not have write access on this directory.
shared_dir  = /var/run
shared_file = smartpi_values

# FIX
# This is how it is configured in the zip package - this works
shared_dir  = /var/tmp/smartpi
shared_file = values
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)