Using fstab causes weewx to not update

60 views
Skip to first unread message

Timothy Buchanan

unread,
Oct 17, 2019, 3:59:01 PM10/17/19
to weewx-user
I am using nginx as the web server for weewx on an RPi3, and all works well until I try to minimize writes on the SD as suggested to prolong its life. Once I do that, the web page loads but will never update. Here are the exact commands I used (deb install):

1.  echo "weewx_reports /var/weewx/reports tmpfs size=20M,noexec,nosuid,nodev 0 0" | sudo tee -a /etc/fstab

2. sudo mkdir -p /var/weewx/reports

3. sudo mount -a

4. sudo sed -i -e 's%HTML_ROOT =.*%HTML_ROOT = /var/weewx/reports%' /etc/weewx/weewx.conf

5. sudo /etc/init.d/weewx stop

6. sudo /etc/init.d/weewx start

7. sudo ln -s /var/weewx/reports /var/www/html/weewx

8. sudo /etc/init.d/nginx restart

I am using the /etc/nginx/sites-available/default file. I tried replacing the server name in the default file with this:

server {
  ...
  location /weewx {
    alias /var/www/html/weewx/index.html;
  }
}
as recommended on another of the wiki pages, but nginx will not start with that configuration. nginx finds the weewx page with the default file. Any suggestions to make this work? Thanks.

Walter Smith

unread,
Oct 18, 2019, 9:00:31 AM10/18/19
to weewx-user
I did this about a week ago.  It changes the URL where the reports are.
On my Pi it changed the Seasons report URL from
to

Timothy Buchanan

unread,
Oct 18, 2019, 1:04:44 PM10/18/19
to weewx-user
Thanks! I will try again, knowing this.
Reply all
Reply to author
Forward
0 new messages