>
> Quick question how does the apr use the shm segments and why does it have
> a slotmem error if we use mod_proxy with several balancer name calls and
> multiple hosts apache servers on a single dev box? I am really trying to
> understand how this code segment below works?
>
> shm.c file call?
>
> #if APR_USE_SHMEM_SHMGET 71 static key_t our_ftok(const char *filename)
> 72 { 73 /* to help avoid collisions while still using 74 * an
> easily recreated proj_id */ 75 apr_ssize_t slen = strlen(filename);
> 76 return ftok(filename, 77
> (int)apr_hashfunc_default(filename, &slen)); 78 } 79 #endif
>
>
>
>
> APR_PERMS_SET_IMPLEMENT(shm)
> 696 {
> 697 #if APR_USE_SHMEM_SHMGET || APR_USE_SHMEM_SHMGET_ANON
> 698 struct shmid_ds shmbuf;
> 699 int shmid;
> 700 apr_shm_t *m = (apr_shm_t *)theshm;
> 701
> 702 if ((shmid = shmget(m->shmkey, 0, SHM_R | SHM_W)) == -1) {
> 703 return errno;
> 704 }
> 705 shmbuf.shm_perm.uid = uid;
> 706 shmbuf.shm_perm.gid = gid;
> 707 shmbuf.shm_perm.mode = apr_unix_perms2mode(perms);
> 708 if (shmctl(shmid, IPC_SET, &shmbuf) == -1) {
> 709 return errno;
> 710 }
> 711 return APR_SUCCESS;
> 712 #else
> 713 return APR_ENOTIMPL;
> 714 #endif
> 715 }
> 716
> shmbuf.shm_perm.uid = uid;
> 706 shmbuf.shm_perm.gid = gid;
> 707 shmbuf.shm_perm.mode = apr_unix_perms2mode(perms);
>