mirror external scsi to san


 
Thread Tools Search this Thread
Operating Systems AIX mirror external scsi to san
# 1  
Old 04-14-2008
mirror external scsi to san

Hi,

How do I mirror an external scsi vg to one hdisk san? The vg has multiple hdisks and the san hdisk has only one.

Is this possible or do I need to create the same hdisks as the scsi? What I meant is, if the scsi vg has 10 hdisk then I need to create also 10 hdisk of san with the same size as per hdisk?

Or I can mirror a logical vg one by one?

Here's the sample of one of the vg:
LV NAME TYPE LPs PPs PVs LV STATE MOUNT POINT
lv110 jfs 3840 3840 8 closed/syncd N/A
lv102 jfs 128 128 1 closed/syncd N/A
lv68 jfs 16 16 1 closed/syncd N/A
loglv03 jfslog 1 1 1 open/syncd N/A
lvcrt01 jfs 178 178 1 open/syncd /crt01
lv106 jfs 16 16 1 open/syncd /db2replication
lv100 jfs 320 320 2 open/syncd /db2logs
paging05 paging 16 16 1 open/syncd N/A
paging06 paging 16 16 1 open/syncd N/A
paging01 paging 16 16 1 open/syncd N/A
lvcrt02 jfs 175 175 1 open/syncd /crt02
lv103 jfs 256 256 1 closed/syncd N/A


As much as possible I don't want a downtime. I don't know what is the best approach.

Thanks in advance,
itik
# 2  
Old 04-14-2008
You can mirror this to only one LUN if that LUN is big enough. Just add lv copies with

mklvcopy <LVname> 2 hdiskXX

where hdiskXX is the LUN from the san. Do this for every LV and then sync the volume group with

syncvg -v <VGname>.

Thats about it.
# 3  
Old 04-14-2008
Short answer: yes, you can mirror several SCSI disks to one SAN disk - but you should not do it anyways.

Long version:

1. FS considerations
As far as your sample vg layout goes you still use JFS(-1) filesystems. You should change that to the newer and by far better JFS2-filesystem. It will be necessary to recreate the filesystems and do a backup/restore of the data. As far as i know there is no way to convert JFS to JFS2 directly.

2. VG considerations
There are some limits in the LVM and one does good to stay away from any of them. The most restraining one is (in my experience) the PP size. As a PV can only hold 1019 PPs it limits directly the size of the disks you can effectively use. (Yes, there is the possibility of using a "factor" to lighten this restriction up to a certain point but at the same time it even tightens the limit on the maximum number of PVs in a VG, so i would not consider it as a long-term solution. Better stay away from that and save this option for a situation where it really *really* is your only possibility.)

As you have several SCSI PVs in the VG i suppose the PP size to be relatively small. When you add your SAN disk it probably exceeds the PP number limit and would practically enforce you to introduce a factor into the VG. The IMHO better (that is: more sustainable) solution would be recreate the VG anew and with better suited values for PP size.

Conclusion
========

If you still want to migrate to the new disk without recreating the VG and the FSs do the following, which can all be done without any downtime:

1. Add the new PV to the VG, maybe first changing the VG to a "Big VG" and introducing a factor as necessary.

2. use the "mirrorvg" facility to add mirrors to every LV, you can designate the new PV as destination for the mirror. You can do that using SMITty.

3. wait until the synchronization is finished. This may take some time and you might want to start in an evening so this can take place over night.

4. remove the mirror using the "unmirrorvg". You can again use SMITty and designate which mirror to remove by declaring the PVs from which the mirrors are to be removed.

5. used "reducevg" to get the old disks out of the VG finally.

6. use "rmdev" to remove the SCSI devices, disconnect them from the system.

Again, i would consider this as an unfortunate solution, but it *can* be done without any downtime (just the performance would be noticeably degraded during the synchronization). Better do the following:

1. create a new VG using the SAN share as PV. Carefully choose a sensible value for the PP size as it limits the maximum size of the PVs in the VG as well as the maximum capacity of the VG as a whole. (Introducing a factor means multiplying the maximum number of PPs per PV as well as dividing the maximum number of PVs in the VG by this factor, so the maximum diskspace held by the VG is final!)

2. create LVs/FSs using the old VG as a blueprint. Use JFS2 as filesystem. Use temporary mountpoints to mount the newly created FSs.

2a. Create a (several?) mountgroup(s) for the new filesystems. You can use "mount -t" to mount all the filesystems in such a group so this is a handy device. You do this by adding a "type = <mountgroup name>" line into the FS stanza in /etc/filesystems.

3. Identify static content of the filesystems. This can be copied to the new FSs in advance.

4. Get a downtime to migrate the rest of the data via copy/restore. Tip: you can do it in one pass using the following mechanism:

Code:
# cd /old/fs
# tar -cvf - * | (cd /new/fs ; tar -xf - )

5. umount the old FSs and new , change the temporary mountpoints of the new FSs in /etc/filesystem, mount the new filesystems.

6. let some time pass to make sure everything is ok. You can still mount the old FSs to temporary mountpoints if something is (supposed to be) missing.

7. after a "varoffvg oldvg" and "exportvg oldvg" delete the devices of the SCSI devices and unplug them.

I hope this helps.

bakunin
# 4  
Old 04-14-2008
Do I need to care about the closed lv (lv110, lv102,lv68,lv103)? Is that the db2 unmanaged database?

I think I will do just a copy and restore so there will be a downtime because Bakunin is right with the PPs. Can't mirror without the same PP size.

itik

Last edited by itik; 04-14-2008 at 04:41 PM..
# 5  
Old 04-14-2008
Quote:
Originally Posted by itik
Do I need to care about the closed lv (lv110, lv102,lv68,lv103)? Is that the db2 unmanaged database?
These are just LVs, which are not in use at the moment, because the filesystems on them are unmounted. If you still need them or not is nothing we can find out for you - it might be a database as well as any other type of data, but the reason the LVs are "closed" is because of the FSs they contain are not mounted.

I hope this helps.

bakunin
# 6  
Old 04-15-2008
once again, bakunin, thank you. are you related to the great mikhail of russia.
# 7  
Old 04-18-2008
I have to open this again.

I was able to sync scsi to san with minimal downtime.

Somehow, when I got error adding hdisk-san on the scsi-multiple-hdisk, it give me errors, so I check it on google.

I tried these:

unmount all filesystem first on that vg. (of couse, the /db2logs, you need to tell the user to logout of db2).

chvg -B vg9

mount all filesystems again on that vg9. (you can tell the db2 user to go back)

chvg -t 64 vg9 (you have to play between 8-64)

Then you will be able to add the san-hdisk on the vg9 and mirror all the filesystems. After that, you can remove the old-scsi-hdisk.

By the way, my AIX is still 43 ml 9 and all jfs. Then my next project is to migrate AIX 43 to 53...
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Whats the best way to mirror a rdiff-backup to an external drive and persevere the rdiff history of

Whats the best way to mirror a rdiff-backup to an external drive and persevere the rdiff history of the local copy ? I was thinking rsync ~/rdiffdirectory /directory on external volume also if I did this... rdiff-backup ~/rdiffdirectory /directory on external volume ... (0 Replies)
Discussion started by: briandanielz
0 Replies

2. AIX

IBM SAN Storage DS4700 - Copy Mirror Flashcopy

Hello, Does anyone know how to copy SAN Storage logical disks from IBM TotalStorage Software. I have a SAN Logical Disk of 200GB mounted on my AIX LPAR_1 via fibre channel fcs0 I would like to make an exact copy of the SAN Logical Disk from IBM totalStorage and mount it on AIX LPAR_2 ... (4 Replies)
Discussion started by: filosophizer
4 Replies

3. Solaris

Connect an External SCSI Hard Drive to Ultra 80

Guys, I have googled and checked this forum in detail and couldn't find any satisfactory answers for my problem. I am trying to connect a external SCSI hard Drive(Sea Gate) to a Ultra 80. I connected it powered it up and at OK prompt did : boot -r system comes up and complains about not... (6 Replies)
Discussion started by: ajnabi
6 Replies

4. Solaris

Removable External SCSI Harddrive

Hi guys, I have a solaris 9 operating system on a sun solaris machine and one external removable scsi drive connected to it. When i type the following command this is what is displayed: #format AVAILABLE DISK SELECTIONS: 0. c0t0d0 <DEFAULT cyl 17832 alt 2 hd 255 sec 63>... (6 Replies)
Discussion started by: tlee
6 Replies

5. Solaris

Unix command to remove external SCSI harddrive

Hi All, I have an external scsi harddrive (HD) connected directly to the workstation. I understand when the external HD is connected and turned on, and type in "devfsadm" command. Unix will detect it but not mount the drive. So by typing in "format" command it will display the following: #... (6 Replies)
Discussion started by: tlee
6 Replies

6. AIX

copy lv scsi to san

Hi All, Regarding my migration of (multiple PV) scsi to san (single PV). I was able to copy lv from scsi to san. The only problem is how can I remove the old lv/old fs to put up the new lv/ old fs. If I try to mount the new lv/old fs, it will have error "There is no plausible log device for... (2 Replies)
Discussion started by: itik
2 Replies

7. UNIX for Dummies Questions & Answers

External SCSI hard drive

Someone gave me a small external SCSI hard drive for my SunOS 5.8 test system. How do I make Unix see the hard drive? (2 Replies)
Discussion started by: FredSmith
2 Replies

8. UNIX for Dummies Questions & Answers

Connecting an external SCSI drive to a unix computer

I am interested in booting up my unix computer by connecting an external SCSI drive( intergraph) to it. The unix box is also an intergraph computer. Whenever I boot it, it gives me an error that says Drive not ready, Insert Boot Diskette in A. What am I doing wrong? Any input would be... (3 Replies)
Discussion started by: teruotor
3 Replies

9. Solaris

mounting an external scsi tape drive

hi- I just installed a quad gigaswift ethernet scsi card to my sunblade 150. I checked with the docs, and got all of the required drivers on the box. Now, I'm trying to mount an external scsi tape drive with no luck. I set the scsi address on the external drive to 0. Here's what I'm coming... (9 Replies)
Discussion started by: ECBROWN
9 Replies

10. UNIX for Dummies Questions & Answers

Mirror 4meg SCSI to Larger

I have a Unix based system running my POS (Point of sale) system that uses two 4.1 gig hard drives. I use the ./diskcopy command to mirror master to Backup My problem is 4.1 gig hard drives are no longer available new so I need to move to a larger cap drive but for my command to work the... (3 Replies)
Discussion started by: dolphin41
3 Replies
Login or Register to Ask a Question