Commit Graph

1444 Commits

Author SHA1 Message Date
Ernesto Puerta
b0085bf224
mgr/{restful,zabbix}: document removal
Fixes: https://tracker.ceph.com/issues/47066
Signed-off-by: Ernesto Puerta <epuertat@redhat.com>
2024-10-28 14:17:19 +01:00
Ernesto Puerta
8ccb634804
mgr/zabbix: remove deprecated module
This (already deprecated) module is removed as a side-effect of the
deprecation and removal of the `restful` module.

Fixes: https://tracker.ceph.com/issues/47066
Signed-off-by: Ernesto Puerta <epuertat@redhat.com>
2024-10-28 14:17:19 +01:00
Ernesto Puerta
96ec7badb8
mgr/restful: remove deprecated module
Detailed changes:
* Remove `restful` mgr module dir,
* Remove Python depedencies (`pecan`, `werkzeug`) from ceph.spec and
  debian control,
* Remove docs,
* Remove associated QA tests,
* Update vstart.

Fixes: https://tracker.ceph.com/issues/47066
Signed-off-by: Ernesto Puerta <epuertat@redhat.com>
2024-10-28 14:17:18 +01:00
Effi Ofer
dc8eed68ce librbd/migration: add nbd stream
Co-authored-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Effi Ofer <effio@il.ibm.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2024-09-06 14:14:12 +02:00
Kefu Chai
729fd8e25f ceph-volume: add "packaging" to install_requires
in 0985e201, "packaging" was introduced as a runtime dependency of
ceph-volume, and `ceph.spec.in` was updated accordingly to note
this new dependency. but the debian packaging was not updated.

in 80edcd40, the missing dependency was added to debian/control as
one of ceph-volume's runtime dependency.

but dh_python3 is able to figure out the dependencies by reading
the egg's metadata of the ceph-volume python module. and as a
python project, ceph-volume is using its `setup.py` for
tracking its dependencies.

so in order to be more consistent, and keep all of its dependencies
in one place, let's move this dependency to setup.py . as the
packagings in both distros are able to figure the dependencies
from egg-info.

see also
- https://manpages.debian.org/testing/dh-python/dh_python3.1.en.html#dependencies
- https://docs.fedoraproject.org/en-US/packaging-guidelines/Python_201x/#_automatically_generated_dependencies

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-08-14 07:04:00 +08:00
Thomas Lamprecht
80edcd40e8 debian pkg: record python3-packaging dependency for ceph-volume
Since commit 0985e20134 ("ceph-volume: use 'no workqueue' options
with dmcrypt") the python "packaging" module is used to parse the
cryptsetup version output, but the debian packaging was not updated to
record that new dependency.

So simply record this in the d/control file, adding a <pkg>.requires
file seemed to not really winning us anything here.

Fixes: https://tracker.ceph.com/issues/67290
Fixes: 0985e20134
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2024-07-31 10:44:58 +02:00
Kefu Chai
85d4bc8c81
Merge pull request #55917 from Aequitosh/fix-ceph-crash-permissions
debian: recursively adjust permissions of /var/lib/ceph/crash

Reviewed-by: Pere Diaz Bou <pdiazbou@redhat.com>
Reviewed-by: Kefu Chai <tchaikov@gmail.com>
2024-07-08 19:57:38 +08:00
Sungmin Lee
679d09b241 debian: add ceph-dedup-daemon to the ceph-test package
When running test-dedup-tool.sh on Ubuntu, the binary for ceph-dedup-daemon
is not installed, resulting in the failure of test_sample_dedup due to its
exclusion from ceph-test debian package.

To fix this issue, this commit includes the ceph-dedup-daemon in ceph-test debian
package.

Fixes: https://tracker.ceph.com/issues/66368

Signed-off-by: Sungmin Lee <sung_min.lee@samsung.com>
2024-06-19 00:49:44 +00:00
Kefu Chai
0370256bf0
Merge pull request #57812 from tchaikov/wip-drop-setuptools
ceph.spec.in: remove setuptools dependency

Reviewed-by: Matan Breizman <mbreizma@redhat.com>
2024-06-05 13:38:22 +08:00
Kefu Chai
6c76fb28f7 ceph.spec.in: remove setuptools dependency
in 844b66de, we stopped using pkg_resources for import packaging.
and the exact reason why we introduced pkg_resources was for using
the packaging python module, see cf608920.

so, let's partially revert cf608920.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-06-02 16:55:29 +08:00
Kefu Chai
53f992810a debian: package mgr/rgw in ceph-mgr-modules-core
in 110db72e, we added the rgw mgr module to ceph-mgr-modules-core
rpm package. but we didn't add this module to the corresponding
debian package.

rgw mgr module provides a simple interface to deploy RGW multisite
setup. so it would be nice to have it in ceph's debian packages as
well.

despite that rgw is not part of the core features, since this module
is already in ceph-mgr-modules-core rpm package, and it is relatively
small and does not pulling extra dependencies, let's added to the
debian packge with the same name. we can revisit this decision and
extract it out in a following up change if it is necessary in future.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-06-01 08:45:18 +08:00
Kefu Chai
844b66de41 mgr/prometheus: s/pkg_resources.packaging/packaging/
instead of relying on the internal implementation of pkg_resources,
let's import packaging directly.

in this change, we also add the dependency to the packaging module
in the packaging recipes.

See also https://github.com/pypa/setuptools/issues/4385

Fixes https://tracker.ceph.com/issues/66201
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-05-25 15:22:32 +08:00
Kefu Chai
720f8e954c
Merge pull request #55437 from tchaikov/ehh-upstart
debian: do not use upstart to start/stop services

Reviewed-by: Casey Bodley <cbodley@redhat.com>
2024-05-08 22:10:05 +08:00
Max Carrara
97a1ec4b52
debian: recursively adjust permissions of /var/lib/ceph/crash
A rather recent PR made ceph-crash run as "ceph" user instead of
root [0]. However, because /var/lib/ceph/crash/posted belongs to root,
ceph-crash cannot actually post any crash logs now.

This commit fixes this by recursively updating the permissions of
'/var/lib/ceph/crash', which ensures that all files and directories
used by 'ceph-crash.service' are actually owned by the user configured
for Ceph. This also accounts for existing installations.

Additionally, quote interpolated variables and use curly braces [1].

[0]: #48713
[1]: https://www.shellcheck.net/wiki/SC2086

Fixes: https://tracker.ceph.com/issues/64548
Signed-off-by: Max Carrara <m.carrara@proxmox.com>
2024-04-30 17:40:27 +02:00
Yuri Weinstein
bf30425f5e
Merge pull request #55409 from cybozu/add-ceph-exporter-to-deb-package
debian: add ceph-exporter package

Reviewed-by: Kefu Chai <tchaikov@gmail.com>
Reviewed-by: Avan Thakkar <athakkar@redhat.com>
Reviewed-by: Juan Miguel Olmo Martínez <jolmomar@redhat.com>
2024-03-20 08:40:57 -07:00
Dan Mick
d3f3b0784c
Merge pull request #56203 from athanatos/sjust/wip-protoc-dependencies
crimson: add crimson-osd rpm and deb runtime dependencies for protobuf inherited from seastar
2024-03-19 16:03:00 -07:00
Samuel Just
ab4c5daead debian/control: add runtime protobuf dependency for crimson-osd inherited from seastar
Signed-off-by: Samuel Just <sjust@redhat.com>
2024-03-14 13:59:45 -07:00
Nizamudeen A
2a112acd0a mgr/cephadm: mount grafana dashboards from the path
For this, the grafana dashboards are installed directly to the
containers and later, cephadm picks it up to mount the dashboards to the
grafana container

Signed-off-by: Nizamudeen A <nia@redhat.com>
2024-03-08 15:51:08 +05:30
Shinya Hayashi
32cbe079c6 systemd: add systemd unit file for ceph-exporter
Signed-off-by: Shinya Hayashi <shinya-hayashi@cybozu.co.jp>
2024-03-06 07:24:15 +00:00
Kefu Chai
080e386098 debian/control: replace <tab> with spaces
to be consistent with the rest of this file

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-22 23:35:45 +08:00
Yuri Weinstein
d74e98db3c
Merge pull request #55218 from tchaikov/debian/postinst
debian/*.postinst: add adduser as a dependency and specify --home when adduser 

Reviewed-by: Laura Flores <lflores@redhat.com>
Reviewed-by: Adam King adking@redhat.com
2024-02-20 08:10:07 -08:00
luo rixin
450f269235 debian/control: add new dependencies protobuf for crismon
As PR https://github.com/ceph/ceph/pull/55444 update seastar version,
the new seastar imports new dependencies protobuf.

Fixes: https://tracker.ceph.com/issues/64420

Signed-off-by: luo rixin <luorixin@huawei.com>
2024-02-19 17:15:58 +08:00
Shinya Hayashi
a53c0651fb debian: add ceph-exporter package
It is hard for Debian/Ubuntu users to use ceph-exporter
because it is not included in any deb packages.

This commit adds a new deb package for ceph-exporter.

Fixes: https://tracker.ceph.com/issues/64095
Signed-off-by: Shinya Hayashi <shinya-hayashi@cybozu.co.jp>
2024-02-13 01:48:22 +00:00
Kefu Chai
08fcf91bd5 debian: do not use upstart to start/stop services
we dropped the support of upstart back in 2c755cef. there is no need
to support it anymore.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-04 00:19:38 +08:00
Kefu Chai
e74ec0b27d debian/cephadm.postinst: stop using adduser --gecos
--gecos option of adduser is deprecated in debian/bookworm, and
will be removed in debian/trixie,
see https://manpages.debian.org/bookworm/adduser/adduser.8.en.html.
so to be future-proof, let's switch to `usermod --comment`. please
note, since we still need to support ubuntu/jammy which is used in
our CI, and `adduser` shipped by ubuntu/jammy does not support
`--comment` yet, so we cannot use this option.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-03 22:36:50 +08:00
Kefu Chai
013eebf535 debian/cephadm.postinst: replace tab with spaces
for better readability, and to be more consistent with the rest
of this file, and other .postinst scripts of this project.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-03 22:36:50 +08:00
Kefu Chai
90bc036924 debian/cephadm.postinst: specify --home when adduser
quote from adduser/NEWS.Debian.gz:

>  System user home defaults to /nonexistent if --home is not specified.
>  Packages that call adduser to create system accounts should explicitly
>  specify a location for /home (see Lintian check
>  maintainer-script-lacks-home-in-adduser).

so let's follow this change in adduser. otherwise "cephadm"
would have a $HOME at `/nonexistent`.

Fixes: https://tracker.ceph.com/issues/64069
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-03 22:36:50 +08:00
Kefu Chai
c517d0b0e9 debian/cephadm.postinst: wrap command line lines which is too long
for better readability.

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-03 22:36:50 +08:00
Kefu Chai
a1a857698c debian/ceph-common.postinst: set user directory using adduser
now that adduser allows us to set its home directory, we can do
this using adduser instead of using usermod. this change also
silences the warning from lintian
"maintainer-script-lacks-home-in-adduser". lintian complains if
`adduser --system` is called without passing `--home` option.

also, take this opportunity to s/-c/--comment/ in the command line
of `usermod`, for better readability.

Fixes: https://tracker.ceph.com/issues/64069
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-03 22:36:50 +08:00
Kefu Chai
2a30ddccd0 debian/control: add adduser to Depends of cephadm and ceph-common
in `debian/ceph-common.postinst` and `debian/cephadm.postinst`, we
use `adduser --system` to create the system user when configuring
the corresponding package.

before this change, the dependency is not listed in the runtime
`Depends` section of ceph-common and cephadm.

in this change, the dependency is added. this is also suggested
by Securing Debian Manual, see
https://www.debian.org/doc/manuals/securing-debian-manual/bpp-lower-privs.en.html

Signed-off-by: Kefu Chai <tchaikov@gmail.com>
2024-02-03 22:36:50 +08:00
Nizamudeen A
35e40c4e8f mgr/dashboard: adapt to new nvmeof APIs
Fixes: https://tracker.ceph.com/issues/64201
Signed-off-by: Nizamudeen A <nia@redhat.com>
2024-01-30 15:39:35 +05:30
Daniel Persson
c1ea66fe12 mgr/dashboard: Changes suggested after review by @epuertat.
Move the JWT requirement to the test requirements file. Also remove JWT from ceph specification and debian build.

Signed-off-by: Daniel Persson <mailto.woden@gmail.com>
2023-12-13 10:43:01 +01:00
Kefu Chai
e577734645
Merge pull request #53290 from ThomasLamprecht/debian-fix-ceph-mgr-requires
debian: add missing bcrypt to ceph-mgr .requires to fix resulting package dependencies

Reviewed-by: Kefu Chai <tchaikov@gmail.com>
2023-11-26 16:28:55 +08:00
Thomas Lamprecht
adc501c2ce debian: add missing bcrypt to manager .requires
The `ceph-mgr` package lost its dependency on `python3-bcrypt` when
the dependencies got moved from d/control to a dh_python3 compatible
requires file. Add it again as the bcrypt module is still used there.

Otherwise one gets errors when, e.g., calling `ceph -s` after a fresh
installation:

> 13 mgr modules have failed dependencies
> Module 'balancer' has failed dependency: No module named 'bcrypt'
> Module 'crash' has failed dependency: No module named 'bcrypt'
> Module 'devicehealth' has failed dependency: No module named 'bcrypt'
> Module 'iostat' has failed dependency: No module named 'bcrypt'
> Module 'nfs' has failed dependency: No module named 'bcrypt'
> Module 'orchestrator' has failed dependency: No module named 'bcrypt'
> Module 'pg_autoscaler' has failed dependency: No module named 'bcrypt'
> Module 'progress' has failed dependency: No module named 'bcrypt'
> Module 'rbd_support' has failed dependency: No module named 'bcrypt'
> Module 'restful' has failed dependency: No module named 'bcrypt'
> Module 'status' has failed dependency: No module named 'bcrypt'
> Module 'telemetry' has failed dependency: No module named 'bcrypt'
> Module 'volumes' has failed dependency: No module named 'bcrypt'

Fixes: https://tracker.ceph.com/issues/63637
Fixes: ef19547e83 ("debian: add .requires for specifying python3 deps")
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-11-25 12:59:55 +01:00
Yuval Lifshitz
46500cace6 rgw/test/lua: add lua integration tests suite
Signed-off-by: Yuval Lifshitz <ylifshit@redhat.com>

Fixes: https://tracker.ceph.com/issues/63616
2023-11-23 16:36:28 +00:00
Kefu Chai
cbb06d6b0b
Merge pull request #53546 from mcv21/deb_package_fixes
debian: update to dh compat 12, fix more serious packaging errors, correct copyright syntax

Reviewed-by: Kefu Chai <tchaikov@gmail.com>
2023-09-23 13:43:12 +08:00
Matthew Vernon
e4393e574c debian: call dh_python3 for ceph-{base,common,fuse,volume}
In the cases of ceph-base, ceph-common, and ceph-fuse, this picks up
that these packages contain python scripts and adds a necessary
python3 dependency. In the case of ceph-volume it additionally parses
the requirements.txt file.

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:04 +01:00
Matthew Vernon
67abe9c49a debian: radosgw.init to installinit, remove auto_build override
Installation of init scripts properly belongs with dh_installinit, so
move the installation there.

That means we no longer need the override of dh_auto_build, which
simplifies the rules file.

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:04 +01:00
Matthew Vernon
efd469e1b1 debian: specify a dependency on python3 for cephadm
cephadm is a compressed zipapp, and dh3_python3 doesn't understand
this sort of binary file, so fails to produce the required python3
dependency. So specify this explicitly in debian/control

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:04 +01:00
Matthew Vernon
96edd84e47 debian: remove obsolete ceph-base.docs, restore dh_installdocs
debian/ceph-base.docs only referred to a README that doesn't exist, so
remove it. Because dpkg-source doesn't reflect deletions from debian/
cf the orig.tar.gz, also remove the file in dh_auto_clean.

Then do away with the removal of the empty override of dh_installdocs;
the main benefit of which here is that debian/copyright gets installed
in all of the built packages, which otherwise lack a copyright
file.

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:04 +01:00
Matthew Vernon
74188c2780 debian: correct maintainer address
This means that debian/control matches changelog entries, and that the
Maintainer address is up to date.

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:04 +01:00
Matthew Vernon
86863990ca debian: dh compat to 12, necessary init/systemd adjustments
Bring the dh compat level to 12, the most recent supported by the
oldest supported Ubuntu LTS release, 20.04. This necessitates changes
to how initscripts & systemd packaging are done.

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:04 +01:00
Matthew Vernon
842d6aed00 debian/copyright: update syntax, maintainer, add license stanzas
Update the header paragraph to link to the canonical URL for the
format, and point to dev@ceph.io as the Contact.

Also add License: stanzas to reflect the licences in use (and refer to
fuller versions in /usr/share/common-licenses/ as appropriate).

This means that packages containing this copyright file are better in
compliance with the licences concerned.

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:03 +01:00
Matthew Vernon
7ec0f6975b debian: add missing item separators in debian/control
Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:03 +01:00
Matthew Vernon
bf09f66545 debian: remove {Build-,}Depends on essential packages
Unless there's a version requirement (which there isn't here),
packages should not declare a Build-Depends: or Depends: relationship
on essential packages. Policy link:

https://www.debian.org/doc/debian-policy/ch-binary.html#dependencies

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:03 +01:00
Matthew Vernon
eaaf80725c debian: specify interpreters for ceph-mon and ceph-osd postinsts
These were previously missing. The requirement for interpreters is in
Debian policy section 10.4:
https://www.debian.org/doc/debian-policy/ch-files.html#s-scripts

Debian's packaging already adds the #! to these two postinsts. In
practice, a text executible without a #! line will likely be executed
by the calling shell, so a lot of the time we'd get away with it
unless the administrator is using an incompatible shell like tcsh.

This behaviour of shells is documented in POSIX section 1(e)(i)(b)
here:
https://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_09_01_01

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:32:03 +01:00
Matthew Vernon
c14ed9bf1b debian: Build-Depend on g++ 11 or greater
Rely on the packaging system to provide a suitable g++ of version 11
or greater, and removing the corresponding hard-coding from
debian/rules, since cmake will then find a suitable version. This
seems better than trying to hard-code a particular version in
debian/rules, and Debian package building tools like e.g. sbuild will
then do the right thing.

This enables Reef (v18.2.0) to build on Debian bookworm in a clean
chroot.

Fixes: https://tracker.ceph.com/issues/61845

Signed-off-by: Matthew Vernon <mvernon@wikimedia.org>
2023-09-22 17:31:50 +01:00
Daniel Gryniewicz
a4b19133f1
Merge pull request #52933 from dang/wip-dang-posix-driver
RGW - Add POSIX Driver

Reviewed-by: Casey Bodley <cbodley@redhat.com>
Reviewed-by: Matt Benjamin <mbenjamin@redhat.com>
2023-09-15 08:58:52 -04:00
Daniel Gryniewicz
5258bcbd73 RGW - Add POSIX Driver
This is the MVP for a driver for RGW that operates on top of a POSIX
filesystem.  It supports get, put, list, copy, multipart, external
access via the filesystem itself, and ordered bucket listings via an
LRU-based cache.

Note that this is currently a Filter, indended to run on top of dbstore.
This is because it currently doesn't have any User implementation, so it
depends on dbstore's User.  Everything else is implemented in
POSIXDriver.  Once there is a User implementation, this will become a
Store, instead of a Filter.

Commit messages from bucket listing cache:

  rgw/posixdriver: recycle lmdb database handles as required

    While LMDB workflows often do not close/return database handles,
    ours continually reuses them.  This requires us to close each
    handle (atomically) when a cache entry is recycled.

  rgw/posixdriver: don't instantiate bucket cache entries from notify events

  rgw/posixdriver: incorporate lmdb-safe for now

    The current inclusion is based on https://github.com/Martchus/lmdb-safe,
    which is actively maintained but currently has some packaging issues the
    author has agreed to accept fixes for.

    For now, skip the submodule to save time and remove an external dependency.

  rgw/posixdriver: fix listing of cached, empty bucket

    * check lmdb enumeration result in all cases and w/better style
    * add unit test for enumeration of an empty cached directory

  rgw/posixdriver: nest lmdbs in a directory under the dbroot path to avoid cleanup issues

  rgw/posixdriver: refactor for posix integration

    * Derive BucketCache types as templates on a SAL driver and SAL
      bucket pair.

    * Integrate cache fills as callbacks into SAL layer (or mock, for
      tests)

    * Renaming and cleanups

  rgw/posixdriver: add bucket cache implementation and tests

    Adds free-standing cache of buckets and object names, with
    bucket names (and listing attributes, upcoming) managed in
    a hashed set of lmdb databases, which provides ordering and
    a high-performance listing cache.

    An framework for notification on new object creation (e.g.,
    outside S3 workflow) is provided, and a Linux implementation
    using inotify.

    FindLMDB.cmake taken with attribution and license.

  rgw/posixdriver: add zpp_bits serialization (FAST)

Signed-off-by: Daniel Gryniewicz <dang@redhat.com>
Signed-off-by: Ali Maredia <amaredia@redhat.com>
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2023-09-14 12:09:40 -04:00
J. Eric Ivancich
815481c637
Merge pull request #51071 from ivancich/wip-versioned-reindex
rgw: reindex of objects in versioned buckets

Reviewed-by: Casey Bodley <cbodley@redhat.com>
2023-09-07 12:43:59 -04:00