How-To : Using Oscdimg.exe for Building W7.x, W8.x, WinPE Bootable DVD ISO Image

Discussion in 'Windows 8' started by MSMG, Jan 23, 2014.

  1. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    2,011
    4,503
    90
    #1 MSMG, Jan 23, 2014
    Last edited by a moderator: Apr 20, 2017
    How-To : Using Oscdimg.exe for Building W7.x, W8.x, WinPE Bootable DVD ISO Image


    The Windows 7.x, Windows 8.x, WinPE CD-ROM can be started from BIOS Firmware or from UEFI Firmware.

    The CD-ROM has two boot catalog entries. One platform ID entry corresponds to the BIOS, and one corresponds to the UEFI.

    Requirement : oscdimg.exe from WADK 8.1 Tools

    To create an ISO image for Windows 7.x/8.x/PE on a CD-ROM which supports Booting from BIOS Firmware follow these steps:

    Code:
    oscdimg.exe -h -m -o -u2 -bx:\w81\boot\etfsboot.com -lWin81 c:\w81 c:\w81.iso
    
    To create an ISO image for Windows 7.x/8.x/PE on a CD-ROM which supports Booting from UEFI Firmware follow these steps:

    Code:
    oscdimg.exe -h -m -o -u2 -udfver102 -bootdata:1pEF,e,bc:\w81\efi\microsoft\boot\efisys.bin -lWin81 c:\w81 c:\w81.iso
    
    To create an ISO image for Windows 7.x/8.x/PE on a CD-ROM which supports Booting from both the BIOS and UEFI Firmware follow these steps:

    Code:
    oscdimg.exe -h -m -o -u2 -udfver102 -bootdata:2#p0,e,bc:\w81\boot\etfsboot.com#pEF,e,bc:\w81\efi\microsoft\boot\efisys.bin -lWin81 c:\w81 c:\w81.iso
    


    Definitions :

    Oscdimg command arguments :

    -h : Includes Hidden Files or Folders.

    -m : Ignores the maximum size limit of the image.

    -o : Optimizes storage by encoding duplicate files only one time.

    -oc
    : Optimizes storage by encoding duplicate files only one once. It does a binary compare on the files and is slower.

    -u2 : Produces an ISO image that has only the Universal Disk Format (UDF) file system on it.

    -udfver102 : Writes UDF revision 1.02 (Supported: Windows 98 and later)

    -udfver150 : Writes UDF revision 1.50 (Supported: Windows 2K and later) This is the Default Format

    -udfver200 : Writes UDF revision 2.00 (Supported: Windows XP and later)

    -bootdata : Specifies a multiboot image. This image uses an x86-based boot sector as the default image.

    This sector starts the Etfsboot.com boot code.

    A secondary EFI boot image starts an EFI boot application.

    -l
    : ISO Volume Label

    c:\w81 : Represents the source root path of the files for the image.

    c:\w81.iso : Represents the output image file.


    Bootdata command arguments :

    2
    : Specifies the number of boot catalog entries.

    # : Functions as the separator between root entries to be put into the boot catalog.

    p0
    : Sets the platform ID to 0 for the first, default boot entry for the BIOS.

    e
    : Specifies the floppy disk emulation in the El Torito catalog.

    -bc:\w81\boot\etfsboot.com : Puts the specified file (Etfsboot.com) in the boot sectors of the disk.

    #
    : Functions as the separator between the first and second boot entries.

    pEF : Sets the platform ID to “EF," as defined by the UEFI specification.

    bc:\w81\efi\microsoft\boot\efisys.bin : Puts the specified file (Efisys.bin) in the boot sector of the disk.

    Efisys.bin is the binary floppy disk layout of the EFI boot code.

    This disk image contains the files that are used to start from the EFI firmware in the Efi\boot\x64boot.efi folder.
     
  2. Oz

    Oz MDL Expert

    Sep 1, 2009
    1,043
    701
    60
    #2 Oz, Jan 23, 2014
    Last edited by a moderator: Apr 20, 2017
    All this info has already been posted years ago

    Code:
    http://forums.mydigitallife.net/threads/8128-How-to-create-official-Windows-7-MSDN-TechNet-ISO-s-FOR-EDUCATIONAL-PURPOSES-ONLY
    

    Actually funny to read the comments on the first few pages, some people really think they know it all, but in reality know very little.
     
  3. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    2,011
    4,503
    90
    #3 MSMG, Jan 24, 2014
    Last edited by a moderator: Apr 20, 2017
    (OP)
    Ya, But still people are still asking about this often so I had to post it and moreover the below thread uses cdimage.exe which is quite old right and oscdimg.exe is more advanced and better

     
  4. genet

    genet MDL Novice

    Mar 10, 2013
    36
    23
    0
    You don't need -m option if UDF (-u2) is used.

    You may also add -udfver102 option to first command line.
     
  5. Boops

    Boops MDL Addicted

    Jan 5, 2008
    668
    559
    30
    Thanks, ;), the information is very useful me.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. spidernz

    spidernz MDL Senior Member

    May 20, 2011
    273
    67
    10
    Ahh great was wondering why my dvd iso never had uefi showing. Was only using the old bios one :wallbash:


    Curious can one use oscdimg.exe to make a windows xp iso too?
     
  7. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    2,011
    4,503
    90
    yes you can use oscdimg.exe for making windows xp iso's


     
  8. spidernz

    spidernz MDL Senior Member

    May 20, 2011
    273
    67
    10
    Would be able to write the command up please.

    I tried doing it assuming it's similar to "oscdimg.exe -h -m -o -u2 -bx:\w81\boot\etfsboot.com -lWin81 c:\w81 c:\w81.iso" but didn't quite work.
    We use "Microsoft Corporation.ima" right?
     
  9. MSMG

    MSMG MDL Developer

    Jul 15, 2011
    2,011
    4,503
    90
    I think you need to use -h -n -j1 -m -o -u1 -b<BootImgFilename> -l<VolumeLable> <SourceFolder> <TargetISOFileName>

    for more info type oscdimg and then oscdimg -help with one of the commands it shows at first.


     
  10. murphy78

    murphy78 MDL DISM Enthusiast

    Nov 18, 2012
    6,787
    10,365
    210
    #10 murphy78, Mar 10, 2014
    Last edited by a moderator: Apr 20, 2017
    Don't know why you'd want to iso a dinosaur, but basically yes... you just need to point it at the correct directories and give it the -b option pointed at an appropriate etfsboot.com
    The command would be something like:
    Code:
    oscdimg -bc:\eltoritostuff\etfsboot.com -lYourXPLABELmax32chars c:\xpsourcedisk\ c:\temp\outputfile.iso
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  11. Oz

    Oz MDL Expert

    Sep 1, 2009
    1,043
    701
    60
    Today CDIMAGE & OSCDIMG are pretty much the same. Years ago OSCDIMG was a stripped down version of CDIMAGE, handed out to OEM's.
     
  12. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    13,693
    15,186
    340
    #12 Enthousiast, Dec 17, 2014
    Last edited: Dec 21, 2014
    Thanks for this helpfull information.

    I've just one (maybe obselete) question about making a x86 iso, i want to use the first command: oscdimg.exe -h -m -o -u2 -bx:\w81\boot\etfsboot.com -lWin81 c:\w81 c:\w81.iso

    Why isn't the argument: -udfver102 used in bios only bootable iso?

    Never mind, i figured it out myself.