thomasjacquin / allsky-portal

A simple, responsive web interface to control an allsky camera connected to a Raspberry Pi
GNU General Public License v3.0
34 stars 22 forks source link

Extra features on the system page #89

Closed tony1tf closed 2 years ago

tony1tf commented 2 years ago

Can we display fan speed, dome temp, sensor temp, and humidity etc on the "system" page, please?

EricClaeys commented 2 years ago

PR #91 implements displaying fan speed. The others are harder to implement.

EricClaeys commented 2 years ago

@tony1tf, Can you please help test my first pass at implementing a generic way for users to add data, progress bars, and/or buttons to the WebUI "System" page? Rename /var/www/html/includes/system.php to system-old.php, then grab the updated system.php from here.

In config/config.sh, add a variable called WEBUI_DATA_FILES that is a colon-separated list of text files. Each file should contain the fields listed in this Wiki page under "Software settings" --> WEBUI_DATA_FILES and the 3 tables after that.

tony1tf commented 2 years ago

Hi Eric

I have downloaded the new system.php file, but I don't know what to do next. I guess your instructions about config.sh must relate to the latest version of the software. I downloaded that software from github on 21 Feb 2022, but havn't installed it yet in case it breaks my system. I only have a file config_RPiHQ.sh.repo in AllSky which has camera and software settings.

Tony

On Thu, 24 Feb 2022 at 11:16, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf, Can you please help test my first pass at implementing a generic way for users to add data, progress bars, and/or buttons to the WebUI "System" page? Rename /var/www/html/includes/system.php to system-old.php, then grab the updated system.php from here https://github.com/thomasjacquin/allsky-portal/blob/WEBUI_DATA_FILES/includes/system.php .

In config/config.sh, add a variable called WEBUI_DATA_FILES that is a colon-separated list of text files. Each file should contain the fields listed in this Wiki page https://github.com/thomasjacquin/allsky/wiki/allsky-Settings under "Software settings" --> WEBUI_DATA_FILES and the 3 tables after that.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1049753494, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTXYOSKMSDG5IOMRZ5TU4YHSLANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

EricClaeys commented 2 years ago

@tony1tf There is a Wiki page on upgrading the software. One of the first steps is to rename your current "allsky" directory so you can restore it if you have a problem. The installation creates the allsky/config/config.sh file based on the repo file you found.

What version are you currently running? Look for the word "Software" in /var/log/allsky.log.

For testing what I did was manually create a text file with data to be displayed, using dummy labels and data. The next step would be to have a script create the file. I will update the Wiki to show an example and indicate which fields change and which stay constant.

tony1tf commented 2 years ago

OK Eric,

I'll spend some time upgrading the software. There is no "Software" word in the log file. I downloaded the code originally on 22 March 2021, so it will soon be a year old.

Tony

On Thu, 24 Feb 2022 at 18:42, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf There is a Wiki page on upgrading the software. One of the first steps is to rename your current "allsky" directory so you can restore it if you have a problem. The installation creates the allsky/config/config.sh file based on the repo file you found.

What version are you currently running? Look for the word "Software" in /var/log/allsky.log.

For testing what I did was manually create a text file with data to be displayed, using dummy labels and data. The next step would be to have a script create the file. I will update the Wiki to show an example and indicate which fields change and which stay constant.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1050150504, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTV6ROODXAU3S7CDNPLU4Z3YHANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

EricClaeys commented 2 years ago

@tony1tf The /var/log/allsky.log file should have something that looks like this:

Feb 24 16:28:05 allsky allsky.sh[3762]:  ********************************************
Feb 24 16:28:05 allsky allsky.sh[3762]:  *** Allsky Camera Software v0.8.3.2 | 2022 ***
Feb 24 16:28:05 allsky allsky.sh[3762]:  ********************************************

As far as I can remember, it's always said "Allsky Camera Software" even in version 0.7 which is what you likely have. You can also check for "Camera" and "v0".

EricClaeys commented 2 years ago

@tony1tf I made what I hope is a major improvement to the WEBUI_DATA_FILES Wiki page . I beefed up descriptions of the fields and added a detailed example and description on how to test. Let me know if it helps. Any feedback is appreciated.

tony1tf commented 2 years ago

Hi Eric

I've taken the plunge and updated my Allsky to the latest version. I'm now battling with a strange large font on the images, although I can see that it still has my location information. Image attached.

Tony

On Fri, 25 Feb 2022 at 04:50, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf I made what I hope is a major improvement to the WEBUI_DATA_FILES Wiki page

https://github.com/thomasjacquin/allsky/wiki/allsky-portal-(WebUI)-settings. I beefed up descriptions of the fields and added a detailed example and description on how to test. Let me know if it helps. Any feedback is appreciated.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1050519469, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTT4LSHVLZNLY6GJG2TU44DBJANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

tony1tf commented 2 years ago

Hi Eric I reduced the font size to 20 - now OK. Tony

On Fri, 25 Feb 2022 at 18:37, Tony Abbey @.***> wrote:

Hi Eric

I've taken the plunge and updated my Allsky to the latest version. I'm now battling with a strange large font on the images, although I can see that it still has my location information. Image attached.

Tony

On Fri, 25 Feb 2022 at 04:50, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf I made what I hope is a major improvement to the WEBUI_DATA_FILES Wiki page

https://github.com/thomasjacquin/allsky/wiki/allsky-portal-(WebUI)-settings. I beefed up descriptions of the fields and added a detailed example and description on how to test. Let me know if it helps. Any feedback is appreciated.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1050519469, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTT4LSHVLZNLY6GJG2TU44DBJANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

EricClaeys commented 2 years ago

@tony1tf. FYI, GitHub doesn't support email attachments so I didn't see your image. I think the font size calculation changed in some update. I don't know if it was intentional or not.

tony1tf commented 2 years ago

Hi Eric

I'm making progress. I've changed the system.php file to your new one. Edited the config.sh file to include the WEBUI_DATA_FILES variable. Using your examples edited to my version of a python script, I can see a new button on the system page which shows "Dew Heater on". However, clicking it, which is supposed to run my onewirethermread.py code produces an error message: '/home/pi/allsky/onewirethermread.py' failed: sh: 1: /home/pi/allsky/onewirethermread.py: Permission denied I can run it successfully from a terminal running ssh logged in as pi when I cd to allsky, but I need to call it with "python onewirethermread.py" and it returns my dome temperature. I added python..... to the dewheater_status.txt file named in WEBUI_DATA_FILES, but I get a further error, so it seems the permissions are wrong since it can't find python: '/home/pi/allsky/python onewirethermread.py' failed: sh: 1: /home/pi/allsky/python: not found That's all for now - I'll try more tomorrow.

Tony

On Fri, 25 Feb 2022 at 19:24, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf. FYI, GitHub doesn't support email attachments so I didn't see your image. I think the font size calculation changed in some update. I don't know if it was intentional or not.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1051130132, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTSIGG52F5BZZJU5F4LU47JNBANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

EricClaeys commented 2 years ago

@tony1tf Thanks for the update. '/home/pi/allsky/onewirethermread.py` needs to be executable by the "www-data" group. I'm guessing the group permissions don't include "x". I updated the Wiki to mention this.

Try adding #!/usr/bin/env python3 as the FIRST line in onewirethermread.py, then do a chmod 775 onewirethermread.py and see if that fixes the problem, and allows you to run the command in ssh by simply typing ./onewirethermread.py.

WEBUI_DATA_FILES should only contain the full path to dewheater_status.txt since the web page is looking for a file with that name.

tony1tf commented 2 years ago

Hi Eric

Two problems now:

Had a problem overnight - no timelapse was generated - the file in tmp doesn't show the problem except for this message at the end:

ln -s /home/pi/allsky/images/20220225/image-20220226060718.jpg /home/pi/allsky/tmp/sequence-20220225/1316.jpg [swscaler @ 0x139ded0] deprecated pixel format used, make sure you did set range correctly

The syslog file shows it was an out of memory error when I ran the timelapse script again:

Feb 26 13:01:16 Tonysallsky kernel: [67834.659095] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=ffmpeg,pid=7116,uid=1000

Feb 26 13:01:16 Tonysallsky kernel: [67834.659188] Out of memory: Killed process 7116 (ffmpeg) total-vm:990972kB, anon-rss:476764kB, file-rss:0kB, shmem-rss:0kB, UID:1000 pgtables:726kB oom_score_adj:0

Feb 26 13:01:16 Tonysallsky kernel: [67834.819986] oom_reaper: reaped process 7116 (ffmpeg), now anon-rss:16kB, file-rss:0kB, shmem-rss:0kB

I deliberately take images in 2X2 binning mode to avoid this problem, so I don't know if the new code is more memory intensive. I am using a 1GB RPi model 3. The old code reduced the size of the images to 1920 X 1078 into the 'small' directory' before ffmeg. They are currently 2028 X 1520 from the RPi HQ camera.

Secondly - I tried adding #!/usr/bin/env python3, and chmod 775. Directory entry looks like this now:

@.***:~/allsky $* ls -l onewirethermread.py

-rwxrwxr-x 1 pi pi 1304 Feb 26 13:18 onewirethermread.py

But I still need python to run it:

@.***:~/allsky $* python3 onewirethermread.py

16.5

Without the python3 call, I get this:

@.***:~/allsky $* ./onewirethermread.py

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

id: extra operand ‘28-0000016c61b5’

Try 'id --help' for more information.

./onewirethermread.py: line 7: syntax error near unexpected token `GPIO.BCM'

./onewirethermread.py: line 7: `GPIO.setmode(GPIO.BCM) # Set GPIO Broadcom names' It looks like it can't do i/o - a properties problem again?

Thanks for your help.

Tony

On Sat, 26 Feb 2022 at 04:44, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf Thanks for the update. '/home/pi/allsky/onewirethermread.py` needs to be executable by the "www-data" group. I'm guessing the group permissions don't include "x". I updated the Wiki to mention this.

Try adding #!/usr/bin/env python3 as the FIRST line in onewirethermread.py, then do a chmod 775 onewirethermread.py and see if that fixes the problem, and allows you to run the command in ssh by simply typing ./onewirethermread.py.

WEBUI_DATA_FILES should only contain the full path to dewheater_status.txt since the web page is looking for a file with that name.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1051571563, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTXTIVB6ELO5DQRE5DTU5BLBLANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

tony1tf commented 2 years ago

Hi again Eric

I cracked the second problem - just found I had used '1' instead of '!' - now it runs OK from the status page. So now I can press on with trying some of the other scripts.

Tony

On Sat, 26 Feb 2022 at 13:50, Tony Abbey @.***> wrote:

Hi Eric

Two problems now:

Had a problem overnight - no timelapse was generated - the file in tmp doesn't show the problem except for this message at the end:

ln -s /home/pi/allsky/images/20220225/image-20220226060718.jpg /home/pi/allsky/tmp/sequence-20220225/1316.jpg [swscaler @ 0x139ded0] deprecated pixel format used, make sure you did set range correctly

The syslog file shows it was an out of memory error when I ran the timelapse script again:

Feb 26 13:01:16 Tonysallsky kernel: [67834.659095] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=ffmpeg,pid=7116,uid=1000

Feb 26 13:01:16 Tonysallsky kernel: [67834.659188] Out of memory: Killed process 7116 (ffmpeg) total-vm:990972kB, anon-rss:476764kB, file-rss:0kB, shmem-rss:0kB, UID:1000 pgtables:726kB oom_score_adj:0

Feb 26 13:01:16 Tonysallsky kernel: [67834.819986] oom_reaper: reaped process 7116 (ffmpeg), now anon-rss:16kB, file-rss:0kB, shmem-rss:0kB

I deliberately take images in 2X2 binning mode to avoid this problem, so I don't know if the new code is more memory intensive. I am using a 1GB RPi model 3. The old code reduced the size of the images to 1920 X 1078 into the 'small' directory' before ffmeg. They are currently 2028 X 1520 from the RPi HQ camera.

Secondly - I tried adding #!/usr/bin/env python3, and chmod 775. Directory entry looks like this now:

@.***:~/allsky $* ls -l onewirethermread.py

-rwxrwxr-x 1 pi pi 1304 Feb 26 13:18 onewirethermread.py

But I still need python to run it:

@.***:~/allsky $* python3 onewirethermread.py

16.5

Without the python3 call, I get this:

@.***:~/allsky $* ./onewirethermread.py

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

import-im6.q16: unable to open X server `' @ error/import.c/ImportImageCommand/360.

id: extra operand ‘28-0000016c61b5’

Try 'id --help' for more information.

./onewirethermread.py: line 7: syntax error near unexpected token `GPIO.BCM'

./onewirethermread.py: line 7: `GPIO.setmode(GPIO.BCM) # Set GPIO Broadcom names' It looks like it can't do i/o - a properties problem again?

Thanks for your help.

Tony

On Sat, 26 Feb 2022 at 04:44, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf Thanks for the update. '/home/pi/allsky/onewirethermread.py` needs to be executable by the "www-data" group. I'm guessing the group permissions don't include "x". I updated the Wiki to mention this.

Try adding #!/usr/bin/env python3 as the FIRST line in onewirethermread.py, then do a chmod 775 onewirethermread.py and see if that fixes the problem, and allows you to run the command in ssh by simply typing ./onewirethermread.py.

WEBUI_DATA_FILES should only contain the full path to dewheater_status.txt since the web page is looking for a file with that name.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1051571563, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTXTIVB6ELO5DQRE5DTU5BLBLANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

EricClaeys commented 2 years ago

@tony1tf per the Wiki page on troubleshooting timelapse issues, you can ignore the "deprecated pixel format" message. Does /var/log/allsky.log have anything on timelapse?

Did timelapse work before you upgraded to 0.8.3? The ffmpeg command isn't part of Allsky so likely didn't change.

tony1tf commented 2 years ago

Hi Eric

Does this need to be moved to a different bug report? I have already said that timelapse was working OK before. There was an extra stage which slightly reduced the image size in the old software.

I copied the relevant part of the latest allsky log and it basically says ffmeg process killed.

Feb 27 06:14:28 Tonysallsky allsky.sh[12313]: endOfNight.sh: ===== Generating Timelapse

Feb 27 06:14:38 Tonysallsky allsky.sh[12313]: STARTING EXPOSURE at: 2022-02-27 06:14:38 @ 32.00 ms (0.03 sec)

Feb 27 06:14:54 Tonysallsky allsky.sh[12313]: Sleeping 15.0 seconds...

Feb 27 06:15:09 Tonysallsky allsky.sh[12313]: STARTING EXPOSURE at: 2022-02-27 06:15:09 @ 32.00 ms (0.03 sec)

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: /home/pi/allsky/scripts/timelapse.sh: line 121: 1646 Killed ffmpeg -y -f image2 -loglevel ${FFLO

G} -r ${FPS} -i "${SEQUENCE_DIR}/%04d.${EXTENSION}" -vcodec ${VCODEC} -b:v ${TIMELAPSE_BITRATE} -pix_fmt ${PIX_FMT} -movflags +faststart $SCALE ${TIMELAPSE_EXTR

A_PARAMETERS} ${TIMELAPSE_PARAMETERS} "${OUTPUT_FILE}" >> "${TMP}" 2>&1

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: *** timelapse.sh: ERROR: ffmpeg failed.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: Error log is in '/home/pi/allsky/tmp/timelapseTMP.txt'.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: Links in '/home/pi/allsky/tmp/sequence-20220226' left for debugging.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: Remove them when the problem is fixed.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: generateForDay.sh: Command Failed: '/home/pi/allsky/scripts/timelapse.sh' 20220226

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: endOfNight.sh: ===== Timelapse complete The stack trace in syslog listed the memory usage and it shows high memory usage by ffmeg before it died:

Feb 28 06:13:18 Tonysallsky kernel: [216159.684378] [ 10196] 1000 10196 237923 107485 675840 0 0 ffmpeg

Feb 28 06:13:18 Tonysallsky kernel: [216159.684388] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=ffm

peg,pid=10196,uid=1000

Feb 28 06:13:18 Tonysallsky kernel: [216159.684487] Out of memory: Killed process 10196 (ffmpeg) total-vm:951692kB, anon-rss:429940kB, file-rss:0kB, shmem-rss:0

kB, UID:1000 pgtables:660kB oom_score_adj:0

There is also a lot of memory being used by the daytime imaging task, so perhaps if I turn that off, then there might be more memory for ffmeg to run in.

ANother problem - I just stopped and then tried to restart AllSky from your new status page to pick up changes to config. Stop is OK, but start gave this error:

'sudo /bin/systemctl start allsky' failed

Rebooted the Pi, and it now picks up the edited config.sh script, which stops the daytime capture. I now got timelapse.sh to run - it took around 20 mins and used 94% memory according to the status page. 'top' shows up to 367% CPU and 91% memory.

Tony

On Sun, 27 Feb 2022 at 02:56, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf per the Wiki page on troubleshooting timelapse issues, you can ignore the "deprecated pixel format" message. Does /var/log/allsky.log have anything on timelapse?

Did timelapse work before you upgraded to 0.8.3? The ffmpeg command isn't part of Allsky so likely didn't change.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1053004482, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTXW3J5V37QUREOTXIDU5GHGLANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

EricClaeys commented 2 years ago

@tony1tf Let's move the timelapse problem to a different Issue. This Issue is to allow users to add information to the "System" page, which is working but needs more user testing. I'll then close it.

I couldn't find where you said timelapse was working before you upgrade to 0.8.3. Possibly in a different thread? Regardless, per the Wiki page, the "Killed" message is, as far as I know, always due to not enough swap space. Try increasing to 4 GB; if that doesn't help, please create a new Issue.

tony1tf commented 2 years ago

R Pi crashed when running timelapse for the next night. Had to recycle the power. OK on second run. Thanks for your message on swap space - I'll look into that.

Tony

On Mon, 28 Feb 2022 at 10:34, Tony Abbey @.***> wrote:

Hi Eric

Does this need to be moved to a different bug report? I have already said that timelapse was working OK before. There was an extra stage which slightly reduced the image size in the old software.

I copied the relevant part of the latest allsky log and it basically says ffmeg process killed.

Feb 27 06:14:28 Tonysallsky allsky.sh[12313]: endOfNight.sh: ===== Generating Timelapse

Feb 27 06:14:38 Tonysallsky allsky.sh[12313]: STARTING EXPOSURE at: 2022-02-27 06:14:38 @ 32.00 ms (0.03 sec)

Feb 27 06:14:54 Tonysallsky allsky.sh[12313]: Sleeping 15.0 seconds...

Feb 27 06:15:09 Tonysallsky allsky.sh[12313]: STARTING EXPOSURE at: 2022-02-27 06:15:09 @ 32.00 ms (0.03 sec)

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: /home/pi/allsky/scripts/timelapse.sh: line 121: 1646 Killed ffmpeg -y -f image2 -loglevel ${FFLO

G} -r ${FPS} -i "${SEQUENCE_DIR}/%04d.${EXTENSION}" -vcodec ${VCODEC} -b:v ${TIMELAPSE_BITRATE} -pix_fmt ${PIX_FMT} -movflags +faststart $SCALE ${TIMELAPSE_EXTR

A_PARAMETERS} ${TIMELAPSE_PARAMETERS} "${OUTPUT_FILE}" >> "${TMP}" 2>&1

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: *** timelapse.sh: ERROR: ffmpeg failed.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: Error log is in '/home/pi/allsky/tmp/timelapseTMP.txt'.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: Links in '/home/pi/allsky/tmp/sequence-20220226' left for debugging.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: Remove them when the problem is fixed.

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: generateForDay.sh: Command Failed: '/home/pi/allsky/scripts/timelapse.sh' 20220226

Feb 27 06:15:16 Tonysallsky allsky.sh[12313]: endOfNight.sh: ===== Timelapse complete The stack trace in syslog listed the memory usage and it shows high memory usage by ffmeg before it died:

Feb 28 06:13:18 Tonysallsky kernel: [216159.684378] [ 10196] 1000 10196 237923 107485 675840 0 0 ffmpeg

Feb 28 06:13:18 Tonysallsky kernel: [216159.684388] oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/,task=ffm

peg,pid=10196,uid=1000

Feb 28 06:13:18 Tonysallsky kernel: [216159.684487] Out of memory: Killed process 10196 (ffmpeg) total-vm:951692kB, anon-rss:429940kB, file-rss:0kB, shmem-rss:0

kB, UID:1000 pgtables:660kB oom_score_adj:0

There is also a lot of memory being used by the daytime imaging task, so perhaps if I turn that off, then there might be more memory for ffmeg to run in.

ANother problem - I just stopped and then tried to restart AllSky from your new status page to pick up changes to config. Stop is OK, but start gave this error:

'sudo /bin/systemctl start allsky' failed

Rebooted the Pi, and it now picks up the edited config.sh script, which stops the daytime capture. I now got timelapse.sh to run - it took around 20 mins and used 94% memory according to the status page. 'top' shows up to 367% CPU and 91% memory.

Tony

On Sun, 27 Feb 2022 at 02:56, EricClaeys @.***> wrote:

@tony1tf https://github.com/tony1tf per the Wiki page on troubleshooting timelapse issues, you can ignore the "deprecated pixel format" message. Does /var/log/allsky.log have anything on timelapse?

Did timelapse work before you upgraded to 0.8.3? The ffmpeg command isn't part of Allsky so likely didn't change.

— Reply to this email directly, view it on GitHub https://github.com/thomasjacquin/allsky-portal/issues/89#issuecomment-1053004482, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABJKGTXW3J5V37QUREOTXIDU5GHGLANCNFSM5N35CGYQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you were mentioned.Message ID: @.***>

EricClaeys commented 2 years ago

Closing - the ability to add any data you'd like was just added. See this Wiki page for details on how to use it.