no connection to the web server

249 views
Skip to first unread message

eckha...@googlemail.com

unread,
May 28, 2021, 7:59:44 PM5/28/21
to weewx-user

Hey

Hardware:
Froggit WS1050
Pi 4
Rasbian os
Weewx 4.5.1
LOG:
pi@raspberrypi:~ $ tail -f /var/log/syslog
May 29 00:50:23 raspberrypi systemd[727]: Listening on GnuPG network certificate                                                                                management daemon.
May 29 00:50:23 raspberrypi systemd[727]: Listening on GnuPG cryptographic agent                                                                                and passphrase cache (access for web browsers).
May 29 00:50:23 raspberrypi systemd[727]: Reached target Sockets.
May 29 00:50:23 raspberrypi systemd[727]: Reached target Basic System.
May 29 00:50:23 raspberrypi systemd[727]: Reached target Default.
May 29 00:50:23 raspberrypi systemd[727]: Startup finished in 163ms.
May 29 00:50:23 raspberrypi systemd[1]: Started User Manager for UID 1000.
May 29 00:50:23 raspberrypi systemd[1]: Started Session 1 of user pi.
May 29 00:50:23 raspberrypi dhcpcd[601]: eth0: fe80::cece:1eff:fe3a:d164 is reac                                                                               hable again
May 29 00:50:23 raspberrypi dhcpcd[601]: eth0: fe80::cece:1eff:fe3a:d164 is reac                                                                               hable again
May 29 00:50:25 raspberrypi systemd[1]: systemd-hostnamed.service: Succeeded.
May 29 00:50:34 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: new data
May 29 00:50:34 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: setting sensor clock 10.0725
May 29 00:50:34 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: live synchronised
May 29 00:50:34 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: packet timestamp is 23:50:34
May 29 00:50:34 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: estimated log time 23:36:04 +/- 30s (23:35:34..23:36:34)
May 29 00:51:19 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: avoid 5.861218690872192
May 29 00:51:25 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: new data
May 29 00:51:25 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: packet timestamp is 23:51:22
May 29 00:51:25 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: estimated log time 23:35:58 +/- 24s (23:35:34..23:36:22)
May 29 00:52:07 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: avoid 5.878083229064941
May 29 00:52:13 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: new data
May 29 00:52:13 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: packet timestamp is 23:52:10
May 29 00:52:13 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: estimated log time 23:35:52 +/- 18s (23:35:22..23:36:10)
May 29 00:52:55 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: avoid 5.862777233123779
May 29 00:53:01 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: new data
May 29 00:53:01 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: packet timestamp is 23:52:58
May 29 00:53:01 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: estimated log time 23:36:04 +/- 6s (23:35:58..23:36:10)
May 29 00:53:01 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: synchronised to 2021-05-28 23:36:04 for ptr 0x2110
May 29 00:53:01 raspberrypi weewx[471] DEBUG weewx.drivers.fousb: found 0 archive records
May 29 00:53:01 raspberrypi weewx[471] INFO weewx.engine: Starting main packet loop.


Install by setup.py

the installation was without any problems. but now I can't get the apache2 forwarding ... I can't find the fault ...


There are all the necessary html files on the server, but I can't call any ...


need help -

eckha...@googlemail.com

unread,
May 28, 2021, 8:00:54 PM5/28/21
to weewx-user
addendum

May 29 00:56:02 raspberrypi weewx[471] INFO weewx.manager: Added record 2021-05-29 00:55:00 BST (1622246100) to database 'weewx.sdb'
May 29 00:56:02 raspberrypi weewx[471] INFO weewx.manager: Added record 2021-05-29 00:55:00 BST (1622246100) to daily summary in 'weewx.sdb'
May 29 00:56:02 raspberrypi weewx[471] DEBUG weewx.reportengine: Running reports for latest time in the database.
May 29 00:56:02 raspberrypi weewx[471] DEBUG weewx.reportengine: Running report 'SeasonsReport'
May 29 00:56:02 raspberrypi weewx[471] DEBUG weewx.reportengine: Found configuration file /home/weewx/skins/Seasons/skin.conf for report 'SeasonsReport'
May 29 00:56:02 raspberrypi weewx[471] DEBUG weewx.cheetahgenerator: Using search list ['weewx.cheetahgenerator.Almanac', 'weewx.cheetahgenerator.Station', 'weewx.cheetahgenerator.Current', 'weewx.cheetahgenerator.Stats', 'weewx.cheetahgenerator.UnitInfo', 'weewx.cheetahgenerator.Extras', 'weewx.cheetahgenerator.JSONHelpers']
May 29 00:56:02 raspberrypi weewx[471] DEBUG weewx.manager: Daily summary version is 4.0
May 29 00:56:04 raspberrypi weewx[471] INFO weewx.cheetahgenerator: Generated 8 files for report SeasonsReport in 2.03 seconds
May 29 00:56:04 raspberrypi weewx[471] DEBUG weewx.manager: Daily summary version is 4.0
May 29 00:56:05 raspberrypi weewx[471] INFO weewx.imagegenerator: Generated 15 images for report SeasonsReport in 0.58 seconds
May 29 00:56:05 raspberrypi weewx[471] INFO weewx.reportengine: Copied 5 files to /home/weewx/public_html
May 29 00:56:05 raspberrypi weewx[471] DEBUG weewx.reportengine: Report 'SmartphoneReport' not enabled. Skipping.
May 29 00:56:05 raspberrypi weewx[471] DEBUG weewx.reportengine: Report 'MobileReport' not enabled. Skipping.
May 29 00:56:05 raspberrypi weewx[471] DEBUG weewx.reportengine: Report 'StandardReport' not enabled. Skipping.
May 29 00:56:05 raspberrypi weewx[471] DEBUG weewx.reportengine: Report 'FTP' not enabled. Skipping.
May 29 00:56:05 raspberrypi weewx[471] DEBUG weewx.reportengine: Report 'RSYNC' not enabled. Skipping.
May 29 00:56:50 raspberrypi dhcpcd[601]: eth0: Router Advertisement from fe80::cece:1eff:fe3a:d164

Tom Keffer

unread,
May 28, 2021, 8:15:55 PM5/28/21
to weewx-user
Weewx seems to be running normally. 

Is there a question in there? Did you look in /home/weewx/public_html?

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/1dc96e0f-e0cf-4a9c-be28-5cebf436a983n%40googlegroups.com.

eckha...@googlemail.com

unread,
May 28, 2021, 8:33:35 PM5/28/21
to weewx-user


weewx.PNG

eckha...@googlemail.com

unread,
May 28, 2021, 8:34:30 PM5/28/21
to weewx-user
Unbenannt.PNG

eckha...@googlemail.com

unread,
May 28, 2021, 8:40:53 PM5/28/21
to weewx-user

index.PNG


the funny thing is there is also data in the file but i can't call it up

Tom Keffer

unread,
May 28, 2021, 9:08:58 PM5/28/21
to weewx-user
Everything looks totally normal to me. Did you browse to file:///home/weewx/public_html/?

Or, did you tell your webserver to look there?

storm...@gmail.com

unread,
May 28, 2021, 9:22:18 PM5/28/21
to weewx-user
Do you have the file "weewx.conf" in  "/etc/apache2/conf-enabled/" folder?


Alias /weewx /home/weewx/public_html
<Directory /home/weewx/public_html>
    Options FollowSymlinks
    AllowOverride None
    Require all granted
</Directory>

If not, add the file and restart apache2

vince

unread,
May 28, 2021, 9:45:52 PM5/28/21
to weewx-user

See if the FAQ helps any.

You've established weewx is generating files.  You haven't pinned down whether weewx+apache are in agreement on where the web pages are, nor if apache is running at all.

eckha...@googlemail.com

unread,
May 29, 2021, 4:25:05 AM5/29/21
to weewx-user
i reinstalled all of them ... then i checked the folders on the spot and checked their contents. without success! I give up.

storm...@gmail.com

unread,
May 29, 2021, 8:52:20 AM5/29/21
to weewx-user
Check to see if the  weewx.conf  is also in  /etc/apache2/conf-available folder.

Tom Keffer

unread,
May 29, 2021, 9:40:49 AM5/29/21
to weewx-user
He may not be using Apache. Indeed, he may not have a webserver at all --- we don't know.

Rainer Lang

unread,
May 29, 2021, 12:31:10 PM5/29/21
to weewx...@googlegroups.com
@OP: don't give up too early, too fast 😉

As per his OP, it looks as if he is using Apache2, however, if the web server is configured properly and configured to display the html files created under /home/weewx/public_html (and if it's running at all) is a different question.

Weewx seems to run properly, saves every 5 minutes data to the database and the pictures and the html page of the Seasons skin are created - the issue is that they are not displayed in the browser.

So it appears to be web server configuration question

Afaik, by default, apache2 expects files to be read from outside via http/https to be located in /var/www/html and subdirectories.
If another directory / path is being used (e.g. /home/weewx/public_html), Apache needs to be told (and needs to have read rights for this directory).

maybe for an inexperienced user (we don't know the experience level of the OP) our explanations need to be more explicit

first of all, as stupid as it may sound, apache needs to run:
check via: service apache2 status
then
see what several posts/replies suggest:
---------------
... have the file "weewx.conf" in  "/etc/apache2/conf-enabled/" folder?

this file (weewx.conf) is NOT the weewx.conf from /etc/weewx used to start weewx
but a file with the same name (i.e. weewx.conf) and it should have the content which is shown below, starting with "Alias /weewx ...." (without "")

Alias /weewx /home/weewx/public_html
<Directory /home/weewx/public_html>
    Options FollowSymlinks
    AllowOverride None
    Require all granted
</Directory>
---------------
if it exists, check if the content matches the bold text above
if it doesn't exist, create a text file weewx.conf with the above content in bold - save !

apache2 needs to be restarted after changes made (or creation) of/to (the Apache specific file) weewx.conf
with
sudo /etc/init.d/apache2 restart

then in principle the Seasons skin should be visible in the web browser

Another test could be to copy the content of /home/weewx/public_html
to /var/www/html/weewx
(create the folder weewx if not existing with sudo mkdir /var/www/html/weewx)
allow apache to read it 
sudo chmod -R 755 /var/www/html/weewx
and then check in the browser:
http://ip-address/weewx

if this works, apache2 is running properly and also hasn't been told where to pick up the weewx index.html

vince

unread,
May 29, 2021, 12:46:29 PM5/29/21
to weewx-user
On Saturday, May 29, 2021 at 1:25:05 AM UTC-7 eckha...@googlemail.com wrote:
i reinstalled all of them ... then i checked the folders on the spot and checked their contents. without success! I give up.

vince schrieb am Samstag, 29. Mai 2021 um 03:45:52 UTC+2:
See if the FAQ helps any.

You've established weewx is generating files.  You haven't pinned down whether weewx+apache are in agreement on where the web pages are, nor if apache is running at all.

I suspect that we have a translation to English problem here.
The problem descriptions are so cryptic and short that we cannot determine what you are doing, and you refuse to give us transcripts of what you are seeing.

  • Try to open http://x.x.x.x in a browser and tell us what Apache responds with
  • They try to open http://x.x.x.x/weewx and tell us what Apache responds with
  • (put in the ip address of your webserver above please)

Do not say "it didn't work" or "without success".

Give us an exact transcript of what the browser returned to you.

lloyd...@gmail.com

unread,
Aug 4, 2021, 1:55:24 PM8/4/21
to weewx-user
Well I had a similar problem and what lang... posted about having have the file "weewx.conf" in  "/etc/apache2/conf-enabled/" folder turned out to be the trick.  Note this is different than what the Users Guide has which is sudo cp util/apache/conf.d/weewx.conf /etc/apache2/conf.d  So should it be sudo cp util/apache/conf.d/weewx.conf /etc/apache2/conf-enabled/weewx.conf instead??? And did I screw up conf.d when I did the copy paste from the users guide? Or did I just add a unused file to /etc/apache2/ ?

vince

unread,
Aug 5, 2021, 12:25:00 PM8/5/21
to weewx-user
Some of the documentation has been around for years and might have been created versus previous versions of operating systems or webserver software.

Basically you need to copy the file into the conf.d directory for your version of apache.    Unfortunately that path might be different for varying operating systems and/or apache versions, so you do need to line things up with whatever your operating systems instance of apache expects.   You can't break anything either way.  Just match what your os expects.

gjr80

unread,
Aug 5, 2021, 5:08:21 PM8/5/21
to weewx-user
I’ve reworked the Apache setup stanza in the User’s Guide as well as the web server wiki page to remove the disconnect between the two documents. Subject to the rigours of the WeeWX Documentation Review Committee the revised User’s Guide should appear in the next release.

Gary

Reply all
Reply to author
Forward
0 new messages