Page 1 of 1

Quotas not saving correctly/Getting cut off

Posted: Thu Apr 02, 2026 10:29 am
by pkkrusty
Hi all,

I have about 200 quotas and usually when I edit one and save, it takes probably 10 seconds and then the page reloads and everything is good. This morning, I tried to adjust a quota and save, the wheel spun for a second or two, then the page reloaded, but only the first 30ish quotas showed up. It's like the rest got cut off mid-save and got lost. I have a backup, so I restored and tried again. Same problem. Sometimes it reloads after one second, sometimes after 3 seconds, each time a larger or smaller portion of the quotas are cut off.

With my old router, I used to get this from time to time (maybe associated with load?)

Now gargoyle is virtualized on a intel processor and runs much faster, so load isn't an issue anymore. However, something seems to be interrupting the quota save script.

Is there a way to watch what's happening to give more detail? Fortunately I can watch the console on Proxmox and mess with settings at the same time.

Re: Quotas not saving correctly/Getting cut off

Posted: Thu Apr 02, 2026 11:03 am
by pkkrusty
Looking at top while I save quotas, this process jumps to the top:

/usr/sbin/uhttpd -f -h /www -r Gargoyle -x /cgi-bin -t 900 -T 30 -k 20 -A 1 -E /login.sh -n 50 -N 200 -D -R -p 0.0.0.0:80 -p [::]:80 -i .sh=/usr/bin/run_haserl -i .csv=/usr/bin/run_haserl -I login.sh -C /etc/uhttpd.crt -K /etc/uhttpd.key -s 0.0.0.0:443 -s [::]:443

I get the following errors in logread:

daemon.err uhttpd[3917]: sh: write error: Broken pipe
daemon.err uhhtpd[3917]: uci: Invalid argument

Re: Quotas not saving correctly/Getting cut off

Posted: Thu Apr 02, 2026 11:06 am
by pkkrusty
Now i just tried again and it saved correctly.

I'll try to trigger it again and see what logread says.

On a successful write, I see this:

Thu Apr 2 15:04:23 2026 daemon.err uhttpd[3917]: Error: syntax error, unexpected string
Thu Apr 2 15:04:23 2026 daemon.err uhttpd[3917]: add rule inet fw4 mangle_combined_quotas ct mark & 0xF0000000 == 0x0 bandwidth id "ALL_OTHERS_INDIVIDUAL_combined" type individual_local subnet "192.168.2.1/23" subnet6 "fd25:c50b:d1ea::1/60" greater-than 1048576 reset-interval day ct mark set ct mark & 0xFFFF7FFF | 0x8000
Thu Apr 2 15:04:23 2026 daemon.err uhttpd[3917]:

Re: Quotas not saving correctly/Getting cut off

Posted: Thu Apr 02, 2026 11:11 am
by pkkrusty
Device info:

Device Name:Gargoyle
Gargoyle Version:1.15.0.4 (Built 20260202-2036 git@d4e2d92b)
eko.one.pl
Model:QEMU Standard PC (i440FX + PIIX, 1996)
Device Configuration:Gateway
Memory Usage:74.5MB / 227.8MB (32.7%)
Connections:391/4096
CPU Load Averages:0.30 / 0.24 / 0.10 (1/5/15 minutes)

Re: Quotas not saving correctly/Getting cut off

Posted: Thu Apr 02, 2026 7:14 pm
by Lantis
I think there might be a couple of things going on, one of which is load and “time to save”, if that process gets interrupted or fails we are going to land somewhere in the middle of nothing and everything. I agree with you that on a modern (virtualised) CPU you should not be running into limits.

The other issue with your unexpected string though definitely warrants exploring.

Are you able to share your firewall config with me (by PM if you don’t want it public) and I’ll take a look?
Also I see you’re running a large subnet, anything else I need to know to help me reproduce it?