Skip to content

Instantly share code, notes, and snippets.

with libc

build with libc allocator, and with the boost context lib support for valgrind:

cmake -DALLOCATOR=libc -DWITH_BOOST_VALGRIND=ON ..

run vstart cluster:

MON=1 OSD=1 MDS=0 MGR=0 RGW=1 ../src/vstart.sh -n -d

kill the radosgw and rerun it under valgrind:

setup

setup 2 clusters:

MON=1 OSD=1 MDS=0 MGR=1 ../src/test/rgw/test-rgw-multisite.sh 2

using hsbench create a bucket on cluster 1:

hsbench -a 1234567890 -s pencil -u http://localhost:8001 -bp my-bucket -b 1 -r zg1 -m i

reshard after sync

setup 2 clusters:

MON=1 OSD=1 MDS=0 MGR=1 RGW=1 ../src/test/rgw/test-rgw-multisite.sh 2

using hsbench create a bucket on cluster 1:

hsbench -a 1234567890 -s pencil -u http://localhost:8001 -bp my-bucket -b 1 -r zg1 -m i

get bucket stats on both clusters:

@yuvalif
yuvalif / wannacry.sh
Created November 10, 2021 09:11
not really :-) just a simple script to encrypt all files in a directory
#!/bin/bash
if [ "$#" -ne 2 ]; then
echo "Usage: $0 <source dir> <destination dir>"
exit 1
fi
SRC_DIR=$1
DST_DIR=$2
@yuvalif
yuvalif / entropy.lua
Created November 10, 2021 06:28
script to calculate the byte entropy of a directory
require "lfs"
-- calculate entropy of a file
function calculate_entropy(filename)
local file = assert(io.open(filename, 'rb'))
local page_size = 4*1024
local byte_hist = {}
local byte_hist_size = 256
for i = 1,byte_hist_size do

Goal

This is list TODOs for the bucket notification PR in Rook. Based on these comments:

Priority 1

Refactoring and Unit Tests

  • code reuse with reused function (and unit test for above reused function)
  • use the regular S3 agent for notification provisioning (topic will still need the special SNS client)

Introduction

Both the RGW and the OSD will be using the opentelemtry client to send traces to jaeger. Other Ceph components may be using jaeger as well in the future.

When Ceph is deployed via Rook, we would expect the Rook operator to:

  • documwent installation of the jaeger operator. installation of the jaeger operator itself, and othe rdependencies (e.g. elasticsearch) will not be done as part of Rook
  • add parameters to the CephCluster spec called "tracing" that would indicate the Rook operator to deploy a Jaeger CR. more specific parameters should go under "tracing"

note that this should follow the deployment requirement that we have for monmitoring with Prometheus

this is based on the following PR as a prerequisite, setup 2 zones multisite setup:

MON=1 OSD=1 MDS=0 MGR=0 ../src/test/rgw/test-rgw-multisite.sh 

to use the AWS CLI tool, following env variables should be set:

 export AWS_ACCESS_KEY_ID=1234567890
 export AWS_SECRET_ACCESS_KEY=pencil
set -ex
# delete the minikube VM
minikube delete
rm -rf ~/.minikube
# start the minikube VM with 3 disks
minikube start --cpus 8 --vm-driver=kvm2 --extra-disks=3 --disk-size=20G
# make sure that sdb/c are there

docker rate limit is causing issues in lab/cloud machines, since many of them share the same external IP. possible workaround is to move the image to quay. for example the rabbitmq:3.8.21-management needed for the rabbitmq k8s operator.

from a laptop or local machine, pull the image, retag it, and push to quay:

podman pull docker.io/library/rabbitmq:3.8.21-management
podman tag rabbitmq:3.8.21-management quay.io/ylifshit/rabbitmq:3.8.21-management
podman push quay.io/ylifshit/rabbitmq:3.8.21-management