I just installed the 8/99 release of Solaris 7 on three Sun Ultra 10's and it seems to have broken Samba. I am running Samba 2.0.5a and it works fine on an Ultra 10 running the 5/99 release of Solaris 7. All of the Ultra 10's are using the 64 bit kernel. This is the errors that I am getting. [1999/10/22 21:09:56, 0] locking/shmem_sysv.c:sysv_shm_open(597) ERROR: root did not create the semaphore [1999/10/22 21:09:56, 0] locking/locking.c:locking_init(174) ERROR: Failed to initialise share modes I used abd to compare the kernel settings for shminfo and seminfo and they are indentical between the 2 releases. I also verified the samba install. I am running smbd and nmbd as a daemon not through inetd. Thanks in advance. Kevin Van Der Hart LAN Administrator Vermeer Mfg Co kvanderhart@vermeermfg.com
jeremy allison posted a patch to deal with this issue back in july. have a look through the samba archives or see this dejanews article: # You can view this message and the related discussion by following this link: # http://www.deja.com/dnquery.xp?search=thread&svcclass=dnserver&recnum=%3c7nq44j$1h@dfw-ixnews3.ix.netcom.com%3e%231/1 # We hope to see you soon at Deja.com. unfortunately, this patch has not always solved the problem for me. it seems to work on some solaris 7 systems and not others. i have seen this problem with various installation of solaris 7 (mostly 5/99) on both 32- and 64-bit kernels. i have never been able to pin down in which cases it does or does not work. i have even seen the case where samba is running fine after a reboot but then exhibits this locking problem if i manually stop and restart smbd sometime later. in some cases, i have been able to eliminate the problem by reverting to an older build of samba-2.0.5a made on a solaris 2.5 system, without the aforementioned patch. just out of curiosity, could you try some tests? 1) starting smbd and nmbd from an init script and reboot the ultra 10 2) apply the patch, rebuild and restart did either of these help? if (1), then try manually stopping and starting smbd. still ok? -- Todd Pfaff \ Email: pfaff@mcmaster.ca Computing and Information Services \ Voice: (905) 525-9140 x22920 ABB 132 \ FAX: (905) 528-3773 McMaster University \ Hamilton, Ontario, Canada L8S 4M1 \ On Sun, 24 Oct 1999, Kevin Van Der Hart wrote:> I just installed the 8/99 release of Solaris 7 on three Sun Ultra 10's and > it seems to have broken Samba. I am running Samba 2.0.5a and it works fine > on an Ultra 10 running the 5/99 release of Solaris 7. All of the Ultra 10's > are using the 64 bit kernel. This is the errors that I am getting. > > [1999/10/22 21:09:56, 0] locking/shmem_sysv.c:sysv_shm_open(597) > ERROR: root did not create the semaphore > [1999/10/22 21:09:56, 0] locking/locking.c:locking_init(174) > ERROR: Failed to initialise share modes > > I used abd to compare the kernel settings for shminfo and seminfo and they > are indentical between the 2 releases. I also verified the samba install. I > am running smbd and nmbd as a daemon not through inetd. Thanks in advance. > > Kevin Van Der Hart > LAN Administrator > Vermeer Mfg Co > kvanderhart@vermeermfg.com
On Sun, 24 Oct 1999, Kevin Van Der Hart wrote:> I just installed the 8/99 release of Solaris 7 on three Sun Ultra 10's and > it seems to have broken Samba. I am running Samba 2.0.5a and it works fine > on an Ultra 10 running the 5/99 release of Solaris 7. All of the Ultra 10's > are using the 64 bit kernel.I haven't tried the 8/99 Solaris CDs, but the problems you describe sound like something I should be interesed in... Can you email me with truss -f output from starting samba? We can get into increasing detail (sotruss, apptrace) later. --dave (who used to work on the Sun ABI team) c-b -- David Collier-Brown, | Always do right. This will gratify some people 185 Ellerslie Ave., | and astonish the rest. -- Mark Twain Willowdale, Ontario | http://java.science.yorku.ca/~davecb Work: (905) 415-2849 Home: (416) 223-8968 Email: davecb@canada.sun.com
Kevin Van Der Hart wrote:> > I just installed the 8/99 release of Solaris 7 on three Sun Ultra 10's and > it seems to have broken Samba. I am running Samba 2.0.5a and it works fine > on an Ultra 10 running the 5/99 release of Solaris 7. All of the Ultra 10's > are using the 64 bit kernel. This is the errors that I am getting. > > [1999/10/22 21:09:56, 0] locking/shmem_sysv.c:sysv_shm_open(597) > ERROR: root did not create the semaphore > [1999/10/22 21:09:56, 0] locking/locking.c:locking_init(174) > ERROR: Failed to initialise share modesThis is the patch you need. This will be fixed in Samba 2.0.6. Regards, Jeremy Allison, Samba Team. ---- /usr/people/jallison/tmp/samba-2.0.5a/source/locking/shmem_sysv.c Tue Jul 20 18:25:11 1999 +++ locking/shmem_sysv.c Tue Oct 12 17:30:16 1999 @@ -528,6 +528,7 @@ /******************************************************************* open the shared memory ******************************************************************/ + struct shmem_ops *sysv_shm_open(int ronly) { BOOL other_processes; @@ -536,6 +537,8 @@ union semun su; int i; pid_t pid; + struct passwd *root_pwd = sys_getpwuid((uid_t)0); + gid_t root_gid = root_pwd ? root_pwd->pw_gid : (gid_t)0; read_only = ronly; @@ -593,8 +596,9 @@ hash_size = sem_ds.sem_nsems-1; if (!read_only) { - if (sem_ds.sem_perm.cuid != 0 || sem_ds.sem_perm.cgid != 0) { - DEBUG(0,("ERROR: root did not create the semaphore\n")); + if (sem_ds.sem_perm.cuid != 0 || ((sem_ds.sem_perm.cgid != root_gid) && (sem_ds.sem_perm.cgid != 0))) { + DEBUG(0,("ERROR: root did not create the semaphore: semgid=%u, rootgid=%u\n", + (unsigned int)sem_ds.sem_perm.cgid, (unsigned int)root_gid)); return NULL; } @@ -684,7 +688,7 @@ } if (!read_only) { - if (shm_ds.shm_perm.cuid != 0 || shm_ds.shm_perm.cgid != 0) { + if (shm_ds.shm_perm.cuid != 0 || ((shm_ds.shm_perm.cgid != root_gid) && (shm_ds.shm_perm.cgid != 0))) { DEBUG(0,("ERROR: root did not create the shmem\n")); global_unlock(); return NULL; -- -------------------------------------------------------- Buying an operating system without source is like buying a self-assembly Space Shuttle with no instructions. --------------------------------------------------------