IBM i Global

 View Only
Expand all | Collapse all

IBM i disk device representation on the IFS

  • 1.  IBM i disk device representation on the IFS

    Posted Thu March 09, 2023 09:10 PM

    With AIX you can build your OVA just running a DD to copy the data in your disk device representation to a file, and you can add your OVF to the mix to create a portable boxed LPAR migration file.

    I have created something similar with IBM i , but requires an external storage to map the same disks in a Linux box, so you can DDuplicate your disk devices to files.

    I am trying to find a way to do something similar to the AIX DD procedure, even when you have internal disks. 

    Does anyone know a way to get a device representation from your disks to DD to a file, or any other mechanism to read disk data and send it to an image file?

    This could help on cloud migrations, building DR-as-a-Service scenarios, creating hot-sites, creating an alternative full-system-backup mechanism based on disk copy, and probably more interesting stuff.



    ------------------------------
    Diego KESSELMAN BARRIONUEVO
    ESSELWARE Soluciones, SA de CV
    dkesselman@esselware.com
    ------------------------------


  • 2.  RE: IBM i disk device representation on the IFS

    IBM Champion
    Posted Fri March 10, 2023 02:29 AM
    Edited by Satid Singkorapoom Fri March 10, 2023 07:46 AM

    Dear Diego

    >>>> Does anyone know a way to get a device representation from your disks to DD to a file, or any other mechanism to read disk data and send it to an image file? <<<<

    In IBM i, we have this thing called "save file" object to which you can save anything in IBM i.  A save file object can be FTPed in binary mode to another IBM i system and its data restored to the target IBM i. It can also be FTPed to any other OS's flat file system but cannot be used in any meaningful way. IBM i also provides a command SAVSTG which you can save the sector-by-sector data (only of permanent objects as opposed to temp objects) in IBM i to a tape device (not sure about to save file).  But I just found that SAVSTG was somehow removed from IBM i as of release 7.2.  I never use this command at all in my 31 years with IBM i. The problem here is that the save file object and IBM i's unique disk sector format are recognized only by IBM i and no other OSs. 

    The answer to your question is that someone has to build from scratch a SW utility that understands IBM i unique 520-byte disk sector format used by IBM i internal disk which is possible in principle. But I do not think non-IBM entity will be able to get the needed information from IBM as it is IBM proprietary information.   I see that your approach published in LinkedIn ( IBM i - Migration to the cloud exporting to OVA (no PowerVC required) at https://www.linkedin.com/pulse/ibm-i-migration-cloud-exporting-ova-powervc-diego-kesselman ) and PowerVC are the best one can get now although with the stated requirements.  They are smart as they utilize 512-byte disk format that IBM i was enhanced to accommodate for (in IBM i 6.1) when it supported open storage SAN.  To write a new utility that works on IBM i 520-byte disk format can be a very challenging enterprise.

    Or you can try to convince IBM Rochester to totally abandon the use os 520-byte sector format. Since IBM i now can handle 512-bytes format with open storage disk, I imagine it is possible to also change to use 512-byte for internal disk.  If this can happen, things can get more convenient for your purpose.



    ------------------------------
    Education is not the learning of facts but the training of the mind to think. -- Albert Einstein.
    ------------------------------
    Satid S.
    ------------------------------



  • 3.  RE: IBM i disk device representation on the IFS

    Posted Fri March 10, 2023 08:03 AM

    Hello Satid,

    thanks for you answer. As long as I know you can only use SAVSTG to a TAPE device, and makes sense, because you can't save the backup to the device you are reading data from (the save file on the ASP).

    Unfortunately PowerVC cannot create OVAs from internal disk, only from external storage devices, so that is the dilema.

    Perhaps I need to create a new IBM Ideas entry asking for a SAVSTG command that saves to a remote optical image catalog (NFS)



    ------------------------------
    Diego KESSELMAN BARRIONUEVO
    General Manager
    ESSELWARE Soluciones, SA de CV
    CDMX DIF
    ------------------------------



  • 4.  RE: IBM i disk device representation on the IFS

    Posted Mon March 13, 2023 08:05 AM

    Satid,

    IBM i does not support 512-btye block size. It is actually the IBM Storwize SAN storage which was modified to support the IBM i 520-byte block size. 



    ------------------------------
    Steve Pavlichek
    ------------------------------



  • 5.  RE: IBM i disk device representation on the IFS

    IBM Champion
    Posted Mon March 13, 2023 09:47 PM
    Edited by Satid Singkorapoom Mon March 13, 2023 10:39 PM

    Dear Steve

    Thanks for your information which is quite a surprise for me. I hope your information is accurate. All the information at the time this support was rolled out was mentioned with regard to IBM i 6.1 which made me think the support was from IBM i itself. 

    Here is one sample from the defunct IBM Systems Magazine I still have : 

    [QUOTE]

    IBM i has been able to attach to 512-byte open storage since early 2008 with the 6.1 release. So far, that connection has required employing VIO server to virtualize open-storage volumes to IBM i, with the IBM i VSCSI client driver providing the "conversion" from 512 bytes to 520 bytes. This conversion involves using one extra 512-byte disk sector for every eight and storing the additional eight bytes from all eight sectors in the ninth.

    [UNQUOTE]

    Here is another from an IBM redbook on IBM i and StorWize : 

    I hope you agree with me that both these samples were written in a way that makes readers think the support is from IBM i itself and therefore a surprise on your revelation! 

    Another point is that virtual disk units created from VIOS's internal disk also have 512-byte sector. If your information is accurate, it implies VIOS also has this modified capability as well. 

    ------------------------------
    Education is not the learning of facts but the training of the mind to think. -- Albert Einstein.
    ------------------------------
    Satid S.
    ------------------------------



  • 6.  RE: IBM i disk device representation on the IFS

    Posted Mon March 13, 2023 10:26 PM

    I guess I should not have been multitasking when I replied. You are correct, 



    ------------------------------
    Steve Pavlichek
    ------------------------------



  • 7.  RE: IBM i disk device representation on the IFS

    IBM Champion
    Posted Mon March 13, 2023 10:49 PM

    Dear Steve

    Thanks for your response.  I have read several articles and watched documentaries in which behavioral scientists tried to inform us that, although many of us can do multitasking, when it comes to tasks requiring precision/accuracy, human multitasking rarely achieves it.  Let the machines do multitasking as they are better than us on this front.  :-)   



    ------------------------------
    Education is not the learning of facts but the training of the mind to think. -- Albert Einstein.
    ------------------------------
    Satid S.
    ------------------------------



  • 8.  RE: IBM i disk device representation on the IFS

    IBM Champion
    Posted Wed March 15, 2023 10:15 AM

    I could have sworn SAVSTG died a long time ago:

    https://www.ibm.com/docs/en/i/7.2?topic=ios-save-storage-savstg-command-restore-storage-process-are-no-longer-provided

    and on my 7.5 system I get:   Command SAVSTG in library *LIBL not found.

    Lots of 7.5 documentation needs updated though.



    ------------------------------
    Robert Berendt IBMChampion
    ------------------------------



  • 9.  RE: IBM i disk device representation on the IFS

    IBM Champion
    Posted Thu March 16, 2023 07:23 AM

    Remove all references to SAVSTG from | IBM Power Ideas Portal



    ------------------------------
    Robert Berendt IBMChampion
    ------------------------------



  • 10.  RE: IBM i disk device representation on the IFS

    Posted Fri March 10, 2023 11:56 AM

    That is a very interesting question.  To my knowledge, IBM i does not have any direct access to drive images built into the operating system like AIX or other Unix environment does, nor would it likely be useful if it did given the nature of scattered single level storage constantly changing all of the time.   

    I'm ignoring IASP here, which does have the ability to freeze, because OVA implies bootable image, and that means *SYSBAS

    Even with external storage based replication technologies, all drives must be captured at exactly the same point in time to get a crash consistent copy.

    That pretty much means you are only going to get a useable copy if the IBM i LPAR is powered off, so doing the copy on the same LPAR is pretty much a non-starter.

    I think the closest you can get to that without external storage would be to configure VIOS to own the internal disks for its file system, and create file backed storage pools in VIOS that are shared as disks to an IBM i client lpar.  You would be able to copy those files, or do as you did with external storage and mount those same volumes to a AIX or linux client lpar and do a DD.  

    You might be able to do the same with iVirtualization aka i hosting i.  

    Satid's points about 520 byte sectors likely apply to using these images as an OVA.  How exactly is Satid NOT an IBM Champion?  He answers practically every question on this forum, and he answers them quickly and correctly.  In this case using VIOS for virtualization of a file backed disk, the 512 to 520 sector conversion happens within the VIOS VSCSI emulation layer.  I'm sure that if you copy that VIOS O/S file which backs the IBMi disks and put it on another VIOS with the same configuration that it will work, because I have done it.  Likewise, if you map that file to an AIX lpar and use DD to make a copy, that copy would be able to be copied byte for byte back to the exact same environment and would work. 

    I'm only familiar with OVA's from some a i86 perspective - virtual HMC and the like.  How they would handle a 520 sector disk image mapped onto a 512 byte image is a big question.

    For an OVA solution, you might have better luck with a SAVSYS + full system backup to a virtual DVD formatted as *UDF.  You can make these pretty big, and they are bootable even as DVD images.  It would be an install/restore process rather than a runnable system image, but it would get you there in a more supported fashion.



    ------------------------------
    Vincent Greene
    IT Consultant
    Technology Services
    IBM
    Vincent.Greene@ibm.com


    The postings on this site are my own and don't necessarily represent IBM's positions, strategies or opinions.
    ------------------------------



  • 11.  RE: IBM i disk device representation on the IFS

    Posted Thu March 16, 2023 04:04 AM

    Hi Diego,

    the only way I think is to use virtual tape which is build by external storage and emulates virtual tapes. So you can save the system data to images and also restore (and boot) from these images in the cloud. These virtual tape images are also "movable" by FTP or something else. And for restoring is isn't necessary to have the same disk layout at the target system.

    https://www.ibm.com/docs/en/i/7.5?topic=storage-i-virtual-tape

    Regards, Harald



    ------------------------------
    Harald Stürner
    Senior Consultant IBM Power Systems
    PROFI Engineering Systems AG Germany
    Stuttgart
    ------------------------------