squid3 smp problem

k simon chio1990 at gmail.com
Wed Oct 23 00:25:36 PDT 2013


Hi, Matt

  I googled it and found:

<quote>
> how can we adjust the path where squid stores the ipc files for the 
> coordinator and kids? it is /path/to/squid/var/run/squid. this is 
> because we used -prefix="/path/to/squid" . but also we have used 
> -prefix we want to have the files in other dirs. with (nearly) all we 
> can adjust the locations in squid.conf and use the full/other path, 

The OS determines where/what the SHM path descriptor has to be. We like 
to follow the FHS specification since these are special networking 
*socket* descriptors not "files". That may or may not permit your 
--prefix to apply on the path, but we do not allow localization. 
</quote>

   I didn't know much about IPC.  In the past years I run some squid box in SMP mode
with freebsd and linux, and I noticed that squid block the IO in the peak time every day, 
iostat displays IOPS cannot exceed 250/s, even though in some test I can get 1000/s 
when I run "tar xf ports.tgz" without any other load.
   Yesterday I ran squid with aufs store in single process mode on dflyBSD, and observed 
the IOPS can touch 500/s sometimes. It's so amazing, so I want give more test with squid
 in SMP mode.
   By the way, I'm a newbie to dfly. Does exist some tool similar to cpuset/taskset can bind
the process to cpu core to avoid some context switches?

Regards,
Simon


在 2013-10-23,上午9:59, Matthew Dillon 写道:

>    That looks like something *very* linux-specific.  There are tons
>    of ways of doing shared memory that are portable, I don't know why
>    squid isn't using them.  You'd have to investigate squid's configuration
>    file / documentation to determine if it is possible to specify the
>    pool some other way.
> 
> 						-Matt
> 
> :Hi,lists
> :
> :    I compile squid 3.3.9 with dports, it's sucessed. But when I start =
> :it with smp features, it's reported :
> :
> :dragonfly# squid -z
> :2013/10/22 20:54:17| storeDirWriteCleanLogs: Starting...
> :2013/10/22 20:54:17|   Finished.  Wrote 0 entries.
> :2013/10/22 20:54:17|   Took 0.00 seconds (  0.00 entries/sec).
> :FATAL: Ipc::Mem::Segment::create failed to =
> :shm_open(/squid-squid-page-pool.shm): (13) Permission denied
> :
> :then I googled and found
> :Troubleshooting
> :
> :Ipc::Mem::Segment::create failed to =
> :shm_open(/squid-squid-page-pool.shm): (13) Permission denied
> :On Linux the page pool should "just work". However it is still dependent =
> :on the SHM device mapping being initialized.
> :
> :Add the following line to your /etc/fstab file:
> :
> :shm        /dev/shm    tmpfs    nodev,nosuid,noexec    0    0
> :After that use (as root):
> :
> :mount shm
> :
> :   It's for linux, but I can't get a clue for how can resolve this =
> :problem on dfly. Can somebody kinds help me.
> :
> :regards
> :Simon=

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.dragonflybsd.org/pipermail/users/attachments/20131023/2dd90488/attachment-0003.htm>


More information about the Users mailing list