Homelab, Linux, JS & ABAP (~˘▾˘)~
 

[Firefox] Freezes computer

For the past few weeks, my computer was randomly freezing for about 30 seconds. After a quick search, it became clear that it was a memory issue, even though my computer has over 32 GB of RAM…

> journalctl -k -b -o short-precise

Sep 23 09:39:38.873173 myPC systemd-journald: Under memory pressure, flushing caches.
Sep 23 09:39:41.632171 myPC systemd-journald: Under memory pressure, flushing caches.
Sep 23 09:39:44.072486 myPC systemd-journald: Under memory pressure, flushing caches.
Sep 23 09:39:50.630124 myPC systemd-journald: Under memory pressure, flushing caches.
Sep 23 09:40:18.142581 myPC kernel: upowerd invoked oom-killer: gfp_mask=0x140cca(GFP_HIGHUSER_MOVABLE|__GFP_COMP), order=0, oom_score_adj=0

> journalctl -k -b --since "2026-09-23 09:39:30" --until "2026-09-23 09:41:30" \
  | grep -iE 'oom|killed process|kill process|out of memory|memory cgroup'

Sep 23 09:40:18 myPC kernel: oom-kill:constraint=CONSTRAINT_NONE,nodemask=(null),cpuset=/,mems_allowed=0,global_oom,task_memcg=/user.slice/user-1000.slice/session-c2.scope,task=Isolated Web Co,pid=2666576,uid=1000
Sep 23 09:40:18 myPC kernel: Out of memory: Killed process 2666576 (Isolated Web Co) total-vm:10469216kB, anon-rss:7162184kB, file-rss:196kB, shmem-rss:1752kB, UID:1000 pgtables:54092kB oom_score_adj:200

As it turned out, the problem was caused by Firefox (Killed process Isolated Web Co). Fortunately, the solution was quite simple. I enabled the unloadOnLowMemory setting:

about:config → browser.tabs.unloadOnLowMemory →true

Since then, everything is running normal again. I also tried to identify a specific extension or website, which needed too much memory via

about:processes

about:memory

but it was nothing out of the ordinary. I guess I just had too many Firefox windows and tabs open…

[Firefox] Speichernutzung einzelner Tabs anzeigen

Mittels about:unloads kann man in Firefox eine Übersichtsseite aufrufen, die einem auflistet, welche Tabs wie viel Speicher verbrauchen. Hier können inaktive Tabs mit hohem RAM verbrauch auch entladen werden. Seit Firefox 140 kann man mit einem Rechtsklick auf einen Tab oder eine Tabgruppe und der Funktion Unload Tab dies nun auch manuell für bestimmte Tabs erledigen.

[Home Assistant] HASS VM High CPU Usage on Proxmox

Since my Proxmox Server is also my HTPC in my living room, I noticed that suddenly the CPU fan became very noisy. When checking all LXCs and VMs, it turned out that the Home Assistant VW was the cause.

When checking the Supervisor logs, I saw that there was a docker container that got terminated. This seemed to match the CPU usage pattern I checked before.

To inspect the docker container via the Advanced SSH & Web Terminal add-on, you must disable the Protection mode first.

After that, simply run docker stats.

If there are no suspicious values, simply open some of the add-ons in another window and check how the values behave. In the above screenshot, I simply opened the VSCode editor, and you can immediately see an extreme high CPU usage. After a quick search, I found open issues that seem to be related to this issue:

As a workaround, a user had the idea to simply restart VSCode via an automation, when its CPU rises above a threshold. To do this, you have to enable some CPU & Memory sensors of the VSCode add-on. Search for your Home Assistant Supervisor Integration.

Select the Studio Code Server add-on.

And enable the sensors.

Now you can set up a simple automation like the following.

alias: Restart VSCode when cpu/memory too high
description: ""
triggers:
  - trigger: numeric_state
    entity_id:
      - sensor.studio_code_server_cpu_percent
    for:
      hours: 0
      minutes: 5
      seconds: 0
    above: 50
  - trigger: numeric_state
    entity_id:
      - sensor.studio_code_server_memory_percent
    above: 30
    for:
      hours: 0
      minutes: 5
      seconds: 0
conditions: []
actions:
  - action: hassio.addon_restart
    metadata: {}
    data:
      addon: a0d7b954_vscode
mode: single

Since I have the automation setup, the Proxmox CPU fan is quiet again and the VM behaves normal.

[ABAP] Export to memory / Import from memory

Exporting:

DATA: l_p0001  TYPE p0001,
      l_return TYPE bapireturn1.

"...

DATA(l_guid) = cl_system_uuid=>create_uuid_c32_static( ).       
 
EXPORT p0001 = l_p0001 TO MEMORY ID l_guid.
SUBMIT z_hr_report WITH p_guid = l_guid AND RETURN.
IMPORT return = l_return FROM MEMORY ID l_guid.

Importing:

REPORT z_hr_report.

PARAMETERS p_guid TYPE sysuuid_c32.

DATA: l_p0001  TYPE p0001,
      l_return TYPE bapireturn1.

START-OF-SELECTION.

IMPORT p0001 = l_p0001 FROM MEMORY ID p_guid.
CHECK sy-subrc = 0.

"do stuff...
CALL FUNCTION 'BAPI_EMPLOYEE_ENQUEUE'
  EXPORTING
    number = l_p0001-pernr
  IMPORTING
    return = l_return.

IF l_return-type = 'E'.
  EXPORT return = l_return TO MEMORY ID p_guid.
  RETURN.
ENDIF.