Author Topic: Power Failure issues  (Read 1069 times)

0 Members and 1 Guest are viewing this topic.

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Power Failure issues
« on: March 27, 2025, 09:46:33 AM »
I had a power failure issue that lasted longer than my UPS battery.

I could not get Weather Display to work by copying my backup ini file.

I backup my entire wddisplay file every night at 1am. I copied that file over and still had to setup weather display for my Vantage Pro 2. Weather display is now downloading data from the vantage pro.

Now when I load my website, I get the following errors -

Warning: Undefined array key 1 in /home4/scannor1/public_html/ajax-dashboard6.php on line 2973

Warning: Undefined array key 2 in /home4/scannor1/public_html/ajax-dashboard6.php on line 2976


Also, portions of the website home page are extended wider than normal.

I have looked at the ajax file at the two lines mentioned and do not see what is wrong. No files were changed on the website.

scannorthcounty.net

John
John
Westminster, MA USA

Offline saratogaWX

  • Administrator
  • Forecaster
  • *****
  • Posts: 9697
  • Saratoga, CA, USA Weather - free PHP scripts
    • Saratoga-Weather.org
Re: Power Failure issues
« Reply #1 on: March 27, 2025, 11:59:54 AM »
It's a known issue when WD restarts after a crash.  the value for
Quote
$dateoflastrainalways = '---';
in testtags.php has an invalid date.

You'll likely need to have some rain to reset that value.

Meanwhile, you can change ajax-dashboard6.php function
Quote
function split_hash_date($datetofix) { // Added for version 6.90 Burnsville Weather Live
    global $datefmt;
to
Quote
function split_hash_date($datetofix) { // Added for version 6.90 Burnsville Weather Live
    global $datefmt;
  if($datetofix == '---') {return(array('','','na')); }
to avoid the error messages
Ken True/Saratoga, CA, USA main site: saratoga-weather.org
Davis VP1+ FARS, Blitzortung RED, GRLevel3, WD, WL, VWS, Cumulus, Meteobridge
Free weather PHP scripts/website templates - update notifications on Twitter saratogaWXPHP

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #2 on: March 27, 2025, 01:19:54 PM »
OK, got it working. Thanks for the help.

John
John
Westminster, MA USA

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #3 on: March 30, 2025, 11:18:11 AM »
After putting the ajax-dashboard6.php file back to normal, I no longer get the forecast and footer on the home page.

These errors show up on view source -

<img src="ajax-images/SI<br />
<b>Fatal error</b>:  Uncaught DivisionByZeroError: Division by zero in /home4/scannor1/public_html/ajax-dashboard6.php:2147

Stack trace:
#0 /home4/scannor1/public_html/index.php(97): include_once()
#1 {main}
  thrown in <b>/home4/scannor1/public_html/ajax-dashboard6.php</b> on line <b>2147</b><br />


I have compared the old and new ajax-dashboard6.php files and do not see any errors.

John
John
Westminster, MA USA

Offline hcorrin

  • Senior Contributor
  • ****
  • Posts: 192
    • Ballaugh Weather
Re: Power Failure issues
« Reply #4 on: March 30, 2025, 12:40:23 PM »
I would suspect a fatal error is being caused, if not already done so on line 4 of the Ajax-dashboard6.php change the display error value from 0 to 1 then at the bottom of the errors will be the error stopping the page from displaying

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #5 on: March 30, 2025, 07:04:46 PM »
I would suspect a fatal error is being caused, if not already done so on line 4 of the Ajax-dashboard6.php change the display error value from 0 to 1 then at the bottom of the errors will be the error stopping the page from displaying

Some how it fixed itself. Not sure how, but is working fine now.
John
Westminster, MA USA

Offline hcorrin

  • Senior Contributor
  • ****
  • Posts: 192
    • Ballaugh Weather
Re: Power Failure issues
« Reply #6 on: March 31, 2025, 06:59:55 AM »
The error is still there as still missing this part see attached
Probably a null value fatal error possibly in the cloud but am only gussing as not seeing the error
« Last Edit: March 31, 2025, 07:02:56 AM by hcorrin »

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #7 on: March 31, 2025, 08:14:39 AM »
The error is still there as still missing this part see attached
Probably a null value fatal error possibly in the cloud but am only gussing as not seeing the error


Strange it was working fine when I last looked.
John
Westminster, MA USA

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #8 on: March 31, 2025, 09:46:55 AM »
The error is still there as still missing this part see attached
Probably a null value fatal error possibly in the cloud but am only gussing as not seeing the error


I guee this error is still coming up. Same errors as shown on the original post. Returned to original after using Ken's suggestion until it rained again.

John
John
Westminster, MA USA

Offline hcorrin

  • Senior Contributor
  • ****
  • Posts: 192
    • Ballaugh Weather
Re: Power Failure issues
« Reply #9 on: March 31, 2025, 12:34:14 PM »
Ok the fatal error appears to be a result of no solar data which is giving a 0 which line 2147 is looking for a none 0 in order to display the image with a value in so you need to find where the solar data is coming from and why it’s not updating
your uv is still showing 0 that may not be updating either

You should have installed the backup reg file at the same time as you put the ini file in
As the march file will be overwritten now goto the February backup zip and look for the reg file with WD not running double click it that should sort the missing ftp setting etc as the registry may have got corrupted no need to do the ini file then restart WD hopefully that will sort your solar error out
« Last Edit: March 31, 2025, 12:48:04 PM by hcorrin »

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #10 on: March 31, 2025, 01:40:18 PM »


You should have installed the backup reg file at the same time as you put the ini file in
As the march file will be overwritten now goto the February backup zip and look for the reg file with WD not running double click it that should sort the missing ftp setting etc as the registry may have got corrupted no need to do the ini file then restart WD hopefully that will sort your solar error out

Since my solar and uv are not updating properly from weather Display, I set them to false in settings-weather.php and that seemed to solve the problem. There are now no errors that I can see on the home page. Will keep an I on it. Thanks,

John
John
Westminster, MA USA

Offline hcorrin

  • Senior Contributor
  • ****
  • Posts: 192
    • Ballaugh Weather
Re: Power Failure issues
« Reply #11 on: March 31, 2025, 06:03:59 PM »
your status page shows the noaa files are not being uploaded ie climatedataout.html, dailynoaareport.htm and dailynoaareport32025.htm which should be uploading just after midnight with the avg and extremes files this is why your reports only show to the 25th
what station do now have as the about page says weather monitor ll
what solar / vu have you got

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #12 on: March 31, 2025, 07:23:53 PM »
your status page shows the noaa files are not being uploaded ie climatedataout.html, dailynoaareport.htm and dailynoaareport32025.htm which should be uploading just after midnight with the avg and extremes files this is why your reports only show to the 25th
what station do now have as the about page says weather monitor ll
what solar / vu have you got

Vantage Pro 2. I should update my about page. Solar comes from Weather Flow through Weather Display, but it never works properly. Will check the files in the morning and see if they update properly.

John
John
Westminster, MA USA

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #13 on: April 02, 2025, 09:52:59 AM »
your status page shows the noaa files are not being uploaded ie climatedataout.html, dailynoaareport.htm and dailynoaareport32025.htm which should be uploading just after midnight with the avg and extremes files this is why your reports only show to the 25th
what station do now have as the about page says weather monitor ll
what solar / vu have you got

After updating the reg file from February, The NOAA reports are still not updating. Not sure where to check to correct the problem.

John
John
Westminster, MA USA

Offline hcorrin

  • Senior Contributor
  • ****
  • Posts: 192
    • Ballaugh Weather
Re: Power Failure issues
« Reply #14 on: April 02, 2025, 10:54:29 AM »
Ok so first in the WD webfiles folder are the three file mentioned in my last post up to date and is there a dailynoaareport42025 file now
The 2 attachment may help in img3960 look at #41 but try the upload buttons on img3959 first and see if they update on web assuming they are updating locally ok
« Last Edit: April 02, 2025, 11:20:31 AM by hcorrin »

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #15 on: April 02, 2025, 07:27:06 PM »
Ok so first in the WD webfiles folder are the three file mentioned in my last post up to date and is there a dailynoaareport42025 file now
The 2 attachment may help in img3960 look at #41 but try the upload buttons on img3959 first and see if they update on web assuming they are updating locally ok

The upload switches were off for noaa report daily and upload standard reports. I changed them to on and did a manual upload and appears things are back to normal. Status page is all current. Appreciate the assistance. John
John
Westminster, MA USA

Offline hcorrin

  • Senior Contributor
  • ****
  • Posts: 192
    • Ballaugh Weather
Re: Power Failure issues
« Reply #16 on: April 03, 2025, 04:38:27 AM »
Looking at you rain detail page you need to manually upload the dailynoaareport32025.htm and the climatedataout32025.html files as they would not have uploaded via the upload button, try the attached to upload them, check they have the full month data in first if not they will need recreating check under ave/ extream
The April data appears to have updated ok over night so your almost there
« Last Edit: April 03, 2025, 04:50:37 AM by hcorrin »

Offline Johnmac

  • Senior Contributor
  • ****
  • Posts: 183
    • Westminster Massachusetts Weather
Re: Power Failure issues
« Reply #17 on: April 03, 2025, 10:56:00 AM »
Looking at you rain detail page you need to manually upload the dailynoaareport32025.htm and the climatedataout32025.html files as they would not have uploaded via the upload button, try the attached to upload them, check they have the full month data in first if not they will need recreating check under ave/ extream
The April data appears to have updated ok over night so your almost there

OK, Think I have all sorted out now. Only missing one day of data on March 26, the day of the power failure which is fine.

John
John
Westminster, MA USA

 

anything