Bug 240676 - After upgrading to samba.i386 3.0.24-5.fc6 smb crashes with errors
After upgrading to samba.i386 3.0.24-5.fc6 smb crashes with errors
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: samba (Show other bugs)
6
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Samba Maint Team
David Lawrence
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2007-05-19 19:38 EDT by Neil Squires
Modified: 2007-11-30 17:12 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2007-05-21 17:24:29 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
My smb conf file. (2.27 KB, text/plain)
2007-05-19 19:38 EDT, Neil Squires
no flags Details
Open ldap conf file (340 bytes, text/plain)
2007-05-19 19:41 EDT, Neil Squires
no flags Details
LDAP Slapd conf file (3.65 KB, text/plain)
2007-05-19 19:41 EDT, Neil Squires
no flags Details
smbd log file level 10 (19.46 KB, text/plain)
2007-05-21 03:53 EDT, Neil Squires
no flags Details
updated log file (47.10 KB, text/plain)
2007-05-21 09:17 EDT, Neil Squires
no flags Details

  None (edit)
Description Neil Squires 2007-05-19 19:38:59 EDT
Description of problem: I upgraded my samba to the latest version from updates
(3.0.24-5 and then the smb process crashes out with the log showing the following:

May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/asyncdns.c:start_async_dns(151) 
May 20 09:17:27 sensi nmbd[3188]:   started asyncdns process 3189 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_logonnames.c:add_logon_names(163) 
May 20 09:17:27 sensi nmbd[3188]:   add_domain_logon_names: 
May 20 09:17:27 sensi nmbd[3188]:   Attempting to become logon server for
workgroup N-KSQUIRES on subnet 192.168.1.2 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_logonnames.c:add_logon_names(163) 
May 20 09:17:27 sensi nmbd[3188]:   add_domain_logon_names: 
May 20 09:17:27 sensi nmbd[3188]:   Attempting to become logon server for
workgroup N-KSQUIRES on subnet UNICAST_SUBNET 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_become_dmb.c:become_domain_master_browser_wins(335) 
May 20 09:17:27 sensi nmbd[3188]:   become_domain_master_browser_wins: 
May 20 09:17:27 sensi nmbd[3188]:   Attempting to become domain master browser
on workgroup N-KSQUIRES, subnet UNICAST_SUBNET. 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_become_dmb.c:become_domain_master_browser_wins(349) 
May 20 09:17:27 sensi nmbd[3188]:   become_domain_master_browser_wins: querying
WINS server from IP 192.168.1.2 for domain master browser name N-KSQUIRES<1b> on
workgroup N-KSQUIRES 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_logonnames.c:become_logon_server_success(124) 
May 20 09:17:27 sensi nmbd[3188]:   become_logon_server_success: Samba is now a
logon server for workgroup N-KSQUIRES on subnet UNICAST_SUBNET 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_become_dmb.c:become_domain_master_stage2(113) 
May 20 09:17:27 sensi nmbd[3188]:   ***** 
May 20 09:17:27 sensi nmbd[3188]:    
May 20 09:17:27 sensi nmbd[3188]:   Samba server SENSI is now a domain master
browser for workgroup N-KSQUIRES on subnet UNICAST_SUBNET 
May 20 09:17:27 sensi nmbd[3188]:    
May 20 09:17:27 sensi nmbd[3188]:   ***** 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_become_dmb.c:become_domain_master_browser_bcast(290) 
May 20 09:17:27 sensi nmbd[3188]:   become_domain_master_browser_bcast: 
May 20 09:17:27 sensi nmbd[3188]:   Attempting to become domain master browser
on workgroup N-KSQUIRES on subnet 192.168.1.2 
May 20 09:17:27 sensi nmbd[3188]: [2007/05/20 09:17:27, 0]
nmbd/nmbd_become_dmb.c:become_domain_master_browser_bcast(303) 
May 20 09:17:27 sensi nmbd[3188]:   become_domain_master_browser_bcast: querying
subnet 192.168.1.2 for domain master browser on workgroup N-KSQUIRES 
May 20 09:17:27 sensi smbd[3185]: [2007/05/20 09:17:27, 0]
services/services_db.c:svcctl_init_keys(420) 
May 20 09:17:27 sensi smbd[3185]:   init_services_keys: key lookup failed!
(WERR_ACCESS_DENIED) 
May 20 09:17:27 sensi smbd[3185]: [2007/05/20 09:17:27, 0] smbd/server.c:main(960) 
May 20 09:17:27 sensi smbd[3185]:   ERROR: failed to setup guest info. 

The system is functioning as a PDC using the LDAP password storage backend. 

Version-Release number of selected component (if applicable): samba.i386
3.0.24-5.fc6


How reproducible: Every time the /etc/init.d/smb restart/start is used.


Steps to Reproduce:
1. Install samba and configure the system to be a PDC with an LDAP backend
2. Upgrade samba to 3.0.24-5
3. try restarting the smbd services
  
Actual results: smb crashes out and no samba shares are available. nmbd still
runs and users can log in.


Expected results: smb starts, users can log on and map network resources.


Additional info: A search for the bug on Google shows that it is a known problem
with 3.0.24 using the ldap passwd backend and that it was fixed in 3.0.25.

Prior to the upgrade, samba and the system was working fine.
Comment 1 Neil Squires 2007-05-19 19:38:59 EDT
Created attachment 155053 [details]
My smb conf file.
Comment 2 Neil Squires 2007-05-19 19:41:09 EDT
Created attachment 155054 [details]
Open ldap conf file

Attached for reference
Comment 3 Neil Squires 2007-05-19 19:41:51 EDT
Created attachment 155055 [details]
LDAP Slapd conf file
Comment 4 Neil Squires 2007-05-19 19:55:08 EDT
Post to Fedora Forums with reference to samba bug

http://forums.fedoraforum.org/showthread.php?p=793627#post793627
Comment 5 Simo Sorce 2007-05-20 20:20:12 EDT
I am sorry the log you pasted show no trace of crashes.
Can you raise your log level to 10 reproduce the crash (I need a stack trace in
the logs) and post it as attachment here?
Comment 6 Neil Squires 2007-05-21 03:53:51 EDT
Created attachment 155077 [details]
smbd log file level 10
Comment 7 Neil Squires 2007-05-21 03:58:46 EDT
I am not sure how to launch smb using the /etc/init.d/smb and change the log
level. The log level was changed in the smb.conf and does not provide a stack
trace that I can see.

If you can post any hints on what to do to get the stack trace then please email me.

Thanks
Comment 8 Pete Graner 2007-05-21 07:39:57 EDT
In reply to comment #7.


Make the SMBDOPTIONS="-D" look like SMBDOPTIONS="-D -d 10" in the
/etc/sysconfig/samba file. This will override any options in the smb.conf file. 
Comment 9 Simo Sorce 2007-05-21 09:13:09 EDT
(In reply to comment #7)
> I am not sure how to launch smb using the /etc/init.d/smb and change the log
> level. The log level was changed in the smb.conf and does not provide a stack
> trace that I can see.

That's because there is no crash.
Samba exits on an error condition.
It seem something in your configuration is wrong.

Can you check your "nobody" user and group are correctly set up in your system
/etc/passwd,/etc/group files and there is no user/group with the same uid/gid on
the ldap server ?
Comment 10 Neil Squires 2007-05-21 09:17:55 EDT
Created attachment 155092 [details]
updated log file
Comment 11 Neil Squires 2007-05-21 09:28:02 EDT
Yes you are correct Samba is exiting on an error condition that has appeared
following my upgrade of the samba to 3.0.24-5 as I have stated. The previous
version was running fine.

See logwatch file for upgrade details below.

 
 Packages Updated:
    php-mysql.i386 5.1.6-3.6.fc6
    freeradius.i386 1.1.3-2.fc6
    samba-swat.i386 3.0.24-5.fc6
    ypbind.i386 3:1.19-7.fc6
    tcllib.noarch 1.9-2.fc6
    gsm.i386 1.0.12-3.fc6
    php-mbstring.i386 5.1.6-3.6.fc6
    openldap-clients.i386 2.3.30-2.fc6
    php.i386 5.1.6-3.6.fc6
    openldap-servers-sql.i386 2.3.30-2.fc6
    firefox.i386 1.5.0.10-6.fc6
    wavpack.i386 4.41-1.fc6
    openldap.i386 2.3.30-2.fc6
    php-common.i386 5.1.6-3.6.fc6
    procps.i386 3.2.7-10.fc6
    samba-common.i386 3.0.24-5.fc6
    openldap-servers.i386 2.3.30-2.fc6
    samba.i386 3.0.24-5.fc6
    samba-client.i386 3.0.24-5.fc6
    squirrelmail.noarch 1.4.10a-1.fc6
    php-pdo.i386 5.1.6-3.6.fc6
    openldap-devel.i386 2.3.30-2.fc6
    php-ldap.i386 5.1.6-3.6.fc6
    firefox-devel.i386 1.5.0.10-6.fc6
    php-cli.i386 5.1.6-3.6.fc6
    logrotate.i386 3.7.4-13.fc6
    nfs-utils.i386 1:1.0.10-10.fc6
    foomatic.i386 3.0.2-39.5.fc6
 
 ---------------------- yum End -------------------------

I still have my nobody user and group set up on my system and no changes were
made to the existing config files that were working the day before.

After I ran the yum update -y command and noticed that the samba and ldap server
had been updated. I restarted the services and notice the error.

None of the attached config files had been updated the day I did the upgrade.
Comment 12 Simo Sorce 2007-05-21 09:31:17 EDT
Can you tell me exactly what version were you using before the update?
This way I can easily identify the relevant changes and inspect the code to see
if we broke something by mistake.

Ty.
Comment 13 Neil Squires 2007-05-21 09:41:28 EDT
Ok. On the 14 Apr 07 I upgrade samba to samba.i386 3.0.24-4.fc6 with no problems.

I don't think you guys broke it. If you read the posts, there appears to
possibly be a problem with Samba that will be fixed in 3.0.25 when using the
LDAP backend. You may wish to check that first.

Regards

Neil
Comment 14 Simo Sorce 2007-05-21 10:44:56 EDT
I am trying to get enough evidence to understand what is the issue.
A minor upgrade shouldn;t break it so I am interesting in finding out what's
going on.

Can you tell me if you have a mapping for user nobody in /etc/samba/smbusers ?
Can you tell me if you see avc messages in the audit.log (if you have selinux
enabled and enforcing).
Can you attach the output of net groupmap list run as root?

Ty
Comment 15 Guenther Deschner 2007-05-21 11:02:03 EDT
Right, from a quick view over the logs, samba has all kinds of problems to
access your LDAP server. It cannot even access the rootdse

-----8<------------------snip--------------8<--------------
[2007/05/21 22:59:02, 3] lib/smbldap.c:smbldap_check_root_dse(1636)
  smbldap_check_root_dse: Expected one rootDSE,
----->8------------------snap-------------->8--------------

Likewise samba cannot access your toplevel basedn object in the Directory

-----8<------------------snip--------------8<--------------
[2007/05/21 22:59:02, 10] lib/smbldap.c:smbldap_search_ext(1237)
  Failed search for base: dc=n-ksquires,dc=id,dc=au, error: No such object ()
----->8------------------snap-------------->8--------------

Can you please make sure 

* there have been no ACL changes on the LDAP server side ?
* to look for errors in your LDAP servers log files ?

Although nothing points into that direction right now, can you please reset your
LDAP access password (using "smbpasswd -w yourpassword").

For faster testing: As long as "pdbedit -L -d 0" does not return your list of
users, smbd won't run properly.
Comment 16 Neil Squires 2007-05-21 16:51:21 EDT
For Ty,

I do not have a nobody user or group in the LDAP directory or the smbpasswd file
and never have.

The audit log was the second place I looked and am getting no error messages.
Selinux is enforcing.

Here is the output from the net grouplist map

[root@sensi samba]# net groupmap list > /home/nfsquires/net_groupmap_list
[2007/05/22 06:15:59, 0] passdb/pdb_ldap.c:ldapsam_setsamgrent(3098)
  ldapsam_setsamgrent: LDAP search failed: No such object
[2007/05/22 06:15:59, 0] passdb/pdb_ldap.c:ldapsam_enum_group_mapping(3170)
  ldapsam_enum_group_mapping: Unable to open passdb


For Guther,
          You are correct, my samba cannot access my LDAP directory. As I have
stated before, I did not change any LDAP ACL's (to my knowledge).

I have reset the ldap user password as requested and still no change.

Now another weird thing I have just found is that I have no slapd messages in my
/var/log/message log file. Yet the status is showing OK.

Also I have found that the upgrade has overwritten my ldap database. I had not
checked this before as I did not expect it to be wiped in the update.

I will restore it from backups and advise.
Comment 17 Neil Squires 2007-05-21 17:00:38 EDT
Restored from backup and system is now working.

This problem needs to be changed to possbily "Upgrade of LDAP overwrites
exisitng database". That is the only thing that I can think of that has happened.

Thanks for the help
Comment 18 Simo Sorce 2007-05-21 17:24:29 EDT
I am sorry this happened.
I will close this bug as it is not a samba bug, would you mind opening a new one
for openLdap ?
There you can refer to this bug for more background.

Thanks.

Note You need to log in before you can comment on or make changes to this bug.