Creating custom Boot Camp configurations in Parallels Desktop 4

Discussion in 'Installation and Configuration of Parallels Desktop' started by Angel Garcia, Mar 17, 2009.

  1. Angel Garcia

    Angel Garcia Member

    Messages:
    23
    There's an archived article that describes the simple procedure for creating custom Boot Camp configurations under earlier versions of Parallels Desktop. In latest version (currently 4.0 build 3810) there's a similar procedure but it's a bit more complicated.

    In this scenario, the Mac's hard disk is partitioned into 3 volumes:
    - Macintosh HD (HFS+, Mac OS default)
    - Data (NTFS)
    - Windows (NTFS, created by Boot Camp Assistant)

    Instructions for setting up this partition scheme are here (3-Partitions scheme with Boot Camp and Parallels Desktop).

    The output for Terminal's command "diskutil list" is as follows:

    Code:
    /dev/disk0
       #:                   TYPE NAME           SIZE       IDENTIFIER
       0:  GUID_partition_scheme               *298.1 Gi   disk0
       1:                    EFI                200.0 Mi   disk0s1
       2:              Apple_HFS Macintosh HD   145.5 Gi   disk0s2
       3:   Microsoft Basic Data Data           50.2 Gi    disk0s3
       4:   Microsoft Basic Data Windows        101.9 Gi   disk0s4
    
    MacFUSE and NTFS-3G for Mac are installed in Mac OSX. They are required for read/write at the Data partition from the Mac side, but they wouldn't be neccesary if the Data partition is FAT32.

    When Windows boots natively it can read and write the Data volume perfectly. However, when running the Boot Camp Windows inside a Virtual Machine the partition is detected but it cannot be accessed. Here's the procedure for allowing it.

    1- Locate the file of your Boot Camp virtual machine in Finder (~/Documents/Parallels), i.e. BootCamp.pvm. Ctrl-click the file, then "Show package contents".

    2- Locate a file with extension .hdd, in my case Hitachi HTS543232L9SA02.hdd. Ctrl-click this file, then "Show package contents".

    3- There's a file named DiskDescriptor.xml. First, make a duplicate as backup (cmd-D), then open it with TextEdit (ctrl-click, Open with...)

    The <StorageData> section has several <Storage> sub-sections. The last one should be pointing to the current Boot Camp partition:

    Code:
    <StorageData>
        ....
    
        <Storage>
            <Start>411453440</Start>
            <End>625141759</End>
            <Blocksize>1008</Blocksize>
            <Image>
                <GUID>{5fbaabe3-6958-40ff-92a7-860e329aab41}</GUID>
                <Type>Bootcamp</Type>
                <Flags/>
                <File>[B]/dev/disk0s4[/B]</File>
            </Image>
        </Storage>
    </StorageData>
    
    In order to grant access to our Data partition we need to add a new <Storage> section after that one. First we need to gather some data:

    Start, End:
    Use the Partition Inspector application included with the rEFIt package. You don't need to install rEFIt, simply download the DMG file and run the Partition Inspector application located inside. It produces an output like this:

    Code:
    *** Report for internal hard disk ***
    
    Current GPT partition table:
     #      Start LBA      End LBA  Type
     1             40       409639  EFI System (FAT)
     2         409640    305620663  Mac OS X HFS+
     3      305882808    411191295  Basic Data
     4      411453440    625141759  Basic Data
    
    Current MBR partition table:
     # A    Start LBA      End LBA  Type
     1              1       409639  ee  EFI Protective
     2         409640    305620663  af  Mac OS X HFS+
     3      305882808    411191295  07  NTFS/HPFS
     4 *    411453440    625141759  07  NTFS/HPFS
    
    ...
    
    The Data partition is number 3, so the Start and End values are 305882808 and 411191295 respectively.

    File:
    The Data partition is disk0s3 (see the output of "diskutil list" above). So the <File> tag for the Data partition is /dev/disk0s3


    Now, back to DiskDescriptor.xml file, duplicate the last <Storage> section and change the Start, End and File values in the copied section leaving all other values unchanged. The result for the <StorageData> section will be this:

    Code:
    <StorageData>
        ....
    
        <Storage>
            <Start>411453440</Start>
            <End>625141759</End>
            <Blocksize>1008</Blocksize>
            <Image>
                <GUID>{5fbaabe3-6958-40ff-92a7-860e329aab41}</GUID>
                <Type>Bootcamp</Type>
                <Flags/>
                <File>/dev/disk0s4</File>
            </Image>
        </Storage>
    [COLOR="Red"]    <Storage>
            <Start>[B]305882808[/B]</Start>
            <End>[B]411191295[/B]</End>
            <Blocksize>1008</Blocksize>
            <Image>
                <GUID>{5fbaabe3-6958-40ff-92a7-860e329aab41}</GUID>
                <Type>Bootcamp</Type>
                <Flags/>
                <File>[B]/dev/disk0s3[/B]</File>
            </Image>
        </Storage>[/COLOR]
    </StorageData>
    
    Save the file, open Parallels Desktop and start the BootCamp virtual machine. Now the Data partition will be fully available.

    NOTE: For some reason, the Virtual Machine may fail to start unless the Windows volume is ejected. If you receive an error "Cannot connect to the hard disk..." then just eject the Windows volume prior to starting the Virtual Machine.
     
    Last edited: Mar 17, 2009
  2. MarkusS

    MarkusS Bit poster

    Messages:
    1
    2nd disk

    Hi, does it work with a secont internal disk? Do you know how to configure the partitions in a second disk so that they work just like the "Data" partition?
     
  3. Ynot

    Ynot Pro

    Messages:
    387
    Hmmm. In PD4 you should be able to select which partitions to connect to your virtual disk from real. It's available in the configuration window of the HDD, but be sure, that advanced settings checkbox is on.
     
  4. Ynot

    Ynot Pro

    Messages:
    387
    Nope, one physical disk should be connected as one virtual. But you can select which partitions from disk to connect to virtual one.
     
  5. Angel Garcia

    Angel Garcia Member

    Messages:
    23
    I'm using a MacBook Pro, so I have no chance of trying with second internal hard disk. Check out this thread if you want to see what happens when trying to use a non-standard disk configuration with several internal disks and Parallels Desktop 4.

    Thank you for your reply, but I you are missing this information from the original post:

    When Windows boots natively it can read and write the Data volume perfectly. However, when running the Boot Camp Windows inside a Virtual Machine the partition is detected but it cannot be accessed.

    The Data partition is shown as a drive at My Computer, but trying to access it shows the message "this drive is unformatted, do yo want to format it now?". I've even tryed to format it by answering "Yes", but the drive is read-only and nothing else can be done.

    I assure you that I've read all documentation available, tryed absolutely everything, and the above is the only way to make it work properly. I had submitted two support tickets (Parallels #650617 and #691863) and the only solution they could give me was to access the Data partition as network share, which is terribly slower compared to direct access and also changes the drive letter assignments between Boot Camp and VM.
     
  6. Ynot

    Ynot Pro

    Messages:
    387
    I've read it. By default - Parallels connects only one partition. But the information about other partitions still present on virtual disk, but not connected if you not specify to connect it. As i see in your post, you have only one Storage section with real partition in the xml file.

    See at picture one, there are no any selections on the screen, but after clicking advanced settings - you can select which partitions to "connect" to virtual disk. If you connect both of your partitions you will see more than one storage section with the real partition.

    So, i connected both NTFS partitions and boot into my windows on bootcamp. Also i put some files on partition and you can see it is readable.
     

    Attached Files:

  7. OliverC

    OliverC Bit poster

    Messages:
    1
    Will this still work in Parallels Desktop 5?

    Hello everybody,

    I've been using exactly this setup for quite some time now (with a shared FAT32 partition) and it works like a charm.

    Today I've received my upgrade disk to PD5… Will this setup continue to work or did anybody with such a setup face upgrade issues?

    Thanks & Cheers,
    oliver
     
  8. Angel Garcia

    Angel Garcia Member

    Messages:
    23
    Thank you for your contribution, but obviously (as seen in your attached pic #2) you are using a different HD scheme than me, probably with more than one internal disk drives. And you don't mention if you are using that Windows also as Boot Camp (native boot).

    This problem applies to a MacBook, with one internal HD, and three partitions: Mac OS - Data - Windows. The Windows partition must be the last one because that's the only way allowed by Boot Camp (remember that we must be able to natively boot Windows, not only using it inside a VM). Believe me, I've spent literally months in order to achieve a way to make everything work, and I've tryed literally *everything*, including the advanced settings you mention.

    My XML file has several Storage sections. In my post I'm showing only the last one, as it's the relevant section used in my procedure (my instructions specify "... duplicate the last <Storage> section ...").
     
  9. Angel Garcia

    Angel Garcia Member

    Messages:
    23
    My recommendation is to keep your PD4-based setup and forget about PD5, or use it only in a different computer, with different settings.

    I had been invited to the PD5 beta program (with access to the Beta forum), and I discarded the idea of uprading to PD5 due to the fact that Parallels definitely abandoned any chance for advanced users to configure any non-stritctly-standard disk configuration. If you have access to the Parallels Desktop 5 Private Beta forum, you'll find many examples:

    http://forum.parallels.com/showthread.php?t=93224

    Here's a clear example quoted from the above thread:

    He talks about external USB drives, but the lack of advanced HD settings also affect us. So unless you have a really important reason to upgrade (i.e. a new PD5 feature you can't live without) I'd recommend you to keep your happily running Parallels Desktop 4.
     
  10. AnnetteI

    AnnetteI Bit poster

    Messages:
    1
    got it working with the above PD4 set up but... data1 disapears in MACOSX

    Hi I changed the file as it was mentioned above and it worked with PD5, however I cannot access my data harddrive in the mac system does anyone know how to fix this so I can access it using both MAC OX 10.6 and Windows 7. I am using the bootcamp partition incase

    Thanks
     
  11. Angel Garcia

    Angel Garcia Member

    Messages:
    23
    The Data partition is accessed in different ways depending on the Parallels Virtual Machine to be running or not. If you aren't running Parallels Desktop, then you should see the Data volume in your desktop and the Finder. If not, then open the Disk Utility, select the Data volume, and click Mount.

    If you want to access the Data partition simultaneously from the PD Virtual Machine and from Mac OSX, then you must open the Virtual Machine Settings, go to Shared Folders, then enable the options "Share all Windows disks with Mac OS X" and "Mount virtual disks on Mac OS X desktop".

    Note than the above options are from the Parallels Desktop 4, and the texts have been translated from the spanish version so they may not be accurate. But you shouldn't have any difficult on finding the proper options in PD5.
     

Share This Page