Month: April 2012
I recently had to configure iSCSI with multipathing on RHEL 6. It wasn’t too hard and these instructions will presumably work with other Redhat based versions & distros
It involves installing/configuring the iSCSI utilities and then installing/configuring Device-Mapper. Device-Mapper will automatically discover devices with multiple paths and creates a mpath device that can be used to load balance/failover between all the paths.
1.) Install iSCSI and Device-Mapper
# yum install iscsi-initiator-utils # yum install device-mapper-multipath
2.) Start iSCSI
# chkconfig iscsi on # chkconfig iscsid on # service iscsi start # service iscsid start
3.) Find your hosts IQN and Update your iSCSI Array
Each iSCSi device will have a iSCSI Qualified Name (IQN). This name is used to manage LUN masking on the iSCSI arrays.
# cat /etc/iscsi/initiatorname.iscsi
Once you have your IQN you then need to go to your iSCSI array and carve out the LUNs you plan…
View original post 637 more words
Python – writing to a file on a fileystem to test I/O
This is very useful Python script that will allow you to test writing to a file on a filesytem. This can be used to verify that their are no I/O read or write failures during an extend or migration of a filesystem.
#!/usr/bin/python
import time
testfile = "/dbbackup-01/testfile.txt"
for i in range(100):
print i
fo = open(testfile, "a")
fo.write('test write while the filesystem is being modified\n')
print fo.name
fo.close()
time.sleep(0.2)