tdb_check() will always return failure for a read-only database. Silently, without any log output, when _tdb_lockall() fails. This happens every time winbindd starts up, so offline login never works. winbindd_validate_cache: replacing panic function tdb_validate_open called for tdb '/var/lib/samba/winbindd_cache.tdb' tdb_validate called for tdb '/var/lib/samba/winbindd_cache.tdb' tdb_validate: forking to let child do validation. tdb_validate: fork succeeded, child PID = 10213 tdb_validate: waiting for child to finish... tdb_validate (validation child): created tdb_validate (validation child): calling tdb_validate_child tdb_validate_child: summary of validation status: * tdb error: yes * bad freelist: no * bad entry: no * unknown key: no => overall success: no tdb_validate: validating child returned. tdb_validate: child exited, code 255. tdb_validate returning code '255' for tdb '/var/lib/samba/winbindd_cache.tdb' tdb '/var/lib/samba/winbindd_cache.tdb' is invalid Could not stat '/var/lib/samba/winbindd_cache.tdb.bak': No such file or directory No backup found. moved '/var/lib/samba/winbindd_cache.tdb' to '/var/lib/samba/winbindd_cache.tdb.corrupt' Corrupt tdb stored as '/var/lib/samba/winbindd_cache.tdb.corrupt' winbindd_validate_cache: validation not successful. removing tdb /var/lib/samba/winbindd_cache.tdb. winbindd_validate_cache: restoring panic function winbindd cache tdb corrupt and no backup could be restored. initialize_winbindd_cache: clearing cache and re-creating with version number 1 [root@i7 dwoodhou]# rpm -q samba-winbind libtdb samba-winbind-3.5.4-62.fc13.x86_64 libtdb-1.2.1-2.fc13.x86_64
This has been fixed in master. I'll create a patch for 3.5.x. Jeremy.
Created attachment 5873 [details] Fix for 3.5.x. Patch that was applied to master. Please review. Jeremy.
Created attachment 5874 [details] Fix for 3.5.x. Doh. Fix patch comment to be correct. Please review & check. Jeremy.
NB. The fix attached here also applies cleanly to the 3.4.x branch and is also needed there. Jeremy.
Comment on attachment 5874 [details] Fix for 3.5.x. Asking gd as well, to get coverage :-). Jeremy.
Comment on attachment 5874 [details] Fix for 3.5.x. gosh. thanks for catching that. I did not notice it. Only question here is, why you did not keep Bo's authorship in the patch 6e48267c28b05c3837a3e5ffc1f5b58316cc286f from master. But that is cosmetic again. :-)
I didn't realize it was a separate patch that went into master with Bo's (C). Please feel free to use Bo's copyright, not mine. Jeremy.
Comment on attachment 5874 [details] Fix for 3.5.x. looks good, thanks! this was driving me nuts here recently :)
Karolin, please pick for 3.4 and 3.5
Pushed to both branches. Closing out bug report. Thanks!
*** Bug 7709 has been marked as a duplicate of this bug. ***
This commit alone is not enough to make offline cache work after a reboot. Even though the cache is listed as valid, pam_winbind fails to find the user (and getent/wbinfo doesn't list anything either). Tested on 3.5.6 and this patch backported for 3.4.7. Should probably file a new bug?
Yes, can you open a new bug to track the problem you are seeing please. Not finding the user is a different problem. Thanks, Jeremy.
Thanks, filed bug 7760 https://bugzilla.samba.org/show_bug.cgi?id=7760