Bug 10892 - CTDB not integrated into top-level Samba build
Summary: CTDB not integrated into top-level Samba build
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Build (show other bugs)
Version: 4.2.0rc2
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Karolin Seeger
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-23 00:40 UTC by Martin Schwenke
Modified: 2014-11-09 19:51 UTC (History)
3 users (show)

See Also:


Attachments
Samba+CTDB unified build patches and cleanups (257.70 KB, patch)
2014-10-31 04:16 UTC, Martin Schwenke
obnox: review+
amitay: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Schwenke 2014-10-23 00:40:04 UTC
Release notes currently say:

  To build the Samba file server with cluster support, use the configure
  command line option --with-cluster-support.  This will build clustered
  file server against the in-tree ctdb.  Building clustered samba with
  previous versions of CTDB is no longer supported.

  CTDB is built separately from the ctdb/ sub-directory.  To build CTDB,
  use the following steps:

    $ cd ctdb
    $ ./configure
    $ make
    # make install

It would make sense to be able to drop the 2nd half and just add into
the first paragraph that CTDB is built too.

Patches required from master are:

  3d6675f lib/util: Clean up includes for blocking.c
  2d7dfe3 lib/util: Clean up includes for xfile.[ch]
  1f0e5cb lib/util: Clean up includes for data_blob.[ch]
  fd9f0c2 lib/util: Clean up includes for time.[ch]
  b69edfe lib/util: Clean up includes for signal.c
  2426130 lib/util: Replace an SMB_ASSERT()
  d929408 lib/util: Clean up includes for substitute.c
  8dac190 lib/util: Clean up includes for fault.c
  db15cc5 lib/util: Clean up includes for util.c
  1fd4556 lib/util: Factor out subsystem samba-util-core from samba-util
  c12aa0c lib/util: Use charset_compat.h if SAMBA_UTIL_CORE_ONLY

  b544073 ctdb-logging: Remove log ringbuffer
  1c8c0be ctdb-tests: Make the fake log timestamp string easy to modify
  3105737 ctdb-logging: Change LogLevel to DEBUGLEVEL
  b4589b9 ctdb-logging: Update to use Samba style debug.h/debug.c
  ba3e2ec ctdb-build: Move generation of ctdb_version.h earlier
  43266be ctdb-build: Add generation of Samba-style version.h
  59c3025 ctdb-build: Change from ctdb-util to samba-util
  88b2485 ctdb-build: Fix handling of public headers

  6b98ddc ctdb-build: Rename define BINDIR to CTDB_HELPER_BINDIR
  d568be6 ctdb-build: Make some steps conditional on standalone build
  e94422a build: Hook CTDB into top level build using --with-cluster-support

These currently apply cleanly to v4-2-stable and a low risk.  There
are very few actual code changes.

One extra trivial patch is required to fix a regression in file
logging (missing newline).  I'll update this bug when this patch is in
master.
Comment 1 Martin Schwenke 2014-10-29 04:31:48 UTC
The last patch is this one, which went into master overnight:

96106e0 ctdb-logging: Add missing newline when logging to file
Comment 2 Michael Adam 2014-10-29 08:08:56 UTC
There are also a few additional recent patches which complete this effort by disabling the ability to build samba against an external ctdb, in particular removing the "--enable-old-ctdb" switch to configure. I guess these should also be brought to 4.2.
Comment 3 Martin Schwenke 2014-10-31 02:51:51 UTC
These should be the patches that Michael is referring to:

  5e7ab5c build: Remove configure option --enable-old-ctdb
  18100b8 build: Remove checks for ctdb features
  9933028 build: Remove configure option --with-ctdb-dir
  0d5ecaa ctdb: Rename ctdb socket variable from CTDB_PATH to CTDB_SOCKET
  e67c4b9 build: Remove configure checks for ctdb headers
  69c0c43 build: Simplify check for building with ctdb
  a54db68 ctdb: Rename CTDB_VERSION to CTDB_PROTOCOL
  eeebbe7 autobuild: adapt samba-ctdb target does not need a separate ctdb build any more
  bf98630 build: further simplify --with-cluster-support case in configure
  a72ca5a build: adapt comments for the clustering choice
  bf07a6b autobuild: check whether ctdbd has been installed in the samba-ctdb target
Comment 4 Martin Schwenke 2014-10-31 04:16:09 UTC
Created attachment 10391 [details]
Samba+CTDB unified build patches and cleanups
Comment 5 Martin Schwenke 2014-11-05 05:38:15 UTC
Hi Karo,

This has 1 review from Amitay.  If it needs another, can you please ping Michael (i.e. obox)?

Thanks...
Comment 6 Michael Adam 2014-11-05 11:37:17 UTC
Comment on attachment 10391 [details]
Samba+CTDB unified build patches and cleanups

Martin, I don't think my review is strictly needed
if your submission is counted as implcit review (by you
as a team member). You could also have explicitly added
your review+. But here you are. The patches are good.

Michael
Comment 7 Karolin Seeger 2014-11-07 19:29:11 UTC
Pushed to autobuild-v4-2-test.
Comment 8 Karolin Seeger 2014-11-09 19:51:22 UTC
Pushed to v4-2-test.
Closing out bug report.

Thanks!