Month: November 2017

Blog of interesting data center technical tips / tasks / articles which we come across

How to replace text inplace without opening it, using sed

I have always loved range of text searching and editing tools in Linux. Be it grep to search for various patterns in a file. Or awk to print parts of a file in required format. Or the general purpose vi editor. Or the stream editor sed. Am writing this post to highlight just one feature…
Read more


November 8, 2017 0

Scan newly added disks or rescan resized disk in Linux VM

How do we rescan for new disks after adding a VMDK to a Linux Virtual Machine? First, list all disks available in the VM sudo fdisk -l Running the following command will scan for new scsi disks. sudo echo “- – -” > /sys/class/scsi_host/host0/scan .. .. sudo echo “- – -” > /sys/class/scsi_host/hostN/scan Run this…
Read more


November 1, 2017 0