)]}'
{"ceph-osd/templates/bin/osd/ceph-volume/_init-with-ceph-volume.sh.tpl":[{"author":{"_account_id":8863,"name":"Andrii Ostapenko","email":"anost1986@gmail.com","username":"aostapenko"},"change_message_id":"b4c4ec3d790e3d9684df70840269883150f1747d","unresolved":true,"context_lines":[{"line_number":220,"context_line":"    vgrename \"ceph-vg-${random_uuid}\" \"${VG}\""},{"line_number":221,"context_line":"  fi"},{"line_number":222,"context_line":"  logical_volumes\u003d\"$(lvs --noheadings -o lv_name ${VG} | xargs)\""},{"line_number":223,"context_line":"  for volume in ${logical_volumes}; do"},{"line_number":224,"context_line":"    data_volume\u003d$(echo ${volume} | sed -E -e \u0027s/db|wal/lv/g\u0027)"},{"line_number":225,"context_line":"    if [[ -z $(lvs --noheadings -o lv_name -S \"lv_name\u003d${data_volume}\") ]]; then"},{"line_number":226,"context_line":"      # DB or WAL volume without a corresponding data volume, remove it"},{"line_number":227,"context_line":"      lvremove -y /dev/${VG}/${volume}"},{"line_number":228,"context_line":"    fi"},{"line_number":229,"context_line":"  done"},{"line_number":230,"context_line":"  udev_settle"},{"line_number":231,"context_line":"  logical_volume\u003d$(lvs --noheadings -o lv_name -S \"lv_name\u003d${lv_name}\" | tr -d \u0027[:space:]\u0027)"},{"line_number":232,"context_line":"  if [[ $logical_volume !\u003d \"${lv_name}\" ]]; then"}],"source_content_type":"text/x-smarty","patch_set":32,"id":"67c1ca89_d3a1291e","line":229,"range":{"start_line":223,"start_character":0,"end_line":229,"end_character":6},"updated":"2021-01-06 19:39:17.000000000","message":"this is pretty unsafe if not maintained well. Imagine future code that changes data volume naming and if this part is missed - we\u0027re going to have an undesired deletion of db or wal volumes. lets hold on for a bit and think if there\u0027s another way to bring idempotency to osd-init run","commit_id":"c0821c9cab68d34c571360fc40a1b2a8feb7d86b"},{"author":{"_account_id":29974,"name":"Stephen Taylor","email":"stephen.taylor.1@att.com","username":"st053q"},"change_message_id":"24829d231060662d81114d40445f35edc6ec3b91","unresolved":true,"context_lines":[{"line_number":220,"context_line":"    vgrename \"ceph-vg-${random_uuid}\" \"${VG}\""},{"line_number":221,"context_line":"  fi"},{"line_number":222,"context_line":"  logical_volumes\u003d\"$(lvs --noheadings -o lv_name ${VG} | xargs)\""},{"line_number":223,"context_line":"  for volume in ${logical_volumes}; do"},{"line_number":224,"context_line":"    data_volume\u003d$(echo ${volume} | sed -E -e \u0027s/db|wal/lv/g\u0027)"},{"line_number":225,"context_line":"    if [[ -z $(lvs --noheadings -o lv_name -S \"lv_name\u003d${data_volume}\") ]]; then"},{"line_number":226,"context_line":"      # DB or WAL volume without a corresponding data volume, remove it"},{"line_number":227,"context_line":"      lvremove -y /dev/${VG}/${volume}"},{"line_number":228,"context_line":"    fi"},{"line_number":229,"context_line":"  done"},{"line_number":230,"context_line":"  udev_settle"},{"line_number":231,"context_line":"  logical_volume\u003d$(lvs --noheadings -o lv_name -S \"lv_name\u003d${lv_name}\" | tr -d \u0027[:space:]\u0027)"},{"line_number":232,"context_line":"  if [[ $logical_volume !\u003d \"${lv_name}\" ]]; then"}],"source_content_type":"text/x-smarty","patch_set":32,"id":"79775635_9f112f99","line":229,"range":{"start_line":223,"start_character":0,"end_line":229,"end_character":6},"in_reply_to":"4f25a100_a5abe3e5","updated":"2021-01-07 17:39:10.000000000","message":"Also, this orphan clean-up behavior used to be in place and the patch set referenced in the commit message broke it. So this also corrects a regression that was introduced a few months back.","commit_id":"c0821c9cab68d34c571360fc40a1b2a8feb7d86b"},{"author":{"_account_id":29974,"name":"Stephen Taylor","email":"stephen.taylor.1@att.com","username":"st053q"},"change_message_id":"a68d96872a4ae422db6ed4947d89345480c7fbe7","unresolved":true,"context_lines":[{"line_number":220,"context_line":"    vgrename \"ceph-vg-${random_uuid}\" \"${VG}\""},{"line_number":221,"context_line":"  fi"},{"line_number":222,"context_line":"  logical_volumes\u003d\"$(lvs --noheadings -o lv_name ${VG} | xargs)\""},{"line_number":223,"context_line":"  for volume in ${logical_volumes}; do"},{"line_number":224,"context_line":"    data_volume\u003d$(echo ${volume} | sed -E -e \u0027s/db|wal/lv/g\u0027)"},{"line_number":225,"context_line":"    if [[ -z $(lvs --noheadings -o lv_name -S \"lv_name\u003d${data_volume}\") ]]; then"},{"line_number":226,"context_line":"      # DB or WAL volume without a corresponding data volume, remove it"},{"line_number":227,"context_line":"      lvremove -y /dev/${VG}/${volume}"},{"line_number":228,"context_line":"    fi"},{"line_number":229,"context_line":"  done"},{"line_number":230,"context_line":"  udev_settle"},{"line_number":231,"context_line":"  logical_volume\u003d$(lvs --noheadings -o lv_name -S \"lv_name\u003d${lv_name}\" | tr -d \u0027[:space:]\u0027)"},{"line_number":232,"context_line":"  if [[ $logical_volume !\u003d \"${lv_name}\" ]]; then"}],"source_content_type":"text/x-smarty","patch_set":32,"id":"4f25a100_a5abe3e5","line":229,"range":{"start_line":223,"start_character":0,"end_line":229,"end_character":6},"in_reply_to":"67c1ca89_d3a1291e","updated":"2021-01-07 16:02:06.000000000","message":"In addition to the confusing gate failures we have seen that this seems to fix, there is also a more legitimate case for this logic. If an OSD disk fails and has to be replaced, there isn\u0027t currently any logic to remove the failed OSD\u0027s DB and WAL volumes automatically if they reside on separate disks. This addresses that and allows for automatic redeployment of the OSD on a new data disk.","commit_id":"c0821c9cab68d34c571360fc40a1b2a8feb7d86b"}]}
