Search squid archive

Re: FATAL: assertion failed: mem/PageStack.cc:159: "StoredNode().is_lock_free()"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2024-06-27 10:35, Nishant Sharma wrote:

I am running squid 6.10 on Openwrt 23.05.2, which is cross compiled for ramips / mipsel_24kc which has a 32 bit CPU (MT7621A) with 2 cores and 2 threads.

Squid fails to start in SMP mode when I set workers > 1.

The assertion in question may be overreaching -- I suspect the relevant code works correctly when std::atomic<uint64_t>::is_lock_free() is false. Depending on how those locks are implemented in your environment, and how your traffic tickles them, SMP Squid without atomic locks might become very slow! We do not (and, IMO, should not) optimize performance for environments without lock-free atomics!

I see the following options for going forward:

* Comment out the assertion, void your warranty, and hope for the best.
* Audit relevant code to confirm that the assertion is safe to remove.
* Find a usable OS/environment that has lock-free 64-bit atomics.


SMP worked fine with squid 4.13 on same architecture.

SMP Squid v4 has an ABA problem that could, at least in theory, result in silent cache corruption. If you are interested in low-level details, please see commit 7a5af8db message:
https://github.com/squid-cache/squid/commit/7a5af8db


HTH,

Alex.


I have filed a bug report with Openwrt at

https://github.com/openwrt/packages/issues/24469

where someone suggested, "ramips has one CPU and the assert is that system pointers are not 64bit."

Below are the logs for debug_options 54,9:

2024/06/27 19:48:45.888| 54,3| mem/Segment.cc(245) unlink: unlinked /squid-cf__metadata.shm segment 2024/06/27 19:48:45.888| 54,3| mem/Segment.cc(128) create: created /squid-cf__metadata.shm segment: 8 2024/06/27 19:48:45.888| 54,5| mem/Segment.cc(211) lock: mlock(2)-ing disabled 2024/06/27 19:48:45.889| 54,3| mem/Segment.cc(245) unlink: unlinked /squid-cf__queues.shm segment 2024/06/27 19:48:45.889| 54,3| mem/Segment.cc(128) create: created /squid-cf__queues.shm segment: 32852 2024/06/27 19:48:45.889| 54,5| mem/Segment.cc(211) lock: mlock(2)-ing disabled 2024/06/27 19:48:45.890| 54,3| mem/Segment.cc(245) unlink: unlinked /squid-cf__readers.shm segment 2024/06/27 19:48:45.890| 54,3| mem/Segment.cc(128) create: created /squid-cf__readers.shm segment: 40 2024/06/27 19:48:45.890| 54,5| mem/Segment.cc(211) lock: mlock(2)-ing disabled
2024/06/27 19:48:45.891| 54,7| Queue.cc(50) QueueReader: constructed ipcQR1
2024/06/27 19:48:45.891| 54,7| Queue.cc(50) QueueReader: constructed ipcQR2
2024/06/27 19:48:45.891| 54,5| mem/PageStack.cc(129) IdSetMeasurements: rounded capacity up from 8192 to 8192 2024/06/27 19:48:45.891| 54,3| mem/Segment.cc(245) unlink: unlinked /squid-squid-page-pool.shm segment 2024/06/27 19:48:45.892| 54,3| mem/Segment.cc(128) create: created /squid-squid-page-pool.shm segment: 268437592 2024/06/27 19:48:45.892| 54,5| mem/Segment.cc(211) lock: mlock(2)-ing disabled 2024/06/27 19:48:45.892| 54,5| mem/PageStack.cc(129) IdSetMeasurements: rounded capacity up from 8192 to 8192 2024/06/27 19:48:45| FATAL: assertion failed: mem/PageStack.cc:159: "StoredNode().is_lock_free()"


Any pointers would be really helpful.

Thanks in advance.

Regards,
Nishant
_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
https://lists.squid-cache.org/listinfo/squid-users

_______________________________________________
squid-users mailing list
squid-users@xxxxxxxxxxxxxxxxxxxxx
https://lists.squid-cache.org/listinfo/squid-users



[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux