LAB 20 (Detach Block Volume) - arunsinghchauhan38-arch/CLOUDARCHITECTDOC GitHub Wiki
Detach Block Volume
Step 1 Detach Block Volume
Befor Detaching the block volume, please use the steps below to confirm the block volume data on the new instance.
1.Add a test file in the mounted folder /u01
- Display the total size of the current directory in a human- readable format
du -sh /u01
Run below commands before unmounting block volume
lsblk
df -h
Now unmount block volume which is currently mounted at the /u01 directory
umount /u01
Again run below commands to check volume unmounted or not?
lsblk
df -h
Since the mounted folder is not visible, but the volume is still present, we will execute the iSCSI detach command in PuTTY.
open that particular attached BV in OCI Go to three dots,
select iSCSI commands & information and copy disconnect command.
Run the iSCSI detach command in putty
and again run lsblk command to check
lsblk
so, now block volume is not showing.
Before detaching the volume in OCI, we'll remove the last line from the fstab file that was added during mounting.
vi /etc/fstab
Save & exit
:wq!
Finally we will detach block volume in OCI