Re: [squid-users] Squid 3.3.2 SMP Problem
On Mar 9, 2013, at 12:48 PM, Adam W. Dace wrote: > Sorry for wasting everyone's time a bit...but I did want to try to > focus in on what is really a problem I can't figure out > and what isn't before filing a bug in Bugzilla. > > Thank you! I nailed it...at least in terms of Unix Domain Sockets. > Squid is up and running with 3 workers and not sharing memory. > > At this point I'll ask if anyone has a FreeBSD box handy? > If so, could you please run "sysctl -A" and let me know what the > following are set to. > Currently I'm using the settings from the squid Wiki and have little > idea what to set them to on Mac OS X. > > net.local.dgram.recvspace: 262144 > net.local.dgram.maxdgram: 16384 > > I'm going to give what I have a little time to "settle in" and then > get back to someone else who wanted a working SMP configuration also. > > Regards, > My FreeBSD 8.x and 9.x boxes show these default values: net.local.dgram.recvspace: 4096 net.local.dgram.maxdgram: 2048 They appear to be the same defaults as on Mac OS X 10.8.2. I did not realize the defaults were so small - yikes! Guy
[squid-users] Squid 3.3.2 SMP Problem
I've updated Bug #3805 a lot, does anybody mind if I move this to the "New Feature Request" component? -- Adam W. Dace Phone: (815) 355-5848 Instant Messenger: AIM & Yahoo! IM - colonelforbin74 | ICQ - #39374451 Microsoft Messenger - colonelforbi...@live.com Google Profile: http://www.google.com/profiles/ColonelForbin74
Re: [squid-users] Squid 3.3.2 SMP Problem
Oh, sure. No problem. That particular issue was solved with this, right from the wiki: sudo sysctl -w net.local.dgram.recvspace=262144 sudo sysctl -w net.local.dgram.maxdgram=16384 Now I'm on to the shared memory problem. There's a couple more sysctl tweaks that I want to try before filing a Bugzilla. On Sun, Mar 10, 2013 at 1:20 AM, Amos Jeffries wrote: > On 2013-03-10 07:48, Adam W. Dace wrote: >> >> Sorry for wasting everyone's time a bit...but I did want to try to >> focus in on what is really a problem I can't figure out >> and what isn't before filing a bug in Bugzilla. >> >> Thank you! I nailed it...at least in terms of Unix Domain Sockets. >> Squid is up and running with 3 workers and not sharing memory. > > > What was the problem? we are currently having UDS socket issues on our MacOS > test machine without a clue how to resolve. > > > >> >> At this point I'll ask if anyone has a FreeBSD box handy? >> If so, could you please run "sysctl -A" and let me know what the >> following are set to. >> Currently I'm using the settings from the squid Wiki and have little >> idea what to set them to on Mac OS X. >> >> net.local.dgram.recvspace: 262144 >> net.local.dgram.maxdgram: 16384 >> >> I'm going to give what I have a little time to "settle in" and then >> get back to someone else who wanted a working SMP configuration also. >> >> Regards, > > > Amos -- Adam W. Dace Phone: (815) 355-5848 Instant Messenger: AIM & Yahoo! IM - colonelforbin74 | ICQ - #39374451 Microsoft Messenger - colonelforbi...@live.com Google Profile: http://www.google.com/profiles/ColonelForbin74
Re: [squid-users] Squid 3.3.2 SMP Problem
On 2013-03-10 07:48, Adam W. Dace wrote: Sorry for wasting everyone's time a bit...but I did want to try to focus in on what is really a problem I can't figure out and what isn't before filing a bug in Bugzilla. Thank you! I nailed it...at least in terms of Unix Domain Sockets. Squid is up and running with 3 workers and not sharing memory. What was the problem? we are currently having UDS socket issues on our MacOS test machine without a clue how to resolve. At this point I'll ask if anyone has a FreeBSD box handy? If so, could you please run "sysctl -A" and let me know what the following are set to. Currently I'm using the settings from the squid Wiki and have little idea what to set them to on Mac OS X. net.local.dgram.recvspace: 262144 net.local.dgram.maxdgram: 16384 I'm going to give what I have a little time to "settle in" and then get back to someone else who wanted a working SMP configuration also. Regards, Amos
Re: [squid-users] Squid 3.3.2 SMP Problem
Sorry for wasting everyone's time a bit...but I did want to try to focus in on what is really a problem I can't figure out and what isn't before filing a bug in Bugzilla. Thank you! I nailed it...at least in terms of Unix Domain Sockets. Squid is up and running with 3 workers and not sharing memory. At this point I'll ask if anyone has a FreeBSD box handy? If so, could you please run "sysctl -A" and let me know what the following are set to. Currently I'm using the settings from the squid Wiki and have little idea what to set them to on Mac OS X. net.local.dgram.recvspace: 262144 net.local.dgram.maxdgram: 16384 I'm going to give what I have a little time to "settle in" and then get back to someone else who wanted a working SMP configuration also. Regards, On Sat, Mar 9, 2013 at 12:07 PM, Alex Rousskov wrote: > On 03/09/2013 09:16 AM, Adam W. Dace wrote: >> This is Mac OS X v10.8.2. >> >> Yeah, I'm having all sorts of problems with shared memory. > > and with inter-process communication (IPC) via Unix Domain Sockets (UDS): > >> With "memory_cache_shared off", I get a different error where the >> child processes are unable to register with the coordinator process. > > > >> Maybe there's some bizarre Mac-specific command I have to issue to >> enable shared memory support? > > It is likely that you have that support enabled but Squid needs to do > something special and/or you need to tune settings such as UDS message > sizes and permissions for everything to work smoothly. Every platform > has its own shared memory and IPC oddities, unfortunately. Some known > ones are documented at > http://wiki.squid-cache.org/Features/SmpScale#Troubleshooting > > >> Any help would be appreciated. > > You need to figure out what system call is failing first and go from > there. I recommend disabling shared memory and making sure IPC is > working first -- you will need IPC anyway. > > Some of the things you can try are: > > * Running Squid with debug_options ALL,9 and figuring out why kid > registration does not work. Often, the OS limit for UDS messages is too > low. There should be some error messages in ALL,9 cache.log about that, > but they are difficult to find and interpret. > > * Running strace/ktrace (or Mac equivalent) and analyzing error codes of > the failing system call (by matching ALL,9 cache.log with the trace). > > None of the above is easy or straightforward, unfortunately. And fewer > folks are going to volunteer their help since you are running on a > non-free OS (I am not saying this in a negative way -- just stating the > facts). You may want to file a bug report to post your logs, ask for > help, and keep a better record of your progress. > > > Good luck, > > Alex. > -- Adam W. Dace Phone: (815) 355-5848 Instant Messenger: AIM & Yahoo! IM - colonelforbin74 | ICQ - #39374451 Microsoft Messenger - colonelforbi...@live.com Google Profile: http://www.google.com/profiles/ColonelForbin74
Re: [squid-users] Squid 3.3.2 SMP Problem
On 03/09/2013 09:16 AM, Adam W. Dace wrote: > This is Mac OS X v10.8.2. > > Yeah, I'm having all sorts of problems with shared memory. and with inter-process communication (IPC) via Unix Domain Sockets (UDS): > With "memory_cache_shared off", I get a different error where the > child processes are unable to register with the coordinator process. > Maybe there's some bizarre Mac-specific command I have to issue to > enable shared memory support? It is likely that you have that support enabled but Squid needs to do something special and/or you need to tune settings such as UDS message sizes and permissions for everything to work smoothly. Every platform has its own shared memory and IPC oddities, unfortunately. Some known ones are documented at http://wiki.squid-cache.org/Features/SmpScale#Troubleshooting > Any help would be appreciated. You need to figure out what system call is failing first and go from there. I recommend disabling shared memory and making sure IPC is working first -- you will need IPC anyway. Some of the things you can try are: * Running Squid with debug_options ALL,9 and figuring out why kid registration does not work. Often, the OS limit for UDS messages is too low. There should be some error messages in ALL,9 cache.log about that, but they are difficult to find and interpret. * Running strace/ktrace (or Mac equivalent) and analyzing error codes of the failing system call (by matching ALL,9 cache.log with the trace). None of the above is easy or straightforward, unfortunately. And fewer folks are going to volunteer their help since you are running on a non-free OS (I am not saying this in a negative way -- just stating the facts). You may want to file a bug report to post your logs, ask for help, and keep a better record of your progress. Good luck, Alex.
Re: [squid-users] Squid 3.3.2 SMP Problem
This is Mac OS X v10.8.2. Yeah, I'm having all sorts of problems with shared memory. I've essentially taken my stock squid config, added some macros for SMP support and given it a shot. Kudos to the squid team for making the configuration piece so easy, when I comment out the SMP directives it works great. With "memory_cache_shared on", I get the error I reported last e-mail. With "memory_cache_shared off", I get a different error where the child processes are unable to register with the coordinator process. I've also tried tweaking my settings for shared memory via sysctl. Nothing seems to help. Maybe there's some bizarre Mac-specific command I have to issue to enable shared memory support? If so, I haven't found it yet. Any help would be appreciated. And yes, I want my squid to cache. This particular install is still just a personal cache to make web browsing faster. On Fri, Mar 8, 2013 at 7:14 PM, Alex Rousskov wrote: > On 03/08/2013 01:14 PM, Adam W. Dace wrote: > >> However, once I add the "workers" directive, I get the following error: >> >> FATAL: Ipc::Mem::Segment::create failed to >> shm_open(/squid-cache_mem.shm): (22) Invalid argument >> >> Squid Cache (Version 3.3.2): Terminated abnormally. >> >> Is this a bug? Or am I doing something wrong? > > There is something wrong or incompatible about shared memory support on > your server. What OS are you using? Do you want your Squid to cache? > > Alex. > -- Adam W. Dace Phone: (815) 355-5848 Instant Messenger: AIM & Yahoo! IM - colonelforbin74 | ICQ - #39374451 Microsoft Messenger - colonelforbi...@live.com Google Profile: http://www.google.com/profiles/ColonelForbin74
Re: [squid-users] Squid 3.3.2 SMP Problem
On 03/08/2013 01:14 PM, Adam W. Dace wrote: > However, once I add the "workers" directive, I get the following error: > > FATAL: Ipc::Mem::Segment::create failed to > shm_open(/squid-cache_mem.shm): (22) Invalid argument > > Squid Cache (Version 3.3.2): Terminated abnormally. > > Is this a bug? Or am I doing something wrong? There is something wrong or incompatible about shared memory support on your server. What OS are you using? Do you want your Squid to cache? Alex.
Re: [squid-users] Squid 3.3.2 SMP Problem
What i have is : http://pastebin.com/dbXNEj5F In production with 700 costumers and is working good so far. Using squid-3.3.2-20130305-r12513 Regards After a bit of reading squid.conf.documented, I went ahead and tried to make a unified SMP squid.conf configuration. However, once I add the "workers" directive, I get the following error: FATAL: Ipc::Mem::Segment::create failed to shm_open(/squid-cache_mem.shm): (22) Invalid argument Squid Cache (Version 3.3.2): Terminated abnormally. Is this a bug? Or am I doing something wrong? Links: -- [1] http://pastebin.com/dbXNEj5F
[squid-users] Squid 3.3.2 SMP Problem
After a bit of reading squid.conf.documented, I went ahead and tried to make a unified SMP squid.conf configuration. However, once I add the "workers" directive, I get the following error: FATAL: Ipc::Mem::Segment::create failed to shm_open(/squid-cache_mem.shm): (22) Invalid argument Squid Cache (Version 3.3.2): Terminated abnormally. Is this a bug? Or am I doing something wrong? -- Adam W. Dace Phone: (815) 355-5848 Instant Messenger: AIM & Yahoo! IM - colonelforbin74 | ICQ - #39374451 Microsoft Messenger - colonelforbi...@live.com Google Profile: http://www.google.com/profiles/ColonelForbin74