Log: /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/logs/pitr-physical.log grep: warning: stray \ before - WARNING: version difference between client (1.33) and server (1.30) exceeds the supported minor version skew of +/-1 WARNING: version difference between client (1.33) and server (1.30) exceeds the supported minor version skew of +/-1 WARNING: version difference between client (1.33) and server (1.30) exceeds the supported minor version skew of +/-1 + main + create_infra pitr-physical-7378 + local ns=pitr-physical-7378 + [[ 1 == 1 ]] + delete_crd + desc 'get and delete old CRDs and RBAC' + set +o xtrace ----------------------------------------------------------------------------------- get and delete old CRDs and RBAC ----------------------------------------------------------------------------------- + kubectl_bin delete -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/crd.yaml --ignore-not-found --wait=false ++ mktemp + local LAST_OUT=/tmp/tmp.zOEEoRK1L0 ++ mktemp + local LAST_ERR=/tmp/tmp.rbEqKfZvP5 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl delete -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/crd.yaml --ignore-not-found --wait=false + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.zOEEoRK1L0 customresourcedefinition.apiextensions.k8s.io "perconaservermongodbbackups.psmdb.percona.com" deleted customresourcedefinition.apiextensions.k8s.io "perconaservermongodbrestores.psmdb.percona.com" deleted customresourcedefinition.apiextensions.k8s.io "perconaservermongodbs.psmdb.percona.com" deleted + cat /tmp/tmp.rbEqKfZvP5 + rm /tmp/tmp.zOEEoRK1L0 /tmp/tmp.rbEqKfZvP5 + return 0 ++ yq eval .metadata.name /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/crd.yaml ++ grep -v '\-\-\-' grep: warning: stray \ before - grep: warning: stray \ before - + for crd_name in $(yq eval '.metadata.name' "${src_dir}/deploy/crd.yaml" | grep -v '\-\-\-') + kubectl get perconaservermongodbbackups.psmdb.percona.com --all-namespaces -o wide + grep -v NAMESPACE + xargs -L 1 sh -xc 'kubectl patch perconaservermongodbbackups.psmdb.percona.com -n $0 $1 --type=merge -p "{\"metadata\":{\"finalizers\":[]}}"' + kubectl patch perconaservermongodbbackups.psmdb.percona.com -n pitr-physical-27863 backup-minio-2 --type=merge -p '{"metadata":{"finalizers":[]}}' perconaservermongodbbackup.psmdb.percona.com/backup-minio-2 patched + kubectl patch perconaservermongodbbackups.psmdb.percona.com -n pitr-physical-27863 backup-minio-3 --type=merge -p '{"metadata":{"finalizers":[]}}' perconaservermongodbbackup.psmdb.percona.com/backup-minio-3 patched + kubectl_bin wait --for=delete crd perconaservermongodbbackups.psmdb.percona.com ++ mktemp + local LAST_OUT=/tmp/tmp.0wbkz8j8hZ ++ mktemp + local LAST_ERR=/tmp/tmp.SNhDKrWckv + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl wait --for=delete crd perconaservermongodbbackups.psmdb.percona.com + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.0wbkz8j8hZ customresourcedefinition.apiextensions.k8s.io/perconaservermongodbbackups.psmdb.percona.com condition met + cat /tmp/tmp.SNhDKrWckv + rm /tmp/tmp.0wbkz8j8hZ /tmp/tmp.SNhDKrWckv + return 0 + for crd_name in $(yq eval '.metadata.name' "${src_dir}/deploy/crd.yaml" | grep -v '\-\-\-') + kubectl get perconaservermongodbrestores.psmdb.percona.com --all-namespaces -o wide + grep -v NAMESPACE + xargs -L 1 sh -xc 'kubectl patch perconaservermongodbrestores.psmdb.percona.com -n $0 $1 --type=merge -p "{\"metadata\":{\"finalizers\":[]}}"' error: the server doesn't have a resource type "perconaservermongodbrestores" + kubectl patch perconaservermongodbrestores.psmdb.percona.com -n sh --type=merge -p '{"metadata":{"finalizers":[]}}' error: the server doesn't have a resource type "perconaservermongodbrestores" + : + kubectl_bin wait --for=delete crd perconaservermongodbrestores.psmdb.percona.com ++ mktemp + local LAST_OUT=/tmp/tmp.CMNctkmVj3 ++ mktemp + local LAST_ERR=/tmp/tmp.IfEaTBqho8 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl wait --for=delete crd perconaservermongodbrestores.psmdb.percona.com + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.CMNctkmVj3 + cat /tmp/tmp.IfEaTBqho8 + rm /tmp/tmp.CMNctkmVj3 /tmp/tmp.IfEaTBqho8 + return 0 + for crd_name in $(yq eval '.metadata.name' "${src_dir}/deploy/crd.yaml" | grep -v '\-\-\-') + kubectl get perconaservermongodbs.psmdb.percona.com --all-namespaces -o wide + xargs -L 1 sh -xc 'kubectl patch perconaservermongodbs.psmdb.percona.com -n $0 $1 --type=merge -p "{\"metadata\":{\"finalizers\":[]}}"' + grep -v NAMESPACE error: the server doesn't have a resource type "perconaservermongodbs" + kubectl patch perconaservermongodbs.psmdb.percona.com -n sh --type=merge -p '{"metadata":{"finalizers":[]}}' error: the server doesn't have a resource type "perconaservermongodbs" + : + kubectl_bin wait --for=delete crd perconaservermongodbs.psmdb.percona.com ++ mktemp + local LAST_OUT=/tmp/tmp.wQiXwTnjXe ++ mktemp + local LAST_ERR=/tmp/tmp.mNvVahRRN8 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl wait --for=delete crd perconaservermongodbs.psmdb.percona.com + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.wQiXwTnjXe + cat /tmp/tmp.mNvVahRRN8 + rm /tmp/tmp.wQiXwTnjXe /tmp/tmp.mNvVahRRN8 + return 0 + local rbac_yaml=rbac.yaml + '[' -n psmdb-operator ']' + rbac_yaml=cw-rbac.yaml + kubectl_bin delete -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/cw-rbac.yaml --ignore-not-found ++ mktemp + local LAST_OUT=/tmp/tmp.IVkpGITrWt ++ mktemp + local LAST_ERR=/tmp/tmp.nHohYGNOHz + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl delete -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/cw-rbac.yaml --ignore-not-found + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.IVkpGITrWt clusterrole.rbac.authorization.k8s.io "percona-server-mongodb-operator" deleted clusterrolebinding.rbac.authorization.k8s.io "service-account-percona-server-mongodb-operator" deleted + cat /tmp/tmp.nHohYGNOHz + rm /tmp/tmp.IVkpGITrWt /tmp/tmp.nHohYGNOHz + return 0 + check_crd_for_deletion PR-1961-f6beb261 + local git_tag=PR-1961-f6beb261 ++ curl -s https://raw.githubusercontent.com/percona/percona-server-mongodb-operator/PR-1961-f6beb261/deploy/crd.yaml ++ yq eval .metadata.name ++ /usr/sbin/sed s/---//g ++ /usr/sbin/sed ':a;N;$!ba;s/\n/ /g' + for crd_name in $(curl -s https://raw.githubusercontent.com/percona/percona-server-mongodb-operator/${git_tag}/deploy/crd.yaml | yq eval '.metadata.name' | $sed 's/---//g' | $sed ':a;N;$!ba;s/\n/ /g') ++ kubectl_bin get crd/null -o 'jsonpath={.status.conditions[-1].type}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.u52GZ6W5wI +++ mktemp ++ local LAST_ERR=/tmp/tmp.k2NxNHEiLX ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get crd/null -o 'jsonpath={.status.conditions[-1].type}' ++ exit_status=1 ++ set -e ++ '[' 1 '!=' 0 -a -n 1 ']' ++ cat /tmp/tmp.u52GZ6W5wI ++ cat /tmp/tmp.k2NxNHEiLX Error from server (NotFound): customresourcedefinitions.apiextensions.k8s.io "null" not found ++ sleep 0 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get crd/null -o 'jsonpath={.status.conditions[-1].type}' ++ exit_status=1 ++ set -e ++ '[' 1 '!=' 0 -a -n 1 ']' ++ cat /tmp/tmp.u52GZ6W5wI ++ cat /tmp/tmp.k2NxNHEiLX Error from server (NotFound): customresourcedefinitions.apiextensions.k8s.io "null" not found ++ sleep 4 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get crd/null -o 'jsonpath={.status.conditions[-1].type}' ++ exit_status=1 ++ set -e ++ '[' 1 '!=' 0 -a -n 1 ']' ++ cat /tmp/tmp.u52GZ6W5wI ++ cat /tmp/tmp.k2NxNHEiLX Error from server (NotFound): customresourcedefinitions.apiextensions.k8s.io "null" not found ++ sleep 8 ++ cat /tmp/tmp.u52GZ6W5wI ++ cat /tmp/tmp.k2NxNHEiLX Error from server (NotFound): customresourcedefinitions.apiextensions.k8s.io "null" not found ++ rm /tmp/tmp.u52GZ6W5wI /tmp/tmp.k2NxNHEiLX ++ return 1 + [[ '' == \T\e\r\m\i\n\a\t\i\n\g ]] + '[' -n psmdb-operator ']' + create_namespace psmdb-operator + local namespace=psmdb-operator + local skip_clean_namespace= + [[ 1 == 1 ]] + [[ -z '' ]] + destroy_chaos_mesh ++ helm list --all-namespaces --filter chaos-mesh ++ tail -n1 ++ awk '-F ' '{print $2}' ++ sed s/NAMESPACE// + local chaos_mesh_ns= + desc 'destroy chaos-mesh' + set +o xtrace ----------------------------------------------------------------------------------- destroy chaos-mesh ----------------------------------------------------------------------------------- + '[' -n '' ']' ++ kubectl get MutatingWebhookConfiguration ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete MutatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl get ValidatingWebhookConfiguration ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl get ValidatingWebhookConfiguration ++ grep validate-auth ++ awk '{print $1}' + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl api-resources ++ grep chaos-mesh ++ awk '{print $1}' ++ kubectl get crd ++ grep chaos-mesh.org ++ awk '{print $1}' + timeout 30 kubectl delete crd error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrolebinding ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrolebinding error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrole ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrole error: resource(s) were provided, but no name was specified + : + desc 'cleaned up all old namespaces' + set +o xtrace ----------------------------------------------------------------------------------- cleaned up all old namespaces ----------------------------------------------------------------------------------- + kubectl_bin get ns + egrep -v '^kube-|^default|Terminating|psmdb-operator|openshift|^gke-|^gmp-|^NAME' + awk '{print$1}' + '[' -n '' ']' + desc 'cleaned up old namespaces psmdb-operator' + set +o xtrace ----------------------------------------------------------------------------------- + xargs kubectl delete ns cleaned up old namespaces psmdb-operator ----------------------------------------------------------------------------------- + kubectl_bin delete namespace psmdb-operator --ignore-not-found ++ mktemp ++ mktemp egrep: warning: egrep is obsolescent; using grep -E + local LAST_OUT=/tmp/tmp.1o24i9fHHG + local LAST_OUT=/tmp/tmp.ktlL9Izrde ++ mktemp ++ mktemp + local LAST_ERR=/tmp/tmp.gpFgvU0baX + local exit_status=0 + local timeout=4 ++ seq 0 2 + local LAST_ERR=/tmp/tmp.ijoTMIEcqO + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl get ns + for i in $(seq 0 2) + set +e + kubectl delete namespace psmdb-operator --ignore-not-found + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.1o24i9fHHG + cat /tmp/tmp.gpFgvU0baX + rm /tmp/tmp.1o24i9fHHG /tmp/tmp.gpFgvU0baX + return 0 namespace "pitr-physical-27863" deleted + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.ktlL9Izrde namespace "psmdb-operator" deleted + cat /tmp/tmp.ijoTMIEcqO + rm /tmp/tmp.ktlL9Izrde /tmp/tmp.ijoTMIEcqO + return 0 + kubectl_bin wait --for=delete namespace psmdb-operator ++ mktemp + local LAST_OUT=/tmp/tmp.l0bzWE1Znb ++ mktemp + local LAST_ERR=/tmp/tmp.6Fh7vYdfAg + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl wait --for=delete namespace psmdb-operator + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.l0bzWE1Znb + cat /tmp/tmp.6Fh7vYdfAg + rm /tmp/tmp.l0bzWE1Znb /tmp/tmp.6Fh7vYdfAg + return 0 + desc 'create namespace psmdb-operator' + set +o xtrace ----------------------------------------------------------------------------------- create namespace psmdb-operator ----------------------------------------------------------------------------------- + kubectl_bin create namespace psmdb-operator ++ mktemp + local LAST_OUT=/tmp/tmp.ZVMNoJcWzT ++ mktemp + local LAST_ERR=/tmp/tmp.hguyjdJMXy + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl create namespace psmdb-operator + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.ZVMNoJcWzT namespace/psmdb-operator created + cat /tmp/tmp.hguyjdJMXy + rm /tmp/tmp.ZVMNoJcWzT /tmp/tmp.hguyjdJMXy + return 0 + set_kube_ctx psmdb-operator + local namespace=psmdb-operator ++ kubectl_bin config current-context +++ mktemp ++ local LAST_OUT=/tmp/tmp.5tyx6q6J44 +++ mktemp ++ local LAST_ERR=/tmp/tmp.M9xsQh9xgE ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl config current-context ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.5tyx6q6J44 ++ cat /tmp/tmp.M9xsQh9xgE ++ rm /tmp/tmp.5tyx6q6J44 /tmp/tmp.M9xsQh9xgE ++ return 0 + kubectl_bin config set-context gke_cloud-dev-112233_us-central1-a_jen-psmdb-1961-f6beb261-6-cluster1 --namespace=psmdb-operator ++ mktemp + local LAST_OUT=/tmp/tmp.iv5Fh4lYSn ++ mktemp + local LAST_ERR=/tmp/tmp.5US9ly3805 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl config set-context gke_cloud-dev-112233_us-central1-a_jen-psmdb-1961-f6beb261-6-cluster1 --namespace=psmdb-operator + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.iv5Fh4lYSn Context "gke_cloud-dev-112233_us-central1-a_jen-psmdb-1961-f6beb261-6-cluster1" modified. + cat /tmp/tmp.5US9ly3805 + rm /tmp/tmp.iv5Fh4lYSn /tmp/tmp.5US9ly3805 + return 0 + deploy_operator + desc 'start PSMDB operator' + set +o xtrace ----------------------------------------------------------------------------------- start PSMDB operator ----------------------------------------------------------------------------------- + local cr_file + '[' -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/crd.yaml ']' + cr_file=/mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/crd.yaml + kubectl_bin apply --server-side --force-conflicts -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/crd.yaml ++ mktemp + local LAST_OUT=/tmp/tmp.sPe37jGBuO ++ mktemp + local LAST_ERR=/tmp/tmp.iVe7hiqhwR + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply --server-side --force-conflicts -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/crd.yaml + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.sPe37jGBuO customresourcedefinition.apiextensions.k8s.io/perconaservermongodbbackups.psmdb.percona.com serverside-applied customresourcedefinition.apiextensions.k8s.io/perconaservermongodbrestores.psmdb.percona.com serverside-applied customresourcedefinition.apiextensions.k8s.io/perconaservermongodbs.psmdb.percona.com serverside-applied + cat /tmp/tmp.iVe7hiqhwR + rm /tmp/tmp.sPe37jGBuO /tmp/tmp.iVe7hiqhwR + return 0 + '[' -n psmdb-operator ']' + apply_rbac cw-rbac + local operator_namespace=psmdb-operator + local rbac=cw-rbac + cat /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/cw-rbac.yaml + sed -e 's^namespace: .*^namespace: psmdb-operator^' + kubectl_bin apply -n psmdb-operator -f - ++ mktemp + local LAST_OUT=/tmp/tmp.716M3WUKHd ++ mktemp + local LAST_ERR=/tmp/tmp.bPYCXr65NX + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -n psmdb-operator -f - + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.716M3WUKHd clusterrole.rbac.authorization.k8s.io/percona-server-mongodb-operator created serviceaccount/percona-server-mongodb-operator created clusterrolebinding.rbac.authorization.k8s.io/service-account-percona-server-mongodb-operator created + cat /tmp/tmp.bPYCXr65NX + rm /tmp/tmp.716M3WUKHd /tmp/tmp.bPYCXr65NX + return 0 + yq eval ' (.spec.template.spec.containers[].image = "perconalab/percona-server-mongodb-operator:PR-1961-f6beb261") | ((.. | select(.[] == "DISABLE_TELEMETRY")) |= .value="true") | ((.. | select(.[] == "LOG_LEVEL")) |= .value="DEBUG")' /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/deploy/cw-operator.yaml + kubectl_bin apply -f - ++ mktemp + local LAST_OUT=/tmp/tmp.MCNXSfELJO ++ mktemp + local LAST_ERR=/tmp/tmp.yDtd9Jkc9n + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.MCNXSfELJO deployment.apps/percona-server-mongodb-operator created + cat /tmp/tmp.yDtd9Jkc9n + rm /tmp/tmp.MCNXSfELJO /tmp/tmp.yDtd9Jkc9n + return 0 + sleep 2 ++ get_operator_pod ++ kubectl_bin get pods --selector=name=percona-server-mongodb-operator -o 'jsonpath={.items[].metadata.name}' -n psmdb-operator +++ mktemp ++ local LAST_OUT=/tmp/tmp.ZqLWSvfWD7 +++ mktemp ++ local LAST_ERR=/tmp/tmp.C3C2x9LfGW ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=percona-server-mongodb-operator -o 'jsonpath={.items[].metadata.name}' -n psmdb-operator ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.ZqLWSvfWD7 ++ cat /tmp/tmp.C3C2x9LfGW ++ rm /tmp/tmp.ZqLWSvfWD7 /tmp/tmp.C3C2x9LfGW ++ return 0 + wait_pod percona-server-mongodb-operator-5d9dc9cbbc-ztvtp + local pod=percona-server-mongodb-operator-5d9dc9cbbc-ztvtp + set +o xtrace waiting for pod/percona-server-mongodb-operator-5d9dc9cbbc-ztvtp to be ready.OK + echo 'Print operator info from log' Print operator info from log + grep 'Manager starting up' ++ get_operator_pod ++ kubectl_bin get pods --selector=name=percona-server-mongodb-operator -o 'jsonpath={.items[].metadata.name}' -n psmdb-operator +++ mktemp ++ local LAST_OUT=/tmp/tmp.swllpG3vbW +++ mktemp ++ local LAST_ERR=/tmp/tmp.E1y55sKV7K ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=percona-server-mongodb-operator -o 'jsonpath={.items[].metadata.name}' -n psmdb-operator ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.swllpG3vbW ++ cat /tmp/tmp.E1y55sKV7K ++ rm /tmp/tmp.swllpG3vbW /tmp/tmp.E1y55sKV7K ++ return 0 + kubectl_bin logs percona-server-mongodb-operator-5d9dc9cbbc-ztvtp ++ mktemp + local LAST_OUT=/tmp/tmp.LN6ViwQ9y9 ++ mktemp + local LAST_ERR=/tmp/tmp.2EbNS0Ya1z + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl logs percona-server-mongodb-operator-5d9dc9cbbc-ztvtp + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.LN6ViwQ9y9 + cat /tmp/tmp.2EbNS0Ya1z + rm /tmp/tmp.LN6ViwQ9y9 /tmp/tmp.2EbNS0Ya1z + return 0 2025-08-14T11:38:08.975Z INFO setup Manager starting up {"gitCommit": "f6beb261109d64229faebd29fd920425a39c54e3", "gitBranch": "PR-1961-f6beb261", "buildTime": "", "goVersion": "go1.24.6", "os": "linux", "arch": "amd64"} + create_namespace pitr-physical-7378 + local namespace=pitr-physical-7378 + local skip_clean_namespace= + [[ 1 == 1 ]] + [[ -z '' ]] + destroy_chaos_mesh ++ helm list --all-namespaces --filter chaos-mesh ++ awk '-F ' '{print $2}' ++ tail -n1 ++ sed s/NAMESPACE// + local chaos_mesh_ns= + desc 'destroy chaos-mesh' + set +o xtrace ----------------------------------------------------------------------------------- destroy chaos-mesh ----------------------------------------------------------------------------------- + '[' -n '' ']' ++ kubectl get MutatingWebhookConfiguration ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete MutatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl get ValidatingWebhookConfiguration ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl get ValidatingWebhookConfiguration ++ grep validate-auth ++ awk '{print $1}' + timeout 30 kubectl delete ValidatingWebhookConfiguration error: resource(s) were provided, but no name was specified + : ++ kubectl api-resources ++ grep chaos-mesh ++ awk '{print $1}' ++ kubectl get crd ++ grep chaos-mesh.org ++ awk '{print $1}' + timeout 30 kubectl delete crd error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrolebinding ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrolebinding error: resource(s) were provided, but no name was specified + : ++ kubectl get clusterrole ++ grep chaos-mesh ++ awk '{print $1}' + timeout 30 kubectl delete clusterrole error: resource(s) were provided, but no name was specified + : + desc 'cleaned up all old namespaces' + set +o xtrace ----------------------------------------------------------------------------------- cleaned up all old namespaces ----------------------------------------------------------------------------------- + kubectl_bin get ns + egrep -v '^kube-|^default|Terminating|psmdb-operator|openshift|^gke-|^gmp-|^NAME' + awk '{print$1}' + xargs kubectl delete ns ++ mktemp + '[' -n '' ']' + desc 'cleaned up old namespaces pitr-physical-7378' + set +o xtrace ----------------------------------------------------------------------------------- cleaned up old namespaces pitr-physical-7378 ----------------------------------------------------------------------------------- + kubectl_bin delete namespace pitr-physical-7378 --ignore-not-found egrep: warning: egrep is obsolescent; using grep -E ++ mktemp + local LAST_OUT=/tmp/tmp.YcjYgYRbwU ++ mktemp + local LAST_OUT=/tmp/tmp.ghX2CJnFpD + local LAST_ERR=/tmp/tmp.sklevQG5mJ + local exit_status=0 + local timeout=4 ++ mktemp ++ seq 0 2 + for i in $(seq 0 2) + local LAST_ERR=/tmp/tmp.XxVrVXnY6c + set +e + local exit_status=0 + kubectl get ns + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl delete namespace pitr-physical-7378 --ignore-not-found + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.YcjYgYRbwU + cat /tmp/tmp.sklevQG5mJ + rm /tmp/tmp.YcjYgYRbwU /tmp/tmp.sklevQG5mJ + return 0 error: resource(s) were provided, but no name was specified + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.ghX2CJnFpD + cat /tmp/tmp.XxVrVXnY6c + rm /tmp/tmp.ghX2CJnFpD /tmp/tmp.XxVrVXnY6c + return 0 + kubectl_bin wait --for=delete namespace pitr-physical-7378 ++ mktemp + local LAST_OUT=/tmp/tmp.wLlNnBx79T ++ mktemp + local LAST_ERR=/tmp/tmp.sb9HV4C7xB + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl wait --for=delete namespace pitr-physical-7378 + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.wLlNnBx79T + cat /tmp/tmp.sb9HV4C7xB + rm /tmp/tmp.wLlNnBx79T /tmp/tmp.sb9HV4C7xB + return 0 + desc 'create namespace pitr-physical-7378' + set +o xtrace ----------------------------------------------------------------------------------- create namespace pitr-physical-7378 ----------------------------------------------------------------------------------- + kubectl_bin create namespace pitr-physical-7378 ++ mktemp + local LAST_OUT=/tmp/tmp.RbBud3HGIw ++ mktemp + local LAST_ERR=/tmp/tmp.wOA1Pp7fcF + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl create namespace pitr-physical-7378 + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.RbBud3HGIw namespace/pitr-physical-7378 created + cat /tmp/tmp.wOA1Pp7fcF + rm /tmp/tmp.RbBud3HGIw /tmp/tmp.wOA1Pp7fcF + return 0 + set_kube_ctx pitr-physical-7378 + local namespace=pitr-physical-7378 ++ kubectl_bin config current-context +++ mktemp ++ local LAST_OUT=/tmp/tmp.mSD7xLl2co +++ mktemp ++ local LAST_ERR=/tmp/tmp.AeXQFPOsaK ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl config current-context ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.mSD7xLl2co ++ cat /tmp/tmp.AeXQFPOsaK ++ rm /tmp/tmp.mSD7xLl2co /tmp/tmp.AeXQFPOsaK ++ return 0 + kubectl_bin config set-context gke_cloud-dev-112233_us-central1-a_jen-psmdb-1961-f6beb261-6-cluster1 --namespace=pitr-physical-7378 ++ mktemp + local LAST_OUT=/tmp/tmp.MZbgGwuGst ++ mktemp + local LAST_ERR=/tmp/tmp.0RxFesfewE + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl config set-context gke_cloud-dev-112233_us-central1-a_jen-psmdb-1961-f6beb261-6-cluster1 --namespace=pitr-physical-7378 + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.MZbgGwuGst Context "gke_cloud-dev-112233_us-central1-a_jen-psmdb-1961-f6beb261-6-cluster1" modified. + cat /tmp/tmp.0RxFesfewE + rm /tmp/tmp.MZbgGwuGst /tmp/tmp.0RxFesfewE + return 0 + deploy_minio + desc 'install Minio' + set +o xtrace ----------------------------------------------------------------------------------- install Minio ----------------------------------------------------------------------------------- + helm uninstall minio-service Error: uninstall: Release not loaded: minio-service: release: not found + : + helm repo remove minio "minio" has been removed from your repositories + helm repo add minio https://charts.min.io/ "minio" has been added to your repositories + retry 10 60 helm install minio-service --version 5.4.0 --set replicas=1 --set mode=standalone --set resources.requests.memory=256Mi --set rootUser=rootuser --set rootPassword=rootpass123 --set 'users[0].accessKey=some-access-key' --set 'users[0].secretKey=some-secret-key' --set 'users[0].policy=consoleAdmin' --set service.type=ClusterIP --set configPathmc=/tmp/.minio/ --set persistence.size=2G --set securityContext.enabled=false minio/minio + local max=10 + local delay=60 + shift 2 + local n=1 + helm install minio-service --version 5.4.0 --set replicas=1 --set mode=standalone --set resources.requests.memory=256Mi --set rootUser=rootuser --set rootPassword=rootpass123 --set 'users[0].accessKey=some-access-key' --set 'users[0].secretKey=some-secret-key' --set 'users[0].policy=consoleAdmin' --set service.type=ClusterIP --set configPathmc=/tmp/.minio/ --set persistence.size=2G --set securityContext.enabled=false minio/minio NAME: minio-service LAST DEPLOYED: Thu Aug 14 11:38:32 2025 NAMESPACE: pitr-physical-7378 STATUS: deployed REVISION: 1 TEST SUITE: None NOTES: MinIO can be accessed via port 9000 on the following DNS name from within your cluster: minio-service.pitr-physical-7378.cluster.local To access MinIO from localhost, run the below commands: 1. export POD_NAME=$(kubectl get pods --namespace pitr-physical-7378 -l "release=minio-service" -o jsonpath="{.items[0].metadata.name}") 2. kubectl port-forward $POD_NAME 9000 --namespace pitr-physical-7378 Read more about port forwarding here: http://kubernetes.io/docs/user-guide/kubectl/kubectl_port-forward/ You can now access MinIO server on http://localhost:9000. Follow the below steps to connect to MinIO server with mc client: 1. Download the MinIO mc client - https://min.io/docs/minio/linux/reference/minio-mc.html#quickstart 2. export MC_HOST_minio-service-local=http://$(kubectl get secret --namespace pitr-physical-7378 minio-service -o jsonpath="{.data.rootUser}" | base64 --decode):$(kubectl get secret --namespace pitr-physical-7378 minio-service -o jsonpath="{.data.rootPassword}" | base64 --decode)@localhost:9000 3. mc ls minio-service-local ++ kubectl_bin get pods --selector=release=minio-service -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.PUvWkcJd7A +++ mktemp ++ local LAST_ERR=/tmp/tmp.9kRgf7fSo0 ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=release=minio-service -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.PUvWkcJd7A ++ cat /tmp/tmp.9kRgf7fSo0 ++ rm /tmp/tmp.PUvWkcJd7A /tmp/tmp.9kRgf7fSo0 ++ return 0 + MINIO_POD=minio-service-86dfccd949-9h22w + wait_pod minio-service-86dfccd949-9h22w + local pod=minio-service-86dfccd949-9h22w + set +o xtrace waiting for pod/minio-service-86dfccd949-9h22w to be ready.OK + '[' -n psmdb-operator ']' + kubectl_bin create svc -n psmdb-operator externalname minio-service --external-name=minio-service.pitr-physical-7378.svc.cluster.local --tcp=9000 ++ mktemp + local LAST_OUT=/tmp/tmp.gGQ3VzTC6V ++ mktemp + local LAST_ERR=/tmp/tmp.Qyt3hvLsTe + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl create svc -n psmdb-operator externalname minio-service --external-name=minio-service.pitr-physical-7378.svc.cluster.local --tcp=9000 + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.gGQ3VzTC6V service/minio-service created + cat /tmp/tmp.Qyt3hvLsTe + rm /tmp/tmp.gGQ3VzTC6V /tmp/tmp.Qyt3hvLsTe + return 0 + create_minio_bucket operator-testing + local bucket=operator-testing + kubectl_bin run -i --rm aws-cli --image=perconalab/awscli --restart=Never -- bash -c 'AWS_ACCESS_KEY_ID=some-access-key AWS_SECRET_ACCESS_KEY=some-secret-key AWS_DEFAULT_REGION=us-east-1 /usr/bin/aws --endpoint-url http://minio-service:9000 s3 mb s3://operator-testing' ++ mktemp + local LAST_OUT=/tmp/tmp.ANJasr2OKD ++ mktemp + local LAST_ERR=/tmp/tmp.75ZdcuPJA4 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl run -i --rm aws-cli --image=perconalab/awscli --restart=Never -- bash -c 'AWS_ACCESS_KEY_ID=some-access-key AWS_SECRET_ACCESS_KEY=some-secret-key AWS_DEFAULT_REGION=us-east-1 /usr/bin/aws --endpoint-url http://minio-service:9000 s3 mb s3://operator-testing' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.ANJasr2OKD make_bucket: operator-testing pod "aws-cli" deleted + cat /tmp/tmp.75ZdcuPJA4 + rm /tmp/tmp.ANJasr2OKD /tmp/tmp.75ZdcuPJA4 + return 0 + desc 'create secrets and start client' + set +o xtrace ----------------------------------------------------------------------------------- create secrets and start client ----------------------------------------------------------------------------------- + kubectl_bin apply -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/conf/secrets.yml -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/conf/client.yml -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/conf/minio-secret.yml ++ mktemp + local LAST_OUT=/tmp/tmp.YR5RPqjUnG ++ mktemp + local LAST_ERR=/tmp/tmp.EwRw5CLG7t + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/conf/secrets.yml -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/conf/client.yml -f /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/conf/minio-secret.yml + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.YR5RPqjUnG secret/some-users created deployment.apps/psmdb-client created secret/minio-secret created + cat /tmp/tmp.EwRw5CLG7t + rm /tmp/tmp.YR5RPqjUnG /tmp/tmp.EwRw5CLG7t + return 0 + cluster=some-name + desc 'create first PSMDB cluster some-name' + set +o xtrace ----------------------------------------------------------------------------------- create first PSMDB cluster some-name ----------------------------------------------------------------------------------- + apply_cluster /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/some-name-rs0.yml + '[' -z '' ']' + cat_config /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/some-name-rs0.yml + kubectl_bin apply -f - + cat /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/some-name-rs0.yml ++ mktemp + yq eval '(.spec | select(.image == null)).image = "perconalab/percona-server-mongodb-operator:main-mongod7.0"' + yq eval '(.spec | select(has("pmm"))).pmm.image = "perconalab/pmm-client:dev-latest"' + yq eval '(.spec | select(has("backup"))).backup.image = "perconalab/percona-server-mongodb-operator:main-backup"' + yq eval '(.spec | select(has("initImage"))).initImage = "perconalab/percona-server-mongodb-operator:PR-1961-f6beb261"' + local LAST_OUT=/tmp/tmp.hiV9UnBBBe + yq eval '.spec.upgradeOptions.apply="Never"' ++ mktemp + local LAST_ERR=/tmp/tmp.gMxqTvGX19 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.hiV9UnBBBe perconaservermongodb.psmdb.percona.com/some-name created + cat /tmp/tmp.gMxqTvGX19 + rm /tmp/tmp.hiV9UnBBBe /tmp/tmp.gMxqTvGX19 + return 0 + desc 'check if all 3 Pods started' + set +o xtrace ----------------------------------------------------------------------------------- check if all 3 Pods started ----------------------------------------------------------------------------------- + wait_for_running some-name-rs0 3 + local name=some-name-rs0 + let last_pod=2 + local check_cluster_readyness=true + set_debug + [[ 1 == 1 ]] + set -o xtrace + local rs_name=rs0 + local cluster_name=some-name ++ seq 0 2 + for i in $(seq 0 $last_pod) + [[ 0 -eq 2 ]] + wait_pod some-name-rs0-0 + local pod=some-name-rs0-0 + set +o xtrace waiting for pod/some-name-rs0-0 to be ready......OK + for i in $(seq 0 $last_pod) + [[ 1 -eq 2 ]] + wait_pod some-name-rs0-1 + local pod=some-name-rs0-1 + set +o xtrace waiting for pod/some-name-rs0-1 to be ready.....OK + for i in $(seq 0 $last_pod) + [[ 2 -eq 2 ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].arbiter.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.HDG2g8bU5l +++ mktemp ++ local LAST_ERR=/tmp/tmp.eje26MAItc ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].arbiter.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.HDG2g8bU5l ++ cat /tmp/tmp.eje26MAItc ++ rm /tmp/tmp.HDG2g8bU5l /tmp/tmp.eje26MAItc ++ return 0 + [[ '' == \t\r\u\e ]] + wait_pod some-name-rs0-2 + local pod=some-name-rs0-2 + set +o xtrace waiting for pod/some-name-rs0-2 to be ready......OK ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].non_voting.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.MjqCKE2lGQ +++ mktemp ++ local LAST_ERR=/tmp/tmp.piFjruay0v ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].non_voting.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.MjqCKE2lGQ ++ cat /tmp/tmp.piFjruay0v ++ rm /tmp/tmp.MjqCKE2lGQ /tmp/tmp.piFjruay0v ++ return 0 + [[ '' == \t\r\u\e ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].hidden.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.sVHieXXukD +++ mktemp ++ local LAST_ERR=/tmp/tmp.Ak9yjrO38I ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].hidden.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.sVHieXXukD ++ cat /tmp/tmp.Ak9yjrO38I ++ rm /tmp/tmp.sVHieXXukD /tmp/tmp.Ak9yjrO38I ++ return 0 + [[ '' == \t\r\u\e ]] + sleep 10 + [[ true == \t\r\u\e ]] + set +x Waiting for cluster readyness........................................... + wait_for_running some-name-cfg 3 false + local name=some-name-cfg + let last_pod=2 + local check_cluster_readyness=false + set_debug + [[ 1 == 1 ]] + set -o xtrace + local rs_name=cfg + local cluster_name=some-name ++ seq 0 2 + for i in $(seq 0 $last_pod) + [[ 0 -eq 2 ]] + wait_pod some-name-cfg-0 + local pod=some-name-cfg-0 + set +o xtrace waiting for pod/some-name-cfg-0 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 1 -eq 2 ]] + wait_pod some-name-cfg-1 + local pod=some-name-cfg-1 + set +o xtrace waiting for pod/some-name-cfg-1 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 2 -eq 2 ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].arbiter.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.rVtyzthO7c +++ mktemp ++ local LAST_ERR=/tmp/tmp.FyIeWVguoT ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].arbiter.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.rVtyzthO7c ++ cat /tmp/tmp.FyIeWVguoT ++ rm /tmp/tmp.rVtyzthO7c /tmp/tmp.FyIeWVguoT ++ return 0 + [[ '' == \t\r\u\e ]] + wait_pod some-name-cfg-2 + local pod=some-name-cfg-2 + set +o xtrace waiting for pod/some-name-cfg-2 to be ready.OK ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].non_voting.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.TCsreNnsyt +++ mktemp ++ local LAST_ERR=/tmp/tmp.xmQHVG5kuP ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].non_voting.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.TCsreNnsyt ++ cat /tmp/tmp.xmQHVG5kuP ++ rm /tmp/tmp.TCsreNnsyt /tmp/tmp.xmQHVG5kuP ++ return 0 + [[ '' == \t\r\u\e ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].hidden.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.9N5kd1ZmLN +++ mktemp ++ local LAST_ERR=/tmp/tmp.FJE1JqWpnU ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].hidden.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.9N5kd1ZmLN ++ cat /tmp/tmp.FJE1JqWpnU ++ rm /tmp/tmp.9N5kd1ZmLN /tmp/tmp.FJE1JqWpnU ++ return 0 + [[ '' == \t\r\u\e ]] + sleep 10 + [[ false == \t\r\u\e ]] + sleep 10 + desc 'write data' + set +o xtrace ----------------------------------------------------------------------------------- write data ----------------------------------------------------------------------------------- + write_initial_data + desc 'create user myApp' + set +o xtrace ----------------------------------------------------------------------------------- create user myApp ----------------------------------------------------------------------------------- + run_mongos 'db.createUser({user:"myApp",pwd:"myPass",roles:[{db:"myApp",role:"readWrite"}]})' userAdmin:userAdmin123456@some-name-mongos.pitr-physical-7378 + local 'command=db.createUser({user:"myApp",pwd:"myPass",roles:[{db:"myApp",role:"readWrite"}]})' + local uri=userAdmin:userAdmin123456@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo ++ echo .svc.cluster.local ++ awk -F: '{print $2}' + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.uF79r8RU2b +++ mktemp ++ local LAST_ERR=/tmp/tmp.AWjYN158fd ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.uF79r8RU2b ++ cat /tmp/tmp.AWjYN158fd ++ rm /tmp/tmp.uF79r8RU2b /tmp/tmp.AWjYN158fd ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''db.createUser({user:"myApp",pwd:"myPass",roles:[{db:"myApp",role:"readWrite"}]})\n'\'' | mongo mongodb://userAdmin:userAdmin123456@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.A238VdKFhl ++ mktemp + local LAST_ERR=/tmp/tmp.zVsyG2zVG5 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''db.createUser({user:"myApp",pwd:"myPass",roles:[{db:"myApp",role:"readWrite"}]})\n'\'' | mongo mongodb://userAdmin:userAdmin123456@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.A238VdKFhl Percona Server for MongoDB shell version v4.4.29-28 connecting to: mongodb://some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin?compressors=disabled&gssapiServiceName=mongodb Implicit session: session { "id" : UUID("074d785e-7307-49ee-b62b-bd512c32f5a4") } Percona Server for MongoDB server version: v7.0.22-12 WARNING: shell and server versions do not match Successfully added user: { "user" : "myApp", "roles" : [ { "db" : "myApp", "role" : "readWrite" } ] } bye + cat /tmp/tmp.zVsyG2zVG5 + rm /tmp/tmp.A238VdKFhl /tmp/tmp.zVsyG2zVG5 + return 0 + sleep 2 + write_document + local cmp_postfix= + local sleep_value=0 + log 'write initial data, read from all' + set +o xtrace [2025-08-14T11:42:48+0000] write initial data, read from all + run_mongos 'use myApp\n db.test.insert({ x: 100500 })' myApp:myPass@some-name-mongos.pitr-physical-7378 + local 'command=use myApp\n db.test.insert({ x: 100500 })' + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo ++ echo .svc.cluster.local ++ awk -F: '{print $2}' + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.CCfRz74WXI +++ mktemp ++ local LAST_ERR=/tmp/tmp.OuyQFSYOWa ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.CCfRz74WXI ++ cat /tmp/tmp.OuyQFSYOWa ++ rm /tmp/tmp.CCfRz74WXI /tmp/tmp.OuyQFSYOWa ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100500 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.dswG8rcPwa ++ mktemp + local LAST_ERR=/tmp/tmp.vfjSquCvao + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100500 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.dswG8rcPwa Percona Server for MongoDB shell version v4.4.29-28 connecting to: mongodb://some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin?compressors=disabled&gssapiServiceName=mongodb Implicit session: session { "id" : UUID("51231546-4ee4-44d5-b904-8e4fc95a49da") } Percona Server for MongoDB server version: v7.0.22-12 WARNING: shell and server versions do not match switched to db myApp WriteResult({ "nInserted" : 1 }) bye + cat /tmp/tmp.vfjSquCvao + rm /tmp/tmp.dswG8rcPwa /tmp/tmp.vfjSquCvao + return 0 + sleep 0 + compare_mongos_cmd find myApp:myPass@some-name-mongos.pitr-physical-7378 + local command=find + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local postfix= + local suffix= + local database=myApp + local collection=test + local port=27017 + run_mongos 'use myApp\n db.test.find()' myApp:myPass@some-name-mongos.pitr-physical-7378 mongodb '' '' 27017 + local 'command=use myApp\n db.test.find()' + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo + egrep -v 'I NETWORK|W NETWORK|Error saving history file|Percona Server for MongoDB|connecting to:|Unable to reach primary for set|Implicit session:|versions do not match|Error saving history file:' + /usr/sbin/sed -re 's/ObjectId\("[0-9a-f]+"\)//; s/-[0-9]+.svc/-xxx.svc/' ++ echo .svc.cluster.local ++ awk -F: '{print $2}' egrep: warning: egrep is obsolescent; using grep -E + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.7VUVME1U3w +++ mktemp ++ local LAST_ERR=/tmp/tmp.r7YMXPp5PH ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.7VUVME1U3w ++ cat /tmp/tmp.r7YMXPp5PH ++ rm /tmp/tmp.7VUVME1U3w /tmp/tmp.r7YMXPp5PH ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.find()\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.g1O2KH0ypx ++ mktemp + local LAST_ERR=/tmp/tmp.sG2XeDmetb + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.find()\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.g1O2KH0ypx + cat /tmp/tmp.sG2XeDmetb + rm /tmp/tmp.g1O2KH0ypx /tmp/tmp.sG2XeDmetb + return 0 + [[ 0 -eq 0 ]] + diff /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/compare/find.json /tmp/tmp.kqz0hqOubJ/find + desc 'wait for pbm agents to start' + set +o xtrace ----------------------------------------------------------------------------------- wait for pbm agents to start ----------------------------------------------------------------------------------- + wait_backup_agent some-name-rs0-0 + local agent_pod=some-name-rs0-0 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs0-0...2025-08-14T11:42:20.000+0000 I listening for the commands + wait_backup_agent some-name-rs0-1 + local agent_pod=some-name-rs0-1 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs0-1...2025-08-14T11:42:22.000+0000 I listening for the commands + wait_backup_agent some-name-rs0-2 + local agent_pod=some-name-rs0-2 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs0-2...2025-08-14T11:42:19.000+0000 I listening for the commands + wait_backup_agent some-name-rs1-0 + local agent_pod=some-name-rs1-0 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs1-0...2025-08-14T11:42:20.000+0000 I listening for the commands + wait_backup_agent some-name-rs1-1 + local agent_pod=some-name-rs1-1 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs1-1...2025-08-14T11:42:20.000+0000 I listening for the commands + wait_backup_agent some-name-rs1-2 + local agent_pod=some-name-rs1-2 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs1-2...2025-08-14T11:42:24.000+0000 I listening for the commands + wait_backup_agent some-name-rs2-0 + local agent_pod=some-name-rs2-0 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs2-0...2025-08-14T11:42:21.000+0000 I listening for the commands + wait_backup_agent some-name-rs2-1 + local agent_pod=some-name-rs2-1 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs2-1...2025-08-14T11:42:20.000+0000 I listening for the commands + wait_backup_agent some-name-rs2-2 + local agent_pod=some-name-rs2-2 + set +o xtrace waiting for pbm-agent to be ready in some-name-rs2-2...2025-08-14T11:42:25.000+0000 I listening for the commands + log 'Sleeping for 360 seconds to avoid PBM-1265' + set +o xtrace [2025-08-14T11:43:07+0000] Sleeping for 360 seconds to avoid PBM-1265 + sleep 360 + backup_name_minio=backup-minio + run_backup backup-minio 2 physical + local name=backup-minio + local idx=2 + local type=physical + desc 'run backup backup-minio-2' + set +o xtrace ----------------------------------------------------------------------------------- run backup backup-minio-2 ----------------------------------------------------------------------------------- + cat /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/backup-minio.yml + /usr/sbin/sed -e 's/name:/name: backup-minio-2/' + /usr/sbin/sed -e 's/type:/type: physical/' + kubectl_bin apply -f - ++ mktemp + local LAST_OUT=/tmp/tmp.3awK0hhSH3 ++ mktemp + local LAST_ERR=/tmp/tmp.TMtQuPUz1q + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.3awK0hhSH3 perconaservermongodbbackup.psmdb.percona.com/backup-minio-2 created + cat /tmp/tmp.TMtQuPUz1q + rm /tmp/tmp.3awK0hhSH3 /tmp/tmp.TMtQuPUz1q + return 0 + wait_backup backup-minio-2 + local backup_name=backup-minio-2 + local target_state=ready + set +o xtrace waiting for backup-minio-2 to reach ready state...... + sleep 5 + write_document -2nd 130 + local cmp_postfix=-2nd + local sleep_value=130 + log 'write initial data, read from all' + set +o xtrace [2025-08-14T11:49:27+0000] write initial data, read from all + run_mongos 'use myApp\n db.test.insert({ x: 100500 })' myApp:myPass@some-name-mongos.pitr-physical-7378 + local 'command=use myApp\n db.test.insert({ x: 100500 })' + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo ++ echo .svc.cluster.local ++ awk -F: '{print $2}' + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.7mwqxJxYnR +++ mktemp ++ local LAST_ERR=/tmp/tmp.TM1IFs23UC ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.7mwqxJxYnR ++ cat /tmp/tmp.TM1IFs23UC ++ rm /tmp/tmp.7mwqxJxYnR /tmp/tmp.TM1IFs23UC ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100500 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.xku0Re431J ++ mktemp + local LAST_ERR=/tmp/tmp.QRbCFPcHxN + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100500 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.xku0Re431J Percona Server for MongoDB shell version v4.4.29-28 connecting to: mongodb://some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin?compressors=disabled&gssapiServiceName=mongodb Implicit session: session { "id" : UUID("87289ddf-22e8-4cd2-887a-7264471acb1f") } Percona Server for MongoDB server version: v7.0.22-12 WARNING: shell and server versions do not match switched to db myApp WriteResult({ "nInserted" : 1 }) bye + cat /tmp/tmp.QRbCFPcHxN + rm /tmp/tmp.xku0Re431J /tmp/tmp.QRbCFPcHxN + return 0 + sleep 130 + compare_mongos_cmd find myApp:myPass@some-name-mongos.pitr-physical-7378 -2nd + local command=find + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local postfix=-2nd + local suffix= + local database=myApp + local collection=test + local port=27017 + run_mongos 'use myApp\n db.test.find()' myApp:myPass@some-name-mongos.pitr-physical-7378 mongodb '' '' 27017 + local 'command=use myApp\n db.test.find()' + egrep -v 'I NETWORK|W NETWORK|Error saving history file|Percona Server for MongoDB|connecting to:|Unable to reach primary for set|Implicit session:|versions do not match|Error saving history file:' + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo ++ echo .svc.cluster.local + /usr/sbin/sed -re 's/ObjectId\("[0-9a-f]+"\)//; s/-[0-9]+.svc/-xxx.svc/' ++ awk -F: '{print $2}' egrep: warning: egrep is obsolescent; using grep -E + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.yO7k0JYKw6 +++ mktemp ++ local LAST_ERR=/tmp/tmp.bc4TUfY1g0 ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.yO7k0JYKw6 ++ cat /tmp/tmp.bc4TUfY1g0 ++ rm /tmp/tmp.yO7k0JYKw6 /tmp/tmp.bc4TUfY1g0 ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.find()\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.iLRi6Ae86b ++ mktemp + local LAST_ERR=/tmp/tmp.r7jB8M26Tq + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.find()\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.iLRi6Ae86b + cat /tmp/tmp.r7jB8M26Tq + rm /tmp/tmp.iLRi6Ae86b /tmp/tmp.r7jB8M26Tq + return 0 + [[ 0 -eq 0 ]] + diff /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/compare/find-2nd.json /tmp/tmp.kqz0hqOubJ/find-2nd ++ date +%s + last_write=1755172302 ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.th4R2q9sX2 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.wvVyiItBn6 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.th4R2q9sX2 +++ cat /tmp/tmp.wvVyiItBn6 +++ rm /tmp/tmp.th4R2q9sX2 /tmp/tmp.wvVyiItBn6 +++ return 0 ++ echo null + last_chunk=null + log 'last write: 1755172302' + set +o xtrace [2025-08-14T11:51:44+0000] last write: 1755172302 + log 'last chunk: null' + set +o xtrace [2025-08-14T11:51:44+0000] last chunk: null + retries=0 + [[ null -gt 1755172302 ]] + [[ 0 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.qtwqa9Xsu2 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.3A2eIfLU0p +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.qtwqa9Xsu2 +++ cat /tmp/tmp.3A2eIfLU0p +++ rm /tmp/tmp.qtwqa9Xsu2 /tmp/tmp.3A2eIfLU0p +++ return 0 ++ echo null + last_chunk=null + retries=1 ++ format_date null ++ local timestamp=null +++ TZ=UTC +++ /usr/sbin/date -d@null '+%Y-%m-%d %H:%M:%S' date: invalid date ‘@null’ ++ echo ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk () to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:51:46+0000] Waiting for last oplog chunk () to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ null -gt 1755172302 ]] + [[ 1 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.PHTthp4nLk ++++ mktemp +++ local LAST_ERR=/tmp/tmp.ytj3rHtOVk +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.PHTthp4nLk +++ cat /tmp/tmp.ytj3rHtOVk +++ rm /tmp/tmp.PHTthp4nLk /tmp/tmp.ytj3rHtOVk +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=2 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:51:58+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 2 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.fMwVqrxmcH ++++ mktemp +++ local LAST_ERR=/tmp/tmp.kbQas5yWkL +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.fMwVqrxmcH +++ cat /tmp/tmp.kbQas5yWkL +++ rm /tmp/tmp.fMwVqrxmcH /tmp/tmp.kbQas5yWkL +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=3 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:52:10+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 3 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.qORhlnTQmV ++++ mktemp +++ local LAST_ERR=/tmp/tmp.aomVGTMfQn +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.qORhlnTQmV +++ cat /tmp/tmp.aomVGTMfQn +++ rm /tmp/tmp.qORhlnTQmV /tmp/tmp.aomVGTMfQn +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=4 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:52:22+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 4 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.SeuojxKLMt ++++ mktemp +++ local LAST_ERR=/tmp/tmp.Y7HKNxr7u8 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.SeuojxKLMt +++ cat /tmp/tmp.Y7HKNxr7u8 +++ rm /tmp/tmp.SeuojxKLMt /tmp/tmp.Y7HKNxr7u8 +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=5 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:52:34+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 5 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.kA9xZpalt6 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.n2iEj1Dwuq +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.kA9xZpalt6 +++ cat /tmp/tmp.n2iEj1Dwuq +++ rm /tmp/tmp.kA9xZpalt6 /tmp/tmp.n2iEj1Dwuq +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=6 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:52:46+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 6 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.9Lby1ZUOsP ++++ mktemp +++ local LAST_ERR=/tmp/tmp.T5HGHqPvGQ +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.9Lby1ZUOsP +++ cat /tmp/tmp.T5HGHqPvGQ +++ rm /tmp/tmp.9Lby1ZUOsP /tmp/tmp.T5HGHqPvGQ +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=7 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:52:58+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 7 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.ohIMhMOVlE ++++ mktemp +++ local LAST_ERR=/tmp/tmp.rlFODDrZox +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.ohIMhMOVlE +++ cat /tmp/tmp.rlFODDrZox +++ rm /tmp/tmp.ohIMhMOVlE /tmp/tmp.rlFODDrZox +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=8 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:53:10+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 8 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.lUNWugyMMS ++++ mktemp +++ local LAST_ERR=/tmp/tmp.iD7QQfRjjQ +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.lUNWugyMMS +++ cat /tmp/tmp.iD7QQfRjjQ +++ rm /tmp/tmp.lUNWugyMMS /tmp/tmp.iD7QQfRjjQ +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=9 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:53:22+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 9 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.kOPoRE9sKl ++++ mktemp +++ local LAST_ERR=/tmp/tmp.nyXnGCn7Ul +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.kOPoRE9sKl +++ cat /tmp/tmp.nyXnGCn7Ul +++ rm /tmp/tmp.kOPoRE9sKl /tmp/tmp.nyXnGCn7Ul +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=10 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:53:35+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 10 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.8wBr8fn4z9 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.4JDFQZot1q +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.8wBr8fn4z9 +++ cat /tmp/tmp.4JDFQZot1q +++ rm /tmp/tmp.8wBr8fn4z9 /tmp/tmp.4JDFQZot1q +++ return 0 ++ echo 1755172297 + last_chunk=1755172297 + retries=11 ++ format_date 1755172297 ++ local timestamp=1755172297 +++ TZ=UTC +++ /usr/sbin/date -d@1755172297 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:37 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:53:47+0000] Waiting for last oplog chunk (2025-08-14 11:51:37) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172297 -gt 1755172302 ]] + [[ 11 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.CEqT3LubMu ++++ mktemp +++ local LAST_ERR=/tmp/tmp.Ig9XsxSDcn +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.CEqT3LubMu +++ cat /tmp/tmp.Ig9XsxSDcn +++ rm /tmp/tmp.CEqT3LubMu /tmp/tmp.Ig9XsxSDcn +++ return 0 ++ echo 1755172424 + last_chunk=1755172424 + retries=12 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172302 ++ local timestamp=1755172302 +++ TZ=UTC +++ /usr/sbin/date -d@1755172302 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:51:42 + log 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than last write (2025-08-14 11:51:42)' + set +o xtrace [2025-08-14T11:53:59+0000] Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than last write (2025-08-14 11:51:42) + sleep 10 + [[ 1755172424 -gt 1755172302 ]] + sleep 10 + check_recovery backup-minio-2 date 1755172424 -2nd some-name + local backup_name=backup-minio-2 + local restore_type=date + local restore_date=1755172424 + local cmp_postfix=-2nd + local cluster_name=some-name + local backupSource= ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.ST4cLE6qgY ++++ mktemp +++ local LAST_ERR=/tmp/tmp.XSI6Uxrdn7 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.ST4cLE6qgY +++ cat /tmp/tmp.XSI6Uxrdn7 +++ rm /tmp/tmp.ST4cLE6qgY /tmp/tmp.XSI6Uxrdn7 +++ return 0 ++ echo 1755172424 + local latest_ts=1755172424 + desc 'write more data before restore by date' + set +o xtrace ----------------------------------------------------------------------------------- write more data before restore by date ----------------------------------------------------------------------------------- + run_mongos 'use myApp\n db.test.insert({ x: 100501 })' myApp:myPass@some-name-mongos.pitr-physical-7378 + local 'command=use myApp\n db.test.insert({ x: 100501 })' + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo ++ echo .svc.cluster.local ++ awk -F: '{print $2}' + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.ky0D01RDDD +++ mktemp ++ local LAST_ERR=/tmp/tmp.M5OIkdRTyc ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.ky0D01RDDD ++ cat /tmp/tmp.M5OIkdRTyc ++ rm /tmp/tmp.ky0D01RDDD /tmp/tmp.M5OIkdRTyc ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100501 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.zr74jbjFMJ ++ mktemp + local LAST_ERR=/tmp/tmp.odTx9iyr5Y + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100501 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.zr74jbjFMJ Percona Server for MongoDB shell version v4.4.29-28 connecting to: mongodb://some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin?compressors=disabled&gssapiServiceName=mongodb Implicit session: session { "id" : UUID("bd8b4bac-6ca9-4183-8e44-fb80d2504a01") } Percona Server for MongoDB server version: v7.0.22-12 WARNING: shell and server versions do not match switched to db myApp WriteResult({ "nInserted" : 1 }) bye + cat /tmp/tmp.odTx9iyr5Y + rm /tmp/tmp.zr74jbjFMJ /tmp/tmp.odTx9iyr5Y + return 0 + [[ -n 1755172424 ]] ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + desc 'Restoring to time 2025-08-14 11:53:44' + set +o xtrace ----------------------------------------------------------------------------------- Restoring to time 2025-08-14 11:53:44 ----------------------------------------------------------------------------------- + retries=0 + [[ 1755172424 -gt 1755172424 ]] + [[ 0 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.V1Tpv3nJXk ++++ mktemp +++ local LAST_ERR=/tmp/tmp.jkeAIwbCD0 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.V1Tpv3nJXk +++ cat /tmp/tmp.jkeAIwbCD0 +++ rm /tmp/tmp.V1Tpv3nJXk /tmp/tmp.jkeAIwbCD0 +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=1 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 1 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.Ey2SxhphAR ++++ mktemp +++ local LAST_ERR=/tmp/tmp.R43UbUBam5 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.Ey2SxhphAR +++ cat /tmp/tmp.R43UbUBam5 +++ rm /tmp/tmp.Ey2SxhphAR /tmp/tmp.R43UbUBam5 +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=2 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 2 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.WPj3bE3kNg ++++ mktemp +++ local LAST_ERR=/tmp/tmp.KPBgDlXAEo +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.WPj3bE3kNg +++ cat /tmp/tmp.KPBgDlXAEo +++ rm /tmp/tmp.WPj3bE3kNg /tmp/tmp.KPBgDlXAEo +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=3 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 3 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.qsth3od2f7 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.Q6pCROyNim +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.qsth3od2f7 +++ cat /tmp/tmp.Q6pCROyNim +++ rm /tmp/tmp.qsth3od2f7 /tmp/tmp.Q6pCROyNim +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=4 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 4 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.FnorHNUu3v ++++ mktemp +++ local LAST_ERR=/tmp/tmp.irKUDa9hVx +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.FnorHNUu3v +++ cat /tmp/tmp.irKUDa9hVx +++ rm /tmp/tmp.FnorHNUu3v /tmp/tmp.irKUDa9hVx +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=5 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 5 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.j47aZ698Gv ++++ mktemp +++ local LAST_ERR=/tmp/tmp.D2IY4PnZSy +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.j47aZ698Gv +++ cat /tmp/tmp.D2IY4PnZSy +++ rm /tmp/tmp.j47aZ698Gv /tmp/tmp.D2IY4PnZSy +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=6 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 6 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.exMvcNBfzA ++++ mktemp +++ local LAST_ERR=/tmp/tmp.alvxi7WEq1 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.exMvcNBfzA +++ cat /tmp/tmp.alvxi7WEq1 +++ rm /tmp/tmp.exMvcNBfzA /tmp/tmp.alvxi7WEq1 +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=7 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 7 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json ++++ mktemp +++ local LAST_OUT=/tmp/tmp.VHUEv4NSv2 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.ZZdgFMBdly +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.VHUEv4NSv2 +++ cat /tmp/tmp.ZZdgFMBdly +++ rm /tmp/tmp.VHUEv4NSv2 /tmp/tmp.ZZdgFMBdly +++ return 0 ++ echo 1755172424 + latest_ts=1755172424 + retries=8 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:53:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172424 -gt 1755172424 ]] + [[ 8 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.Tpq8QS3zWn ++++ mktemp +++ local LAST_ERR=/tmp/tmp.luEU0svhU0 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.Tpq8QS3zWn +++ cat /tmp/tmp.luEU0svhU0 +++ rm /tmp/tmp.Tpq8QS3zWn /tmp/tmp.luEU0svhU0 +++ return 0 ++ echo 1755172544 + latest_ts=1755172544 + retries=9 ++ format_date 1755172544 ++ local timestamp=1755172544 +++ TZ=UTC +++ /usr/sbin/date -d@1755172544 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:44 ++ format_date 1755172424 ++ local timestamp=1755172424 +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:53:44 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:44) to be greater than restore target (2025-08-14 11:53:44)' Waiting for last oplog chunk (2025-08-14 11:55:44) to be greater than restore target (2025-08-14 11:53:44) + sleep 10 + [[ 1755172544 -gt 1755172424 ]] + '[' -z '' ']' + desc 'check restore by date' + set +o xtrace ----------------------------------------------------------------------------------- check restore by date ----------------------------------------------------------------------------------- + cat /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/restore.yml + /usr/sbin/sed -e 's/name:/name: restore-backup-minio-2/' + /usr/sbin/sed -e 's/backupName:/backupName: backup-minio-2/' + /usr/sbin/sed -e /backupSource/,+8d + /usr/sbin/sed -e 's/pitrType:/type: date/' + '[' -z 1755172424 ']' ++ format_date 1755172424 ++ local timestamp=1755172424 + kubectl_bin apply -f - +++ TZ=UTC +++ /usr/sbin/date -d@1755172424 '+%Y-%m-%d %H:%M:%S' ++ mktemp ++ echo 2025-08-14 11:53:44 + /usr/sbin/sed -e 's/date:/date: 2025-08-14 11:53:44/' + local LAST_OUT=/tmp/tmp.6i3sRkgHlC ++ mktemp + local LAST_ERR=/tmp/tmp.jn90mZvvfT + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.6i3sRkgHlC perconaservermongodbrestore.psmdb.percona.com/restore-backup-minio-2 created + cat /tmp/tmp.jn90mZvvfT + rm /tmp/tmp.6i3sRkgHlC /tmp/tmp.jn90mZvvfT + return 0 + wait_restore backup-minio-2 some-name requested 0 1200 + local backup_name=backup-minio-2 + local cluster_name=some-name + local target_state=requested + local wait_cluster_consistency=0 + local wait_time=1200 + local ok_if_ready=0 + set +o xtrace Waiting for the psmdb-restore/restore-backup-minio-2 object to be createdOK Waiting psmdb-restore/restore-backup-minio-2 to reach state "requested" .............OK after 13 minutes + [[ 0 -eq 1 ]] + echo + wait_restore backup-minio-2 some-name ready 0 1600 + local backup_name=backup-minio-2 + local cluster_name=some-name + local target_state=ready + local wait_cluster_consistency=0 + local wait_time=1600 + local ok_if_ready=0 + set +o xtrace Waiting for the psmdb-restore/restore-backup-minio-2 object to be createdOK Waiting psmdb-restore/restore-backup-minio-2 to reach state "ready" ..OK after 2 minutes + [[ 0 -eq 1 ]] + echo + set -o xtrace + wait_for_running some-name-rs0 3 + local name=some-name-rs0 + let last_pod=2 + local check_cluster_readyness=true + set_debug + [[ 1 == 1 ]] + set -o xtrace + local rs_name=rs0 + local cluster_name=some-name ++ seq 0 2 + for i in $(seq 0 $last_pod) + [[ 0 -eq 2 ]] + wait_pod some-name-rs0-0 + local pod=some-name-rs0-0 + set +o xtrace waiting for pod/some-name-rs0-0 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 1 -eq 2 ]] + wait_pod some-name-rs0-1 + local pod=some-name-rs0-1 + set +o xtrace waiting for pod/some-name-rs0-1 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 2 -eq 2 ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].arbiter.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.Juz6t0YR25 +++ mktemp ++ local LAST_ERR=/tmp/tmp.hZBQ1CRg1x ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].arbiter.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.Juz6t0YR25 ++ cat /tmp/tmp.hZBQ1CRg1x ++ rm /tmp/tmp.Juz6t0YR25 /tmp/tmp.hZBQ1CRg1x ++ return 0 + [[ '' == \t\r\u\e ]] + wait_pod some-name-rs0-2 + local pod=some-name-rs0-2 + set +o xtrace waiting for pod/some-name-rs0-2 to be ready.OK ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].non_voting.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.nlV7FRSE98 +++ mktemp ++ local LAST_ERR=/tmp/tmp.ozRHaYWQeP ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].non_voting.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.nlV7FRSE98 ++ cat /tmp/tmp.ozRHaYWQeP ++ rm /tmp/tmp.nlV7FRSE98 /tmp/tmp.ozRHaYWQeP ++ return 0 + [[ '' == \t\r\u\e ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].hidden.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.w4r31hl8DN +++ mktemp ++ local LAST_ERR=/tmp/tmp.vzW0lRsWpB ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="rs0")].hidden.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.w4r31hl8DN ++ cat /tmp/tmp.vzW0lRsWpB ++ rm /tmp/tmp.w4r31hl8DN /tmp/tmp.vzW0lRsWpB ++ return 0 + [[ '' == \t\r\u\e ]] + sleep 10 + [[ true == \t\r\u\e ]] + set +x Waiting for cluster readyness............................................................................. + wait_for_running some-name-cfg 3 + local name=some-name-cfg + let last_pod=2 + local check_cluster_readyness=true + set_debug + [[ 1 == 1 ]] + set -o xtrace + local rs_name=cfg + local cluster_name=some-name ++ seq 0 2 + for i in $(seq 0 $last_pod) + [[ 0 -eq 2 ]] + wait_pod some-name-cfg-0 + local pod=some-name-cfg-0 + set +o xtrace waiting for pod/some-name-cfg-0 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 1 -eq 2 ]] + wait_pod some-name-cfg-1 + local pod=some-name-cfg-1 + set +o xtrace waiting for pod/some-name-cfg-1 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 2 -eq 2 ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].arbiter.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.vV6eEZEo7y +++ mktemp ++ local LAST_ERR=/tmp/tmp.QYGMvz39Lk ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].arbiter.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.vV6eEZEo7y ++ cat /tmp/tmp.QYGMvz39Lk ++ rm /tmp/tmp.vV6eEZEo7y /tmp/tmp.QYGMvz39Lk ++ return 0 + [[ '' == \t\r\u\e ]] + wait_pod some-name-cfg-2 + local pod=some-name-cfg-2 + set +o xtrace waiting for pod/some-name-cfg-2 to be ready.OK ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].non_voting.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.kStklg6Zvt +++ mktemp ++ local LAST_ERR=/tmp/tmp.eQNp4przNh ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].non_voting.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.kStklg6Zvt ++ cat /tmp/tmp.eQNp4przNh ++ rm /tmp/tmp.kStklg6Zvt /tmp/tmp.eQNp4przNh ++ return 0 + [[ '' == \t\r\u\e ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].hidden.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.S8Cu37yKdC +++ mktemp ++ local LAST_ERR=/tmp/tmp.FVG1yBxdBa ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="cfg")].hidden.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.S8Cu37yKdC ++ cat /tmp/tmp.FVG1yBxdBa ++ rm /tmp/tmp.S8Cu37yKdC /tmp/tmp.FVG1yBxdBa ++ return 0 + [[ '' == \t\r\u\e ]] + sleep 10 + [[ true == \t\r\u\e ]] + set +x Waiting for cluster readyness + wait_for_running some-name-mongos 3 + local name=some-name-mongos + let last_pod=2 + local check_cluster_readyness=true + set_debug + [[ 1 == 1 ]] + set -o xtrace + local rs_name=mongos + local cluster_name=some-name ++ seq 0 2 + for i in $(seq 0 $last_pod) + [[ 0 -eq 2 ]] + wait_pod some-name-mongos-0 + local pod=some-name-mongos-0 + set +o xtrace waiting for pod/some-name-mongos-0 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 1 -eq 2 ]] + wait_pod some-name-mongos-1 + local pod=some-name-mongos-1 + set +o xtrace waiting for pod/some-name-mongos-1 to be ready.OK + for i in $(seq 0 $last_pod) + [[ 2 -eq 2 ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="mongos")].arbiter.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.xHegngTpm6 +++ mktemp ++ local LAST_ERR=/tmp/tmp.c7HWDxiO2m ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="mongos")].arbiter.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.xHegngTpm6 ++ cat /tmp/tmp.c7HWDxiO2m ++ rm /tmp/tmp.xHegngTpm6 /tmp/tmp.c7HWDxiO2m ++ return 0 + [[ '' == \t\r\u\e ]] + wait_pod some-name-mongos-2 + local pod=some-name-mongos-2 + set +o xtrace waiting for pod/some-name-mongos-2 to be ready.OK ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="mongos")].non_voting.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.OmfKTP40Zn +++ mktemp ++ local LAST_ERR=/tmp/tmp.dxJt7yh9Gf ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="mongos")].non_voting.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.OmfKTP40Zn ++ cat /tmp/tmp.dxJt7yh9Gf ++ rm /tmp/tmp.OmfKTP40Zn /tmp/tmp.dxJt7yh9Gf ++ return 0 + [[ '' == \t\r\u\e ]] ++ kubectl_bin get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="mongos")].hidden.enabled}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.5mmF28XcJC +++ mktemp ++ local LAST_ERR=/tmp/tmp.Sh5L3o6syM ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get psmdb some-name -o 'jsonpath={.spec.replsets[?(@.name=="mongos")].hidden.enabled}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.5mmF28XcJC ++ cat /tmp/tmp.Sh5L3o6syM ++ rm /tmp/tmp.5mmF28XcJC /tmp/tmp.Sh5L3o6syM ++ return 0 + [[ '' == \t\r\u\e ]] + sleep 10 + [[ true == \t\r\u\e ]] + set +x Waiting for cluster readyness + sleep 10 + compare_mongos_cmd find myApp:myPass@some-name-mongos.pitr-physical-7378 -2nd + local command=find + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local postfix=-2nd + local suffix= + local database=myApp + local collection=test + local port=27017 + run_mongos 'use myApp\n db.test.find()' myApp:myPass@some-name-mongos.pitr-physical-7378 mongodb '' '' 27017 + local 'command=use myApp\n db.test.find()' + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo + egrep -v 'I NETWORK|W NETWORK|Error saving history file|Percona Server for MongoDB|connecting to:|Unable to reach primary for set|Implicit session:|versions do not match|Error saving history file:' + /usr/sbin/sed -re 's/ObjectId\("[0-9a-f]+"\)//; s/-[0-9]+.svc/-xxx.svc/' ++ echo .svc.cluster.local ++ awk -F: '{print $2}' egrep: warning: egrep is obsolescent; using grep -E + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.3tC1LNTFdo +++ mktemp ++ local LAST_ERR=/tmp/tmp.CRp1bU4PJl ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.3tC1LNTFdo ++ cat /tmp/tmp.CRp1bU4PJl ++ rm /tmp/tmp.3tC1LNTFdo /tmp/tmp.CRp1bU4PJl ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.find()\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.3GKbeykzAX ++ mktemp + local LAST_ERR=/tmp/tmp.nITRrqEe7i + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.find()\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.3GKbeykzAX + cat /tmp/tmp.nITRrqEe7i + rm /tmp/tmp.3GKbeykzAX /tmp/tmp.nITRrqEe7i + return 0 + [[ 0 -eq 0 ]] + diff /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/compare/find-2nd.json /tmp/tmp.kqz0hqOubJ/find-2nd + run_backup backup-minio 3 physical + local name=backup-minio + local idx=3 + local type=physical + desc 'run backup backup-minio-3' + set +o xtrace ----------------------------------------------------------------------------------- run backup backup-minio-3 ----------------------------------------------------------------------------------- + cat /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/backup-minio.yml + /usr/sbin/sed -e 's/name:/name: backup-minio-3/' + /usr/sbin/sed -e 's/type:/type: physical/' + kubectl_bin apply -f - ++ mktemp + local LAST_OUT=/tmp/tmp.eTcmP3Cb54 ++ mktemp + local LAST_ERR=/tmp/tmp.mBHzlVPFln + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.eTcmP3Cb54 perconaservermongodbbackup.psmdb.percona.com/backup-minio-3 created + cat /tmp/tmp.mBHzlVPFln + rm /tmp/tmp.eTcmP3Cb54 /tmp/tmp.mBHzlVPFln + return 0 + wait_backup backup-minio-3 + local backup_name=backup-minio-3 + local target_state=ready + set +o xtrace waiting for backup-minio-3 to reach ready state........ + sleep 5 + compare_latest_restorable_time some-name-rs0 backup-minio-3 + local cluster=some-name-rs0 + local backup_name=backup-minio-3 + local latest_restorable_time + local backup_time ++ get_latest_restorable_time some-name-rs0 ++ local cluster=some-name-rs0 ++ local first_timestamp ++ local second_timestamp ++ local retry=0 ++ [[ '' != '' ]] +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.ZhpMWXuOYY ++++ mktemp +++ local LAST_ERR=/tmp/tmp.moOH3stKaY +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.ZhpMWXuOYY +++ cat /tmp/tmp.moOH3stKaY +++ rm /tmp/tmp.ZhpMWXuOYY /tmp/tmp.moOH3stKaY +++ return 0 ++ first_timestamp=1755172548 ++ sleep 5 ++ [[ 1755172548 != '' ]] ++ [[ 1755172548 != \n\u\l\l ]] +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.RFnAGDNE7u ++++ mktemp +++ local LAST_ERR=/tmp/tmp.u0ZMg7Rdfl +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.RFnAGDNE7u +++ cat /tmp/tmp.u0ZMg7Rdfl +++ rm /tmp/tmp.RFnAGDNE7u /tmp/tmp.u0ZMg7Rdfl +++ return 0 ++ second_timestamp=1755172548 ++ let retry+=1 ++ [[ 1 -gt 30 ]] ++ [[ 1755172548 != '' ]] ++ [[ 1755172548 != \n\u\l\l ]] ++ [[ 1755172548 == 1755172548 ]] ++ /usr/sbin/date -u -d @1755172548 +%Y-%m-%dT%H:%M:%SZ + latest_restorable_time=2025-08-14T11:55:48Z ++ get_latest_restorable_time_from_backup_object backup-minio-3 ++ local backup_name=backup-minio-3 ++ local latestRestorableTime ++ local retry=0 ++ [[ '' != '' ]] ++ sleep 5 +++ kubectl_bin get psmdb-backup backup-minio-3 -o 'jsonpath={.status.latestRestorableTime}' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.9LMuWsSx9y ++++ mktemp +++ local LAST_ERR=/tmp/tmp.G69az0Kl8B +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl get psmdb-backup backup-minio-3 -o 'jsonpath={.status.latestRestorableTime}' +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.9LMuWsSx9y +++ cat /tmp/tmp.G69az0Kl8B +++ rm /tmp/tmp.9LMuWsSx9y /tmp/tmp.G69az0Kl8B +++ return 0 ++ latestRestorableTime=2025-08-14T11:55:48Z ++ let retry+=1 ++ [[ 1 -gt 30 ]] ++ [[ 2025-08-14T11:55:48Z != '' ]] ++ [[ 2025-08-14T11:55:48Z != \n\u\l\l ]] ++ echo 2025-08-14T11:55:48Z + backup_time=2025-08-14T11:55:48Z + [[ 2025-08-14T11:55:48Z != \2\0\2\5\-\0\8\-\1\4\T\1\1\:\5\5\:\4\8\Z ]] + check_recovery backup-minio-3 latest '' -3rd some-name + local backup_name=backup-minio-3 + local restore_type=latest + local restore_date= + local cmp_postfix=-3rd + local cluster_name=some-name + local backupSource= ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.vM4R89p9lG ++++ mktemp +++ local LAST_ERR=/tmp/tmp.GhiUBnrjaP +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.vM4R89p9lG +++ cat /tmp/tmp.GhiUBnrjaP +++ rm /tmp/tmp.vM4R89p9lG /tmp/tmp.GhiUBnrjaP +++ return 0 ++ echo 1755172548 + local latest_ts=1755172548 + desc 'write more data before restore by latest' + set +o xtrace ----------------------------------------------------------------------------------- write more data before restore by latest ----------------------------------------------------------------------------------- + run_mongos 'use myApp\n db.test.insert({ x: 100501 })' myApp:myPass@some-name-mongos.pitr-physical-7378 + local 'command=use myApp\n db.test.insert({ x: 100501 })' + local uri=myApp:myPass@some-name-mongos.pitr-physical-7378 + local driver=mongodb + local suffix=.svc.cluster.local + local mongo_flag= + local port=27017 + local mongo_bin=mongo ++ echo .svc.cluster.local ++ awk -F: '{print $2}' + suffix_port= + [[ -z '' ]] + suffix=.svc.cluster.local:27017 ++ kubectl_bin get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' +++ mktemp ++ local LAST_OUT=/tmp/tmp.tnVN5ORudC +++ mktemp ++ local LAST_ERR=/tmp/tmp.IFOOsiQREv ++ local exit_status=0 ++ local timeout=4 +++ seq 0 2 ++ for i in $(seq 0 2) ++ set +e ++ kubectl get pods --selector=name=psmdb-client -o 'jsonpath={.items[].metadata.name}' ++ exit_status=0 ++ set -e ++ '[' 0 '!=' 0 -a -n 1 ']' ++ break ++ cat /tmp/tmp.tnVN5ORudC ++ cat /tmp/tmp.IFOOsiQREv ++ rm /tmp/tmp.tnVN5ORudC /tmp/tmp.IFOOsiQREv ++ return 0 + local client_container=psmdb-client-66f577db5f-cs2k7 + kubectl_bin exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100501 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' ++ mktemp + local LAST_OUT=/tmp/tmp.fAUaN1UERN ++ mktemp + local LAST_ERR=/tmp/tmp.wFUiAGg5P8 + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl exec psmdb-client-66f577db5f-cs2k7 -- bash -c 'printf '\''use myApp\n db.test.insert({ x: 100501 })\n'\'' | mongo mongodb://myApp:myPass@some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin ' + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.fAUaN1UERN Percona Server for MongoDB shell version v4.4.29-28 connecting to: mongodb://some-name-mongos.pitr-physical-7378.svc.cluster.local:27017/admin?compressors=disabled&gssapiServiceName=mongodb Implicit session: session { "id" : UUID("5528f807-a1d8-4497-a8aa-c7b1bc138bab") } Percona Server for MongoDB server version: v7.0.22-12 WARNING: shell and server versions do not match switched to db myApp WriteResult({ "nInserted" : 1 }) bye + cat /tmp/tmp.wFUiAGg5P8 + rm /tmp/tmp.fAUaN1UERN /tmp/tmp.wFUiAGg5P8 + return 0 + [[ -n '' ]] + desc 'Restoring to latest' + set +o xtrace ----------------------------------------------------------------------------------- Restoring to latest ----------------------------------------------------------------------------------- ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.Cu7YdDeIOn ++++ mktemp +++ local LAST_ERR=/tmp/tmp.xZNQATjCrS +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.Cu7YdDeIOn +++ cat /tmp/tmp.xZNQATjCrS +++ rm /tmp/tmp.Cu7YdDeIOn /tmp/tmp.xZNQATjCrS +++ return 0 ++ echo 1755172548 + local current_ts=1755172548 + retries=0 + [[ 1755172548 -gt 1755172548 ]] + [[ 0 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.hJuECvXmC2 ++++ mktemp +++ local LAST_ERR=/tmp/tmp.Y5ZlRgcH2m +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.hJuECvXmC2 +++ cat /tmp/tmp.Y5ZlRgcH2m +++ rm /tmp/tmp.hJuECvXmC2 /tmp/tmp.Y5ZlRgcH2m +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=1 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 1 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json ++++ mktemp +++ local LAST_OUT=/tmp/tmp.b3Y9BB1IgO ++++ mktemp +++ local LAST_ERR=/tmp/tmp.8W89JkzReV +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.b3Y9BB1IgO +++ cat /tmp/tmp.8W89JkzReV +++ rm /tmp/tmp.b3Y9BB1IgO /tmp/tmp.8W89JkzReV +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=2 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 2 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.vwaN1Pb4II ++++ mktemp +++ local LAST_ERR=/tmp/tmp.aRlT1szvOB +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.vwaN1Pb4II +++ cat /tmp/tmp.aRlT1szvOB +++ rm /tmp/tmp.vwaN1Pb4II /tmp/tmp.aRlT1szvOB +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=3 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 3 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.E0I22a8HKR ++++ mktemp +++ local LAST_ERR=/tmp/tmp.XXB5UQH7J2 +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.E0I22a8HKR +++ cat /tmp/tmp.XXB5UQH7J2 +++ rm /tmp/tmp.E0I22a8HKR /tmp/tmp.XXB5UQH7J2 +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=4 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 4 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.auRVXGQ3Sr ++++ mktemp +++ local LAST_ERR=/tmp/tmp.gK0AYmLdCq +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.auRVXGQ3Sr +++ cat /tmp/tmp.gK0AYmLdCq +++ rm /tmp/tmp.auRVXGQ3Sr /tmp/tmp.gK0AYmLdCq +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=5 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 5 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.1g4CFFRaDq ++++ mktemp +++ local LAST_ERR=/tmp/tmp.vf9NoPVXXd +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.1g4CFFRaDq +++ cat /tmp/tmp.vf9NoPVXXd +++ rm /tmp/tmp.1g4CFFRaDq /tmp/tmp.vf9NoPVXXd +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=6 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 6 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.Dgi9L33KEo ++++ mktemp +++ local LAST_ERR=/tmp/tmp.wIkt7PvnrK +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.Dgi9L33KEo +++ cat /tmp/tmp.wIkt7PvnrK +++ rm /tmp/tmp.Dgi9L33KEo /tmp/tmp.wIkt7PvnrK +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=7 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 7 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.FqCrcwoWdb ++++ mktemp +++ local LAST_ERR=/tmp/tmp.1GSU5I8eoB +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.FqCrcwoWdb +++ cat /tmp/tmp.1GSU5I8eoB +++ rm /tmp/tmp.FqCrcwoWdb /tmp/tmp.1GSU5I8eoB +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=8 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 8 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.PaGHlXtg4l ++++ mktemp +++ local LAST_ERR=/tmp/tmp.EghusriJsn +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.PaGHlXtg4l +++ cat /tmp/tmp.EghusriJsn +++ rm /tmp/tmp.PaGHlXtg4l /tmp/tmp.EghusriJsn +++ return 0 ++ echo 1755172548 + latest_ts=1755172548 + retries=9 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 11:55:48) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755172548 -gt 1755172548 ]] + [[ 9 -gt 30 ]] ++ get_latest_oplog_chunk_ts some-name ++ local cluster=some-name +++ kubectl_bin exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ jq '.backups.pitrChunks.pitrChunks | last | .range.end' ++++ mktemp +++ local LAST_OUT=/tmp/tmp.qDJCphjuSM ++++ mktemp +++ local LAST_ERR=/tmp/tmp.YIHjlTV2EQ +++ local exit_status=0 +++ local timeout=4 ++++ seq 0 2 +++ for i in $(seq 0 2) +++ set +e +++ kubectl exec some-name-rs0-0 -c backup-agent -- pbm status -o json +++ exit_status=0 +++ set -e +++ '[' 0 '!=' 0 -a -n 1 ']' +++ break +++ cat /tmp/tmp.qDJCphjuSM +++ cat /tmp/tmp.YIHjlTV2EQ +++ rm /tmp/tmp.qDJCphjuSM /tmp/tmp.YIHjlTV2EQ +++ return 0 ++ echo 1755173936 + latest_ts=1755173936 + retries=10 ++ format_date 1755173936 ++ local timestamp=1755173936 +++ TZ=UTC +++ /usr/sbin/date -d@1755173936 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 12:18:56 ++ format_date 1755172548 ++ local timestamp=1755172548 +++ TZ=UTC +++ /usr/sbin/date -d@1755172548 '+%Y-%m-%d %H:%M:%S' ++ echo 2025-08-14 11:55:48 + echo 'Waiting for last oplog chunk (2025-08-14 12:18:56) to be 120 seconds older than starting chunk (2025-08-14 11:55:48)' Waiting for last oplog chunk (2025-08-14 12:18:56) to be 120 seconds older than starting chunk (2025-08-14 11:55:48) + sleep 10 + [[ 1755173936 -gt 1755172548 ]] + '[' -z '' ']' + desc 'check restore by latest' + set +o xtrace ----------------------------------------------------------------------------------- check restore by latest ----------------------------------------------------------------------------------- + cat /mnt/jenkins/workspace/cloud-psmdb-operator_PR-1961/e2e-tests/pitr-physical/conf/restore.yml + /usr/sbin/sed -e 's/name:/name: restore-backup-minio-3/' + /usr/sbin/sed -e 's/backupName:/backupName: backup-minio-3/' + /usr/sbin/sed -e /backupSource/,+8d + /usr/sbin/sed -e 's/pitrType:/type: latest/' + '[' -z '' ']' + /usr/sbin/sed -e /date:/d + kubectl_bin apply -f - ++ mktemp + local LAST_OUT=/tmp/tmp.NgQozzl9m0 ++ mktemp + local LAST_ERR=/tmp/tmp.MI1l0sGnyU + local exit_status=0 + local timeout=4 ++ seq 0 2 + for i in $(seq 0 2) + set +e + kubectl apply -f - + exit_status=0 + set -e + '[' 0 '!=' 0 -a -n 1 ']' + break + cat /tmp/tmp.NgQozzl9m0 perconaservermongodbrestore.psmdb.percona.com/restore-backup-minio-3 created + cat /tmp/tmp.MI1l0sGnyU + rm /tmp/tmp.NgQozzl9m0 /tmp/tmp.MI1l0sGnyU + return 0 + wait_restore backup-minio-3 some-name requested 0 1200 + local backup_name=backup-minio-3 + local cluster_name=some-name + local target_state=requested + local wait_cluster_consistency=0 + local wait_time=1200 + local ok_if_ready=0 + set +o xtrace Waiting for the psmdb-restore/restore-backup-minio-3 object to be createdOK Waiting psmdb-restore/restore-backup-minio-3 to reach state "requested" ...