Apache 2.4 on raspbian doesn't display wx data

70 views
Skip to first unread message

IL

unread,
Aug 26, 2019, 10:49:16 AM8/26/19
to weewx-user
I am trying to configure weewx to receive wx data from a Froggit WH3000SE weather station. Messages like these are shown in syslog:

Aug 26 15:56:08 wxpi weewx[23866]: manager: Added record 2019-08-26 15:55:00 CEST (1566827700) to database 'weewx.sdb'
Aug 26 15:56:08 wxpi weewx[23866]: manager: Added record 2019-08-26 15:55:00 CEST (1566827700) to daily summary in 'weewx.sdb'
Aug 26 15:56:11 wxpi weewx[23866]: cheetahgenerator: Generated 8 files for report SeasonsReport in 1.57 seconds
Aug 26 15:56:12 wxpi weewx[23866]: imagegenerator: Generated 14 images for SeasonsReport in 0.97 seconds
Aug 26 15:56:12 wxpi weewx[23866]: copygenerator: copied 0 files to /var/www/html/weewx

The files go into /var/www/html/weewx and if I enter "file:///var/www/html/weewx/index.html" into the address field of a web browser this file (with reasonable data) is shown.

I have configured Apache to use port 8000 to avoid port 80 as this is used by the weewx-interceptor. When I address the browser to localhost:8000 the default Apache page is shown. I have tried to get the browser to display the weewx page using addresses like localhost:/weewx:8000 or localhost:/weewx/index.html:8000 but then it displays a page with the single word "success".

I have tried to configure Apache but the instructions seem to be for earlier versions, so here I would need some help. There are no error messages when I restart Apache. Even with bad configuration I think it should be possible to have the weewx page displayed when using the explicit address. The  result is also the same with the default (?) configuration. (The ? marks that I am not quite sure, as this server has been in use for some time in another configuration.)




vince

unread,
Aug 26, 2019, 5:56:13 PM8/26/19
to weewx-user
On Monday, August 26, 2019 at 7:49:16 AM UTC-7, IL wrote:

The files go into /var/www/html/weewx and if I enter "file:///var/www/html/weewx/index.html" into the address field of a web browser this file (with reasonable data) is shown.

I have configured Apache to use port 8000 to avoid port 80 as this is used by the weewx-interceptor. When I address the browser to localhost:8000 the default Apache page is shown. I have tried to get the browser to display the weewx page using addresses like localhost:/weewx:8000 or localhost:/weewx/index.html:8000 but then it displays a page with the single word "success".


This isn't a weewx problem, it's a "how do I set up Apache" problem.   That is likely documented in a million howtos already.

My 'guess' is that your Apache config is expecting the HTML document root in one place, and you have weewx configured to copy to a different directory.    Check your apache config files for what your document root is for your port 8000 virtual server.   Also check your Apache logs.

Alternate thing to try would be to open http://localhost:8000/html and see if that shows your weewx pages.  If you see weewx stuff there, you're just copying to one level too deep, meaning your document root is incorrect in weewx.conf.

IL

unread,
Aug 27, 2019, 5:46:24 AM8/27/19
to weewx-user
Of course you are right that this is a "how do I set up Apache" problem. I realized it was a permission problem and found out that I had to modify 000-default.conf in /etc/apache2/sites-available, so now it is working.
Reply all
Reply to author
Forward
0 new messages