[pkg-bacula-devel] Contribution

Sven Hartge sven at svenhartge.de
Mon Sep 14 21:46:30 BST 2020


Um 22:27 Uhr am 14.09.20 schrieb Mario Pranjic:
> On 9/14/20 9:16 PM, Sven Hartge wrote:

>> libs3 originates from https://github.com/bji/libs3 and is a third party
>> library for Amazon S3 acccess. Bacula Systems originally used the libs3
>> git HEAD version from December 2016 when then developed the (then)
>> proprietary cloud driver for Bacula Enterprise.
>>
>> 3 years later the cloud driver is fully open-sourced and integrated into
>> the Bacula community version.
>>
>> It was soon discovered that libs3 is a bit of a mess, because it never
>> really got a stable API and even slightly different versions are
>> incompatible with each other, making using and packaging it very
>> difficult. In addition to that the last offical release of libs3 was in
>> 2011, which is the version currently in Debian.
>>
>> Unfortunately libs3 is very much abandoned by its authors and does not
>> even compile without errors with anything newer than GCC8 without heavy
>> patching. (And my personal opinion is that libs3 is a security breach
>> wating to happen.)
 
> Hm. What you just wrote is disturbing.
> I was led to believe that Bacula Enterprise from time to time makes
> parts of code, such as drivers, available to community version.

That is still the case. Bacula Enterprise is something people called "open
core licensed". Bacula itself is licensed under the AGPL license and fully
open source.

Bacula Systems SA or Kern Sibbald will port code from the Enterprise
version to the community version after some time has passed.

> But, point being, if Bacula Enterprise have a working driver for
> multiple cloud  providers, while we here sit with 2011 code not even
> maintained, it is a good question indeed why would we pack it in the
> first place.

As I said, libs3 is completely external to Bacula and has nothing to do
with Bacula. The Author of libs3 just made the last proper release in 2011
and after that you only get the "moving goalpost" that is the git HEAD.

Packaging such a moving target with a constantly chaning API (and thus
ABI) is difficult of not impossible.

Side note: During my first tests with packaging the cloud-driver from
Bacula I discovered that libs3 changed its API multiple times in the past
without the SONAME being changed. Which is ... really bad and more or less
breaks the justificaton for it being a shared library in the first place.

(Most projects I can find in the Internet seem to either use the official
Amazon SDK for S3 access or are implemented in a different language,
mostly Go.)

Concerning the Enterprise version supporting more than one S3 provider: As
far as I know (please don't quote me on that), Bacula Systems have
redeveloped the cloud/S3 integration in the Enterprise version. That
change has not yet landed in the community edition.

>> The only possibility of getting Baculas own libs3-fork into Debian is by
>> making it a private library, in contrast to the public system library you
>> created above.
>>
>> Which means
>>
>> 1) installing into /usr/lib/bacula and /usr/include/bacula
>> 2) changing the library name from libs3 to something different so the
>> dynamic linker does not get confused
>>
>> or
>>
>> 2) changing it to a static library that is linked into the cloud-driver at
>> compile time.
 
> Fully understandable.
> In fact, I am surprised why is that driver called only "s3", but I
> guess, that goes to not being properly maintained over time.

I think you misunderstood what libs3 is, see below.

>> Please explain.

> Well. If cloud driver is related to Bacula ans Bacula alone, I find it
> very weird  - you build it for Bacula and then the output is not even
> called as Bacula expect it to be called.

libs3 is a generic library external to Bacula, just like libcurl or
libzstd.
 
> If, on the other hand, this cloud driver is actually "general purpose"
> piece of code to communicate with AWS S3 bucket and it suppose to be
> used by Bacula "as is", then it makes more sense.

Only the cloud-driver is Bacula code that just uses libs3. libs3 is *not*
the cloud-driver per se.

Grüße,
Sven.



More information about the pkg-bacula-devel mailing list