Multiple smbd process by user, 10% cpu load each! - SMB

This is a discussion on Multiple smbd process by user, 10% cpu load each! - SMB ; I have a PDC samba for 40 users. It works fine exept that I only use it for authentification for now (no share exept logon script) and each user connect generate 2 to 5 smbd process that sucks up to ...

+ Reply to Thread
Results 1 to 6 of 6

Thread: Multiple smbd process by user, 10% cpu load each!

  1. Multiple smbd process by user, 10% cpu load each!

    I have a PDC samba for 40 users. It works fine exept that I only use
    it for authentification for now (no share exept logon script) and each
    user connect generate 2 to 5 smbd process that sucks up to 25% of the
    cpu each !!! I tryed the option "deadtime 30" but without good result
    !
    I really don't know where it comes from.

  2. Re: Multiple smbd process by user, 10% cpu load each!

    fred wrote:

    > I have a PDC samba for 40 users. It works fine exept that I only use
    > it for authentification for now (no share exept logon script) and each
    > user connect generate 2 to 5 smbd process that sucks up to 25% of the
    > cpu each !!! I tryed the option "deadtime 30" but without good result
    > !
    > I really don't know where it comes from.


    Looks like a race condition. Which version of samba and *nix, your smb.conf
    and did you run testparm, did you double-check your unix filesystem
    permissions for the /homes and netlogon shares? What about the samba
    logfiles?
    --
    Longhorn error#4711: TCPA / NGSCB VIOLATION: Microsoft optical mouse
    detected penguin patterns on mousepad. Partition scan in progress
    *to*remove*offending*incompatible*products.**React ivate*your*MS*software.
    Linux woodpecker.homnet.at 2.6.8-rc2-bk9pkt*[LinuxCounter#295241]

  3. Re: Multiple smbd process by user, 10% cpu load each!

    > Looks like a race condition. Which version of samba and *nix, your smb.conf
    > and did you run testparm, did you double-check your unix filesystem
    > permissions for the /homes and netlogon shares? What about the samba
    > logfiles?


    Thanks for help !

    Samba 3.0.4 on debian woody kernel 2.6
    Testparm run ok !
    Server role: ROLE_DOMAIN_PDC
    # Global parameters
    [global]
    workgroup = OPTELVISION.NET
    server string = pdc samba
    min passwd length = 6
    smb passwd file = /etc/samba/smbpasswd
    passdb backend = tdbsam
    pam password change = Yes
    passwd program = /usr/bin/passwd %u
    passwd chat = *password* %n\n *password* %n\n *changed*
    unix password sync = Yes
    log file = /var/log/samba/%U.log
    time server = Yes
    socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
    add user script = /usr/sbin/useradd -m %u
    delete user script = /usr/sbin/userdel %s
    add group script = /usr/sbin/groupadd -r %g
    delete group script = /usr/sbin/groupdel %g
    add user to group script = /usr/bin/gpasswd -a %u %g
    delete user from group script = /usr/bin/gpasswd -d %U %g
    set primary group script = /usr/sbin/usermod -g %g %u
    add machine script = /usr/sbin/useradd -g pcs -d /dev/null -c "auto
    added" -s /bin/false %m$
    logon script = %U.cmd
    logon drive = p:
    logon home = \\home\%U
    domain logons = Yes
    os level = 33
    preferred master = Yes
    wins support = Yes
    idmap uid = 10000-20000
    idmap gid = 10000-20000
    invalid users = bin, deamon, sys, man, postfix, mail, ftp
    admin users = sysadmin
    hosts allow = 192.168.0/24
    hide unreadable = Yes

    [homes]
    comment = Home Directories
    read only = No
    browseable = No
    oplocks = No
    level2 oplocks = No

    [netlogon]
    comment = Network Logon Service
    path = /home/netlogon
    write list = @domadm
    guest ok = Yes
    oplocks = No
    level2 oplocks = No
    share modes = No
    root preexec = /root/mklogon %m %U %a %g %L

    log file :
    Those lines a repeating :
    .log
    [2004/08/09 09:40:54, 0]
    rpc_server/srv_pipe.c:api_pipe_netsec_process(1397)
    failed to decode PDU
    [2004/08/09 09:40:54, 0]
    rpc_server/srv_pipe_hnd.crocess_request_pdu(605)
    process_request_pdu: failed to do schannel processing.

    nothing interesting in log.smbd
    nothing interesting in log.%U

  4. Re: Multiple smbd process by user, 10% cpu load each!

    fred wrote:

    >> Looks like a race condition. Which version of samba and *nix, your
    >> smb.conf and did you run testparm, did you double-check your unix
    >> filesystem permissions for the /homes and netlogon shares? What about the
    >> samba logfiles?

    >
    > Thanks for help !
    >
    > Samba 3.0.4 on debian woody kernel 2.6
    > Testparm run ok !
    > Server role: ROLE_DOMAIN_PDC
    > # Global parameters
    > [global]
    > workgroup = OPTELVISION.NET


    Hmmm. Are you sure a netbios name with a dot inside is ok?
    It will force windows to resort to search the PDC not via wins but via a SRV
    dns record instead ... which isn't what you want in most cases?

    However, I found
    http://www.mail-archive.com/samba%40.../msg41875.html
    describing a similar issue.
    Take a look if that (stale entries in /etc/group) might cause your problems.

    Btw. why do you turn off oplocks completely?


    --
    Longhorn error#4711: TCPA / NGSCB VIOLATION: Microsoft optical mouse
    detected penguin patterns on mousepad. Partition scan in progress
    *to*remove*offending*incompatible*products.**React ivate*your*MS*software.
    Linux woodpecker.homnet.at 2.6.8-rc2-bk9pkt*[LinuxCounter#295241]

  5. Re: Multiple smbd process by user, 10% cpu load each!

    Little more info :
    From "ps aux"
    nobody 15183 99.9 0.1 6704 2976 ? R 14:33 121:21 smbd
    nobody 15293 99.9 0.1 6708 2972 ? R 15:28 66:42 smbd
    nobody 15303 99.9 0.1 6696 2976 ? R 15:35 59:41 smbd
    nobody 15369 99.9 0.1 6712 2988 ? R 16:04 30:01 smbd
    root 15402 0.0 0.1 6676 2980 ? S 16:27 0:00 smbd
    from "smbstatus"
    IPC$ 15183 veronique Mon Aug 9 14:33:21 2004
    from the log corresponding to user :
    [2004/08/09 14:32:33, 0]
    rpc_server/srv_util.c:get_domain_user_groups(376)
    get_domain_user_groups: primary gid of user [user] is not a Domain
    group !
    get_domain_user_groups: You should fix it, NT doesn't like that
    [2004/08/09 14:32:33, 0]
    rpc_server/srv_util.c:get_alias_user_groups(219)
    get_alias_user_groups: gid of user user doesn't exist. Check your
    /etc/passwd and /etc/group files

  6. Re: Multiple smbd process by user, 10% cpu load each!

    Everything is now normal. Thanks Walter for your help. This was
    invalid user in group definition. And I use the script from Dragan
    Krnic to find them which is very cool.

+ Reply to Thread