David Anderson
2002-Feb-22 13:14 UTC
[Samba] Trouble with Samba 2.2.2 under HPUX (high cpu utilization)
Hello, I have been tracking down a cause for some abnormal CPU utilization with samba. It appears after looking at glance plus that samba is spending the majority of its time (like around 75-80%) doing lstat system calls. When I used tusc I discovered that it appears to be looking for a file /tmp/.winbindd which I am assuming is the unix domain socket for winbind. However this system is not compile with winbindd as it wasnt supported under HPUX 11 in 2.2.2 and I dont really have a need for it. All of our unix users have identical named windows accounts, so its of little concern to me at this moment. I looked into the source for references to that file and it appears that smbd always tries winbind first regardless of whether or not its compiled to support winbind or not. This appears in my case to be rather heavy on system call overhead, dealing with errors. I think perhaps something that is aggrevating this is the broken Visual Basic Application ont he other end is written to open a logfile and write a line then close it to cause a sync to happen which has got to cause alot of access checks which intern will try to resolve uids. Has anyone else run into problem with this? What should I do to fix the situation, my first thought is to comment out the winbind checks from my smbd and recompile, but I want to see if there is another way. David Anderson danderso@amdocs.com PS - Here is the output from tusc getgid() ................................................. = 0 (0) setgroups(1, 0x400f1f20) ................................. = 0 setresgid(-1, 1010, -1) .................................. = 0 getgid() ................................................. = 0 (1010) setresuid(-1, 104, -1) ................................... = 0 getuid() ................................................. = 0 (104) lseek64(40, 207011840, SEEK_SET) ......................... = 207011840 write(40, "010117\0' \0\0\0\r\0g \ace065 06".., 2048) .... = 2048 send(12, "\0\0\0/ ffS M B / \0\0\0\08801\0".., 51, 0) .... = 51 select(21, 0x68ff07c8, NULL, NULL, 0x68ff08cc) ........... = 1 read(12, "\0\0\b@ ", 4) .................................. = 4 read(12, "ffS M B / \0\0\0\018\a\b\0\0\0\0".., 2112) ..... = 2112 gettimeofday(0x4009ff80, NULL) ........................... = 0 getpid() ................................................. = 16906 (26051) getpid() ................................................. = 16906 (26051) lstat("/tmp/.winbindd", 0x68ff21b8) ...................... ERR#2 ENOENT getpid() ................................................. = 16906 (26051) getpid() ................................................. = 16906 (26051) lstat("/tmp/.winbindd", 0x68ff21b8) ...................... ERR#2 ENOENT getuid() ................................................. = 0 (104) setresuid(-1, 0, -1) ..................................... = 0 getuid() ................................................. = 0 (0) getuid() ................................................. = 0 (0) getgid() ................................................. = 0 (1010) setresgid(-1, 0, -1) ..................................... = 0 getgid() ................................................. = 0 (0) getgid() ................................................. = 0 (0) setgroups(1, 0x400f1f20) ................................. = 0 setresgid(-1, 1010, -1) .................................. = 0 getgid() ................................................. = 0 (1010) setresuid(-1, 104, -1) ................................... = 0 getuid() ................................................. = 0 (104) lseek64(30, 207468544, SEEK_SET) ......................... = 207468544 write(30, "04018303' \0\0\0b68b01\0f88b01\0".., 2048) .... = 2048 send(12, "\0\0\0/ ffS M B / \0\0\0\08801\0".., 51, 0) .... = 51 select(21, 0x68ff07c8, NULL, NULL, 0x68ff08cc) ........... = 1 read(12, "\0\0\b@ ", 4) .................................. = 4 read(12, "ffS M B / \0\0\0\018\a\b\0\0\0\0".., 2112) ..... = 2112 gettimeofday(0x4009ff80, NULL) ........................... = 0 getpid() ................................................. = 16906 (26051) getpid() ................................................. = 16906 (26051) lstat("/tmp/.winbindd", 0x68ff21b8) ...................... ERR#2 ENOENT getpid() ................................................. = 16906 (26051) getpid() ................................................. = 16906 (26051) lstat("/tmp/.winbindd", 0x68ff21b8) ...................... ERR#2 ENOENT getuid() ................................................. = 0 (104) setresuid(-1, 0, -1) ..................................... = 0 getuid() ................................................. = 0 (0) getuid() ................................................. = 0 (0) getgid() ................................................. = 0 (1010) setresgid(-1, 0, -1) ..................................... = 0 getgid() ................................................. = 0 (0) getgid() ................................................. = 0 (0) setgroups(1, 0x400f1f20) ................................. = 0 setresgid(-1, 1010, -1) .................................. = 0 getgid() ................................................. = 0 (1010) setresuid(-1, 104, -1) ................................... = 0 getuid() ................................................. = 0 (104) lseek64(40, 207013888, SEEK_SET) ......................... = 207013888 write(40, "010117\0' \0\0\0\r\0g \ace065 06".., 2048) .... = 2048 send(12, "\0\0\0/ ffS M B / \0\0\0\08801\0".., 51, 0) .... = 51 select(21, 0x68ff07c8, NULL, NULL, 0x68ff08cc) ........... = 1 read(12, "\0\0\0A ", 4) .................................. = 4 read(12, "ffS M B / \0\0\0\018\a( \0\0\0\0".., 65) ....... = 65 gettimeofday(0x4009ff80, NULL) ........................... = 0 getpid() ................................................. = 16906 (26051) getpid() ................................................. = 16906 (26051) lstat("/tmp/.winbindd", 0x68ff21b8) ...................... ERR#2 ENOENT getpid() ................................................. = 16906 (26051) getpid() ................................................. = 16906 (26051) lstat("/tmp/.winbindd", 0x68ff21b8) ...................... ERR#2 ENOENT getuid() ................................................. = 0 (104) setresuid(-1, 0, -1) ..................................... = 0 getuid() ................................................. = 0 (0) getuid() ................................................. = 0 (0) getgid() ................................................. = 0 (1010) setresgid(-1, 0, -1) ..................................... = 0 getgid() ................................................. = 0 (0) getgid() ................................................. = 0 (0) setgroups(1, 0x400f1f20) ................................. = 0 setresgid(-1, 1010, -1) .................................. = 0 getgid() ................................................. = 0 (1010) setresuid(-1, 104, -1) ................................... = 0 getuid() ................................................. = 0 (104) lseek64(30, 207472639, SEEK_SET) ......................... = 207472639 write(30, "\0", 1) ....................................... = 1 send(12, "\0\0\0/ ffS M B / \0\0\0\08801\0".., 51, 0) .... = 51 select(21, 0x68ff07c8, NULL, NULL, 0x68ff08cc) ........... = 1 read(12, "\0\0\0A ", 4) .................................. = 4 read(12, "ffS M B / \0\0\0\018\a( \0\0\0\0".., 65) ....... = 65 gettimeofday(0x4009ff80, NULL) ........................... = 0 getpid() ................................................. = 16906 (26051) getpid() ................................................. = 16906 (26051) lstat("/tmp/.winbindd", 0x68ff21b8) ...................... ERR#2 ENOENT ( Detaching from process 16906 ("/opt/samba/sbin/smbd -D") ) #