AIX Open Source

AIX Open Source

Share your experiences and connect with fellow developers to discover how to build and manage open source software for the AIX operating system

 View Only
Expand all | Collapse all

Samba panics and core dumps

  • 1.  Samba panics and core dumps

    Posted Tue February 16, 2021 10:52 AM
      |   view attached

    Trying to install a very simple standalone samba server on AIX 7.2 using samba 4.12.10.  I installed samba using yum.

    root@burnina-new.btv: /var/log/samba

    # rpm -qa|grep -E "samba|smb"

    samba-libs-4.12.10-1.ppc

    samba-devel-4.12.10-1.ppc

    samba-winbind-clients-4.12.10-1.ppc

    samba-client-4.12.10-1.ppc

    samba-test-libs-4.12.10-1.ppc

    samba-python3-4.12.10-1.ppc

    samba-pidl-4.12.10-1.ppc

    samba-winbind-krb5-locator-4.12.10-1.ppc

    samba-winbind-4.12.10-1.ppc

    samba-common-4.12.10-1.ppc

    libsmbclient-4.12.10-1.ppc

    samba-4.12.10-1.ppc

    samba-test-4.12.10-1.ppc

    libsmbclient-devel-4.12.10-1.ppc

    samba-winbind-devel-4.12.10-1.ppc

    root@burnina-new.btv: /etc/samba

    # cat smb.conf

    [global]

    # log file = /var/log/samba/%

    passdb backend = tdbsam

    log level = 3

    debug level = 10

    debug pid = true

    max log size = 0

    [TEST]

    # This share requires authentication to access

    path = /testfs

    read only = no

    root@burnina-new.btv: /var/log/samba

    # testparm /etc/samba/smb.conf

    Load smb config files from /etc/samba/smb.conf

    Loaded services file OK.

    Server role: ROLE_STANDALONE

    Press enter to see a dump of your service definitions

    # Global parameters

    [global]

    debug pid = Yes

    max log size = 0

    idmap config * : backend = tdb

    [TEST]

    path = /testfs

    read only = No

    ------------------------

    root@burnina-new.btv: /var/log/samba

    # /opt/freeware/sbin/nmbd -D

    ------------------------

    root@burnina-new.btv: /var/log/samba

    # /opt/freeware/sbin/smbd -D –configfile=/etc/samba/smb.conf

    root@burnina-new.btv: /var/log/samba

    # tail log.smbd

    INTERNAL ERROR: Signal 11 in pid 8520072 (4.12.10)

    If you are running a recent Samba version, and if you think this problem is not yet fixed in the latest versions, please consider reporting this bug, see https://wiki.samba.org/index.php/Bug_Reporting

    [2021/02/16 07:43:26.571072, 0, pid=8520072, effective(0, 0), real(0, 0)] ../../lib/util/fault.c:86(fault_report)

    ===============================================================

    [2021/02/16 07:43:26.571131, 0, pid=8520072, effective(0, 0), real(0, 0)] ../../source3/lib/util.c:830(smb_panic_s3)

    PANIC (pid 8520072): internal error

    [2021/02/16 07:43:26.571205, 0, pid=8520072, effective(0, 0), real(0, 0)] ../../lib/util/fault.c:277(log_stack_trace)

    unable to produce a stack trace on this platform

    [2021/02/16 07:43:26.571276, 0, pid=8520072, effective(0, 0), real(0, 0)] ../../source3/lib/dumpcore.c:315(dump_core)

    dumping core in /var/log/samba/cores/smbd


    ======================
    I have attached the logs and core.  
    Any help would be greatly appreciated.  I am desperate to get this working!
    Thanks so much!
    Cyd



    ------------------------------
    Cyd Ferry
    ------------------------------

    Attachment(s)

    zip
    samba_logs.zip   29 KB 1 version


  • 2.  RE: Samba panics and core dumps

    Posted Wed February 17, 2021 03:56 AM
    There is not much info available in the logs. 
    Can you run dbx on the core and print the stack trace. 
    "dbx /opt/freeware/sbin/smbd smbd_core" 
    (dbx) where

    ------------------------------
    Ayappan P
    ------------------------------



  • 3.  RE: Samba panics and core dumps

    Posted Wed February 17, 2021 07:23 AM
    root@burnina-new.btv: /var/log/samba/cores/smbd
    # dbx /opt/freeware/sbin/smbd core
    Type 'help' for help.
    warning: The core file is not a fullcore. Some info may
    not be available.
    [using memory image in core]
    reading symbolic information ...

    IOT/Abort trap in pthread_kill at 0xd05949ec
    0xd05949ec (pthread_kill+0xac) 80410014 lwz r2,0x14(r1)
    (dbx) where
    pthread_kill(??, ??) at 0xd05949ec
    _p_raise(??) at 0xd0593dc8
    raise.raise(??) at 0xd01247a4
    abort() at 0xd018a6b8
    dump_core() at 0xd20e1a1c
    smb_panic_s3(0xd243b770) at 0xd20c5a18
    smb_panic(0xd243b770) at 0xd23d5d78
    fault_report(0xb) at 0xd23d5f64
    sig_fault(0xb) at 0xd23d5fd4
    ldap_enable_cache(ld = 0xf05f5b98, timeout = -262171729, maxmem = 4033), line 81 in "cache.c"
    do_open() at 0xd1288c00
    _nss_ldap_search(??, ??, ??, ??, ??) at 0xd1289e30
    _nss_ldap_getbyname(??, ??, ??, ??, ??, ??, ??, ??) at 0xd1289a8c
    pw_byname(??, ??) at 0xd128d924
    _nss_ldap_getpwnam(??) at 0xd1286138
    _getpwnam_shadow_r(??, ??, ??, ??, ??) at 0xd01e7b30
    getpwnam(??) at 0xd01e9b4c
    getpwnam_alloc_cached(0x30048448, 0x2ff22330) at 0xd20ce5ec
    Get_Pwnam_internals(0x30048448, 0x300486f8, 0x2ff22330) at 0xd20ceaac
    Get_Pwnam_alloc(0x30048448, 0x300486f8) at 0xd20ceeac
    smb_getpwnam(0x30048448, 0x300486f8, 0x2ff224fc, 0x1000001) at 0xd38431cc
    check_account(0x30048448, 0x30048598, 0x30048558, 0x2ff22554, 0x2ff225f0, 0x2ff225ec) at 0xd3843520
    make_server_info_info3(0x30044dc8, 0x3002f358, 0x3002f1d8, 0x2ff22664, 0x2ff22670) at 0xd3843728
    make_new_session_info_guest(0x0, 0x200de7b8, 0x200de7c0) at 0xd3843be8
    init_guest_session_info(0x0) at 0xd3844198
    main(0x3, 0x2ff22af0) at 0x100038f4
    (dbx)

    ------------------------------
    Cyd Ferry
    ------------------------------



  • 4.  RE: Samba panics and core dumps

    Posted Wed February 17, 2021 08:26 AM
    Do you have any ldap fileset installed in your machine ? 
    lslpp -l | grep ldap

    ------------------------------
    Ayappan P
    ------------------------------



  • 5.  RE: Samba panics and core dumps

    Posted Wed February 17, 2021 11:08 AM
    cyd@burnina-new.btv: /afs/apd.pok.ibm.com/u/cyd
    # lslpp -l|grep ldap
    gsa.ldapauth.rte 6.0.0.9 COMMITTED ldapauth GSA client package


    I don't want to use LDAP authentication.  Just want a standalone server using local authentication.

    Thank you so much for helping me with this!

    ------------------------------
    Cyd Ferry
    ------------------------------



  • 6.  RE: Samba panics and core dumps

    Posted Wed February 17, 2021 11:42 AM
    Are you using GSA authentication ? 
    If not, then you can comment out the below lines in /etc/methods.cfg and then try starting smbd
    #GSA:
    # program = /usr/lib/security/GSA
    # program_64 = /usr/lib/security/GSA64

    ------------------------------
    Ayappan P
    ------------------------------



  • 7.  RE: Samba panics and core dumps

    Posted Wed February 17, 2021 01:18 PM
    That worked!  Only problem now  AFS login is broken.    We do you AFS to log into the server.  Any thoughts on how to get both working together.

    Thanks,
    Cyd

    ------------------------------
    Cyd Ferry
    ------------------------------



  • 8.  RE: Samba panics and core dumps

    Posted Thu February 18, 2021 12:24 AM
    I need to look into it. 
    Right now , I don't have any idea to get both working together. 
    Form the stack trace , it looks like smbd invokes getpwnam syscall which loads gsaldap library , based on the entry in /etc/methods.cfg. And returns something which the smbd can't handle.

    ------------------------------
    Ayappan P
    ------------------------------



  • 9.  RE: Samba panics and core dumps

    Posted Thu February 18, 2021 09:58 AM
    Ayappan,
    I am having Todd Desantis who is on the openAFS team look into it as well.  I can live without AFS id I need to.  Just will have to have a local id and password to keep track of.  I will let you know if Todd finds anything.
    Thank you so much for all of your help!!
    Cyd

    ------------------------------
    Cyd Ferry
    ------------------------------



  • 10.  RE: Samba panics and core dumps

    Posted Fri February 19, 2021 09:25 AM
    Ayappan,
    I accidentally used  hash marks to comment out the GSA stanza in /etc/methods.cfg.   Todd noticed that and corrected it. With GSA commented out correctly, Samba and AFS  are working happily together now.
    Thank you so much for your help!
    Cyd

    ------------------------------
    Cyd Ferry
    ------------------------------