Bug 11562 - s4:lib/messaging: use correct path for names.tdb
Summary: s4:lib/messaging: use correct path for names.tdb
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Other (show other bugs)
Version: unspecified
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Karolin Seeger
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-20 09:26 UTC by Ralph Böhme
Modified: 2021-01-18 11:12 UTC (History)
2 users (show)

See Also:


Attachments
Patch for master (3.66 KB, patch)
2015-10-20 09:40 UTC, Ralph Böhme
no flags Details
Patch for 4.3 cherry-picked from master (2.42 KB, patch)
2015-10-22 09:36 UTC, Ralph Böhme
jra: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ralph Böhme 2015-10-20 09:26:50 UTC
source3 messaging_init() calls server_id_db_init() (where names.tdb is created) with lock_path. source4 imessaging_init() otoh wrongly used the special lock_path subdirectory "msg.lock":
    
> find /opt/samba/ -name names.tdb
/opt/samba/var/lock/msg.lock/names.tdb
/opt/samba/var/lock/names.tdb

> tdbdump /opt/samba/var/lock/names.tdb
{
key(14) = "notify-daemon\00"
data(27) = "28609/12756565486113779780\00"
}

> tdbdump /opt/samba/var/lock/msg.lock/names.tdb
{
key(15) = "winbind_server\00"
data(8) = "28593/0\00"
}
    
With a follow up patch both source3 and source4 messaging now use the same names.tdb which is what we want:
    
> find /opt/samba/ -name names.tdb
/opt/samba/var/lock/names.tdb
    
> tdbdump /opt/samba/var/lock/names.tdb
{
key(15) = "winbind_server\00"
data(8) = "26434/0\00"
}
{
key(14) = "notify-daemon\00"
data(26) = "26452/3454520012124001687\00"
}
Comment 1 Ralph Böhme 2015-10-20 09:40:41 UTC
Created attachment 11510 [details]
Patch for master
Comment 2 Ralph Böhme 2015-10-22 09:36:31 UTC
Created attachment 11526 [details]
Patch for 4.3 cherry-picked from master
Comment 3 Jeremy Allison 2015-10-22 17:32:45 UTC
Comment on attachment 11526 [details]
Patch for 4.3 cherry-picked from master

LGTM.
Comment 4 Jeremy Allison 2015-10-22 17:33:06 UTC
Reassigning to Karolin for inclusion in 4.3.next.
Comment 5 Karolin Seeger 2015-10-28 09:47:56 UTC
Pushed to autobuild-v4-3-test.
Comment 6 Karolin Seeger 2015-10-29 08:39:13 UTC
(In reply to Karolin Seeger from comment #5)
Pushed to v4-3-test.
Closing out bug report.

Thanks!