Comments (11)
@philn thank you. Also, if not disabled, then redirected to a tmpfs directory
from cog.
Some of the features which cause writes to disk can be disabled using some of the command line options listed with --help-websettings
, for example:
cog --enable-offline-web-application-cache=false \
--enable-page-cache=false \
...
That being said, writable disk access for temporary files may still be needed. You can use the XDG_CACHE_HOME
, XDG_DATA_HOME
, XDG_RUNTIME_DIR
, and so on as defined in the XDG Base Directory Specification, which Cog honors.
Please let us know if doing any of the above (or a combination of both) solves the issue for you.
from cog.
@aperezdc Thank you for the information. I will try the XDG variables.
Please note that my version of Cog doesn't have the --help-websettings
$cog --version
0.1.0
$cog --help-websettings
Unknown option --help-websettings
from cog.
@gil0109 You're welcome! The XDG variables should be enough to make Cog write temporary files and caches in whichever path you may prefer. For the --help-websettings
you will need a version of Cog newer than commit 1c63839 so I suppose your build is from some older commit — you may need to update your build recipes to pick a more recent revision from the Cog repository.
from cog.
I upgrade to the latest cog (thank you).
I am viewing a 600mb mp4 file.
I am getting the following memory error. Is there something I can do to fix this? If I run the same thing using chromium and raspbian stretch using overlayfs, I don't have this issue. So I am hoping, there's something we can do with cog and webkit.
root@raspberrypi3:~# /usr/sbin/start_cog.sh
Starting Digital Signage
[LibinputServer] Initialization of linux input system succeeded.
Cannot create EGL surfaceless context: missing EGL_KHR_surfaceless_{context,opengl} extension.
Cannot create EGL WPE context: EGL_SUCCESS
Cog-Message: https://sbc-qsystem-prod.pathfinder.gov.bc.ca/sbc.mp4 Load started.
Cog-Message: https://sbc-qsystem-prod.pathfinder.gov.bc.ca/sbc.mp4 Loading...
Cog-Message: https://sbc-qsystem-prod.pathfinder.gov.bc.ca/sbc.mp4 Loaded successfully.
Memory pressure relief: Total: res = 25817088/24981504/-835584, res+swap = 23851008/23187456/-663552
from cog.
One more thing, running the video using streamer does not seem tohave this issue:
gst-play-1.0 https://sbc-qsystem-dev.pathfinder.gov.bc.ca/sbc.mp4
Now playing https://sbc-qsystem-dev.pathfinder.gov.bc.ca/sbc.mp4
Prerolling...
Buffering... 100%
0:01:01.9 / 0:22:36.5
from cog.
Chromium doesn't display errors but likely also uses a lot of memory :) The memory pressure message you see is not critical but it would be good to do further investigation anyway.
May I suggest you to subscribe to the WPE mailing list? See https://lists.webkit.org/mailman/listinfo/webkit-wpe
This specific issue you observe is not related with this Cog issue we're discussing in.
from cog.
As mentioned by @philn, the memory pressure handler message is normal, and means that WebKit is trying to return some unused memory back to the system — that's good!
@gil0109 I understand that you have been able to use Cog on your system with read-only rootfs, using the XDG_*
variables. Can you confirm whether that approach worked for you? Thanks!
from cog.
@aperezdc Absolutely will let you know. Turning on read-only broke a few other items like DHCP so I am working on getting that fixed before I can test and report.
As for the message, as soon as that happens, the video either hangs or the image is flattened to a cm thick. I was hoping to post it on Igalia_WebKit but I will take @philn advice and try to figure out how to use the mailing list to post the issue there. Learning a lot of new things.
from cog.
Great news... COG is running successfully with the variables set on a read-only-rootfs.
Thank you for your help!!
export XDG_CACHE_HOME=/tmp
export XDG_DATA_HOME=/tmp
export XDG_CONFIG_HOME=/tmp
export XDG_RUNTIME_DIR=/tmp
export XDG_DATA_DIRS=/tmp
export XDG_RUNTIME_DIR=/tmp
exec /usr/bin/cog ${URL}
from cog.
@gil0109 Thanks for confirming that you got it working 👍
I think we can now close this issue.
from cog.
Related Issues (20)
- Error [destroyed object]: error 7: failed to import supplied dmabufs HOT 3
- issue in starting cog 0.18.0 wpewebkit 2.40.3 HOT 1
- TLS support requirements HOT 1
- Help with cog in DRM mode on Orange Pi5+ HOT 3
- Cog + DRM Lease HOT 1
- REGRESSION(47dee03): Broke DRM plugin on RPi4 HOT 5
- Support ignoring files in the style checker
- x11: cog on VirtualBox Ubuntu 20.04 seg fault core dumped HOT 1
- VPU not used with cog HOT 12
- Disentangle CogShell from CogPlatform
- When drawing a pixel, also the pixel above is impacted HOT 2
- Difference handling needed on Visibility vs Focus for the Views
- Meson configure error when Cog is build only for wayland
- Missing cog-export.h header in the cogcore_headers
- gtk4: Pointer coordinates wrongly reported when the window is on a monitor with fractional scaling HOT 1
- [Clean-up] Remove redundant platform safe-guards in core
- Remove cog_platform_init_web_view() from the API
- MouseEvent buttons property not set in wayland backend
- Crash calling wl_pointer_set_cursor() in cog-utils.c HOT 2
- /snap/wpe-webkit-mir-kiosk/101/usr/bin/cog memory increases until it crashes.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cog.