Nizamudeen A [Thu, 18 Nov 2021 07:13:39 +0000 (12:43 +0530)]
mgr/dashboard: fix flaky inventory e2e test
When `inventory.getTableCount('total').should('be.eq', totalDiskCount);`
this line is executed the table was not loaded properly and hence the
getTableCount returns 0 on the first try but on second try it passes
since the table is loaded. But in orch e2es the retries are set to 0. I
am not sure if it makes sense to set it to 1. Anyway I am adapting the
test a bit to expect the count to be equal to totalDiskCount so that the
test will wait a bit.
Fixes: https://tracker.ceph.com/issues/53353 Signed-off-by: Nizamudeen A <nia@redhat.com>
myoungwon oh [Wed, 3 Nov 2021 07:27:03 +0000 (16:27 +0900)]
seastore: generalize paddr_t
Due to necessity to support both segment and rbm addrs,
paddr_t needs to be generlized.
To do so, this commits introduces seg_paddr_t---
seg_paddr_t inherits paddr_t, and deals with common_addr
according to the semantic of segment.
Soumya Koduri [Wed, 23 Jun 2021 18:00:11 +0000 (23:30 +0530)]
rgw/CloudTransition: Replace Coroutines with RGWRestConn APIs
To avoid the overhead of using coroutines during lifecycle transition,
RGWRESTStream* APIs are used to transition objects to remote cloud.
Also handled few optimizations and cleanup stated below:
* Store the list of cloud target buckets as part of LCWorker instead
of making it global. This list is maintained for the duration of
RGWLC::process(), post which discarded.
* Refactor code to remove coroutine based class definitions which are no
longer needed and use direct function calls instead.
* Check for cloud transitioned objects using tier-type and return error if
accessed in RGWGetObj, RGWCopyObj and RGWPutObj ops.
Soumya Koduri [Wed, 17 Mar 2021 21:12:54 +0000 (02:42 +0530)]
rgw/CloudTransition: Handle versioned objects
For versioned and locked objects, similar semantics as that of LifecycleExpiration are applied as stated below -
If the bucket versioning is enabled and the object transitioned to cloud is
- current version, irrespective of what the config option "retain_object" value is, the object is not deleted but instead delete marker is created on the source rgw server.
- noncurrent version, it is deleted or retained based on the config option "retain_object" value.
If the object is locked, and is
- current version, it is transitioned to cloud post which it is made noncurrent with delete marker created.
- noncurrent version, transition is skipped.
Also misc rebase fixes and cleanup -
* Rename config option to "retain_head_object"
to reflect its functionality to keep head object post transitioning
to cloud if enabled
Soumya Koduri [Sun, 7 Mar 2021 14:14:36 +0000 (19:44 +0530)]
rgw/CloudTransition: Skip transition to cloud if the object is locked
If an object is locked, skip its transition to cloud.
@todo: Do we need special checks for bucket versioning too?
If current, instead of deleting the data, do we need to create
a delete marker? What about the case if retain_object is set to true.
Soumya Koduri [Fri, 26 Feb 2021 16:48:52 +0000 (22:18 +0530)]
rgw/CloudTransition: Change tier-type to cloud-s3
Currently the transition is supported to cloud providers
that are compatible with AWS/S3. Hence change the tier-type to
cloud-s3 to configure the S3 style endpoint details.
Soumya Koduri [Wed, 4 Nov 2020 18:24:47 +0000 (23:54 +0530)]
rgw/CloudTransition: Fail GET on cloud tiered objects
As per https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html
GET operation may fail with “InvalidObjectStateError” error if the
object is in GLACIER or DEEP_ARCHIVE storage class and not restored.
Same can apply for cloud tiered objects. However STAT/HEAD requests
shall return the metadata stored.
Soumya Koduri [Sun, 16 Aug 2020 09:01:50 +0000 (14:31 +0530)]
rgw/CloudTransition: Verify if the object is already tiered
Add class to fetch headers from remote endpoint and verify if the object
is already tiered.
& Few other fixes stated below -
* Erase data in the head of cloud transitioned object
* 'placement rm' command should erase tier_config details
* A new option added in the object manifest to denote if the
object is tiered in multiparts
Soumya Koduri [Tue, 18 Aug 2020 07:02:22 +0000 (12:32 +0530)]
rgw/CloudTransition: Store the status of multipart uploads
Store the status of multipart upload parts to verify if the object
hasn't changed during the transition and if yes, abort the upload.
Also avoid re-creating target buckets -
Its not ideal to try creating target bucket for every object
transition to cloud. To avoid it caching the bucket creations in
a map with an expiry period set to '2*lc_debug_interval' for each
entry.
Soumya Koduri [Sun, 2 Aug 2020 19:54:19 +0000 (01:24 +0530)]
rgw/CloudTransition: Delete cloud tiered objects by default
Added a new option "retain_object" in tier_config which determines
whether a cloud tiered object is deleted or if its head object is
retained. By default the value is false i.e, the objects get
deleted.
XXX: verify that if Object is locked (ATTR_RETENTION), transition is
not processed. Also check if the transition takes place separately for
each version.
rgw/CloudTransition: Update object metadata and bi post cloud tranistion
After transitioning the object to cloud, following updates are done
to the existing object.
* In bi entry, change object category to CloudTiered
* Update cloud-tier details (like endpoint, keys etc) in Object Manifest
* Mark the tail objects expired to be deleted by gc
TODO:
* Update all the cloud config details including multiparts
* Check if any other object metadata needs to be changed
* Optimize to avoid using read_op again to read attrs.
* Check for mtime to resolve conflicts when multiple zones try to transition obj
Soumya Koduri [Wed, 23 Dec 2020 05:44:53 +0000 (11:14 +0530)]
rgw/CloudTransition: Tier objects to remote cloud
If the storage class configured is of cloud, transition
the objects to remote endpoint configured.
In case the object size is >mulitpart size limit (say 5M),
upload the object into multiparts.
As part of transition, map rgw attributes to http attrs,
including ACLs.
A new attribute (x-amz-meta-source: rgw) is added to denote
that the object is transitioned from RGW source.
Added two new options to tier-config to configure multipart size -
* multipart_sync_threshold - determines the limit of object size,
when exceeded transitioned in multiparts
* multipart_min_part_size - the minimum size of the multipart upload part
Default values for both the options is 32M and minimum value supported
is 5M.
rgw/CloudTransition: Add new options to configure tier endpoint
As mentioned in https://docs.google.com/document/d/1IoeITPCF64A5W-UA-9Y3Vp2oSfz3xVQHu31GTu3u3Ug/edit,
the tier storage class will be configured at zonegroup level.
So the existing CLI "radosgw-admin zonegroup placement add <id> --storage-class <class>" will be
used to add tier storage classes as well but with extra tier-config options mentioned below -
chunmei-liu [Wed, 17 Nov 2021 04:40:09 +0000 (20:40 -0800)]
crimson: add delay for peering_event start when nested
Delay the second (nested) peerevent::start to let the first finish.
Then avoid interruptor nesting which will cause local interrupt_cond
not equal global interrupt_cond.
Adam Kupczyk [Sat, 13 Nov 2021 10:28:18 +0000 (11:28 +0100)]
os/bluestore: Fix omap upgrade to per-pg scheme
This is fix to regression introduced by fix to omap upgrade: https://github.com/ceph/ceph/pull/43687
The problem was that we always skipped first omap entry.
This worked fine with objects having omap header key.
For objects without header key we skipped first actual omap key.
Fixes: https://tracker.ceph.com/issues/53260 Signed-off-by: Adam Kupczyk <akupczyk@redhat.com>
Alfonso Martínez [Wed, 17 Nov 2021 12:18:26 +0000 (13:18 +0100)]
mgr/dashboard: NFS non-existent files cleanup
After https://github.com/ceph/ceph/pull/42526 and https://github.com/ceph/ceph/pull/43725 merges,
the following files do not exist but there were still references to them:
- src/pybind/mgr/dashboard/services/ganesha.py
- qa/tasks/mgr/dashboard/test_ganesha.py
The following files were renamed but there were still references to old names:
- src/pybind/mgr/dashboard/controllers/nfsganesha.py: nfsganesha.py --> nfs.py
- src/pybind/mgr/dashboard/tests/test_ganesha.py: test_ganesha.py --> test_nfs.py
Other changes in qa/suites/rados/dashboard/tasks/dashboard.yaml:
- Add missing task: tasks.mgr.dashboard.test_api
- Sort dashboard tasks alphabetically.
Fixes: https://tracker.ceph.com/issues/53123 Signed-off-by: Alfonso Martínez <almartin@redhat.com>