Rebuilding samba as "user" (not root) seem to yield a program that can't
switch uid / gid's. Take a look what happens when my GF tries to logon
to the samba server:
[2000/11/26 14:56:33, 0] lib/util_sec.c:assert_gid(72)
Failed to set gid privileges to (-1,702) now set to (0,0) uid=(0,0)
[2000/11/26 14:56:33, 0] lib/util.c:smb_panic(2381)
PANIC: failed to set gid
[2000/11/26 14:56:42, 0] lib/util_sec.c:assert_gid(72)
Failed to set gid privileges to (-1,702) now set to (0,0) uid=(0,0)
[2000/11/26 14:56:42, 0] lib/util.c:smb_panic(2381)
PANIC: failed to set gid
[2000/11/26 15:10:45, 0] lib/util_sec.c:assert_gid(72)
Failed to set gid privileges to (-1,702) now set to (0,0) uid=(0,0)
[2000/11/26 15:10:45, 0] lib/util.c:smb_panic(2381)
PANIC: failed to set gid
I have been using user-built samba's for a long time, and now since
glibc-2.2 this is going on....
Take a look at this diff between the buildout of the samba package built
as root and as user (the "cooker" user in this case). Do you see that
the "checking for setreuid..." test with the "cooker" user yields the
same error as stated above? What do you make out of it?
---
/misc/linux/mandrake/buildout/cooker/alpha/OK/samba-2.0.7-20mdk.src.rpm.txt
Sun Nov 26 12:48:41 2000
+++ samba.out Sun Nov 26 15:25:01 2000
@@ -1,18 +1,20 @@
Installing /mirrors/SRPMS/samba-2.0.7-20mdk.src.rpm
-Executing(%prep): /bin/sh -e /users/cooker/tmp/rpm-tmp.30304
+Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.54701
+ umask 022
-+ cd /users/cooker/RPM/BUILD
-+ cd /users/cooker/RPM/BUILD
++ cd /usr/src/RPM/BUILD
++ cd /usr/src/RPM/BUILD
+ rm -rf samba-2.0.7
-+ /usr/bin/bzip2 -dc /users/cooker/RPM/SOURCES/samba-2.0.7.tar.bz2
++ /usr/bin/bzip2 -dc /usr/src/RPM/SOURCES/samba-2.0.7.tar.bz2
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd samba-2.0.7
++ /usr/bin/id -u
-+ '[' 800 = 0 ']'
++ '[' 0 = 0 ']'
++ /bin/chown -Rhf root .
++ /usr/bin/id -u
-+ '[' 800 = 0 ']'
++ '[' 0 = 0 ']'
++ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,g-w,o-w .
+ echo 'Patch #0 (samba-makefilepath.patch.bz2):'
Patch #0 (samba-makefilepath.patch.bz2):
@@ -81,9 +83,9 @@
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ exit 0
-Executing(%build): /bin/sh -e /users/cooker/tmp/rpm-tmp.66780
+Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.76783
+ umask 022
-+ cd /users/cooker/RPM/BUILD
++ cd /usr/src/RPM/BUILD
+ cd samba-2.0.7
+ cd source
+ autoconf
@@ -431,15 +433,17 @@
checking for working fnmatch... yes
checking for broken inet_ntoa... no
checking for sysconf(_SC_NGROUPS_MAX)... yes
-checking for root... no
-configure: warning: running as non-root will disable some tests
+checking for root... yes
checking for iface AIX... no
checking for iface ifconf... got 3 interfaces:
eth0 IP=213.46.10.179 NETMASK=255.255.255.192
eth1 IP=192.168.1.254 NETMASK=255.255.255.0
lo IP=127.0.0.1 NETMASK=255.0.0.0
yes
-checking for setresuid... yes
+checking for setresuid... Failed to set gid privileges to (-1,1) now
set to (0,0) uid=(0,0)
+no
+checking for setreuid... OK
+yes
checking for shared mmap... yes
checking for ftruncate needs root... no
checking for fcntl locking... yes
@@ -627,1870 +631,3 @@
2nd point: is this chkconfig line enough?:
# chkconfig: - 91 35
can't that be:
# chkconfig: 345 91 35
TIA,
Stefan
Stefan