Trunk 8093- Deploying Image Failing, Partition Size Error



  • Trunk Version: 8093
    I am having an issue deploying an image. The deployment keeps failing because of a partition size error. I have included the screenshot of the error saying “Target partition size (525 MB) is smaller than source (525MB)”. The upload of this image was on an 80 GB HDD and the imaged was deployed to a different PC with the same size and specs as the upload computer HDD. If I put in a hard drive that is bigger than 80 GB, then the image deploys successfully. The Windows 10 image has two partitions, a 500 MB System reserved, and a 74.04 GB C://

    Here are the specs of the image I am trying to deploy:
    Operating System: Windows 10
    Image Type: Single Disk- Resizable
    Partition: Everything
    Compression: 7

    0_1465931602952_IMG_0902.JPG
    Any help will be fantastic!

    Thanks


  • Developer

    @LJedi Could you please upgrade to the latest trunk and see if the d1.fixed_size_partitions is now created properly in your case?

    Thanks Tom for looking into this and fixing it!


  • Senior Developer

    @Wayne-Workman Could be anything. Should be fixed in latest though.

    The 1 was being missed I believe, due to the line 73 @Sebastian-Roth pointed out. The 1 would ONLY be created if there was more than one extfs AND/OR ntfs partition present.

    That would mean a disk with 5 partitions might only have one extfs or ntfs partition. The one would be missed. I have corrected this suspicion of mine and updated the inits after testing upload/download still worked. I don’t have a way to confirm the exact issue itself though.



  • @Sebastian-Roth said in Trunk 8093- Deploying Image Failing, Partition Size Error:

    As a quick workaround, can you please edit that file on the FOG server using your favorite text editor and simply put 1: in.

    Why is it that so often that 1: is missing?


  • Developer

    @LJedi Ok, thanks for testing and letting us know.

    @Tom-Elliott I think the issue is caused by line 116 in the upload script. As well line number 73 is likely not doing exactly what we want I suppose.



  • @Sebastian-Roth

    After editing that file, the image deployed successfully.

    Here is that screenshot with the commands before I deployed that image. Thanks for your help.

    0_1466114629695_IMG_0907.JPG


  • Developer

    @LJedi Thanks heaps! So here we go. It does resize your first partition on deploy (shrinking it by only a few sectors). The problem is that you d1.fixed_size_partitions file is empty which shouldn’t be the case. As a quick workaround, can you please edit that file on the FOG server using your favorite text editor and simply put 1: in.

    Then please run another debug deploy session and issue the following commands before even starting the deploy:

    mkdir -p /mnt
    ntfs-3g /dev/sda1 /mnt
    ls -al /mnt/Boot/BCD*
    umount /mnt
    ntfs-3g /dev/sda2 /mnt
    ls -al /mnt/Boot/BCD*
    umount /mnt
    

    Take a picture and then start deploying (command fog)… Working now?



  • @Sebastian-Roth

    Here ya go:

    0_1466111437910_IMG_0906.JPG


  • Developer

    @Tom-Elliott said:

    Is there anything in the d1.fixed_size_partitions file? I see a 1 byte which means something is there, but what?

    My guess it’s just a simple new line in that file. But even then I am wondering why it does not like sda1 because in the partition text files it seems like sda1 is not being touched (resized) and therefore shouldn’t cause an issue.

    @LJedi Can you please do a debug deploy. After you see the error and got back to the shell please run sfdisk -d /dev/sda and post a picture here.


  • Senior Developer

    Is there anything in the d1.fixed_size_partitions file? I see a 1 byte which means something is there, but what?



  • @Sebastian-Roth

    Here are my results:

    ls -al Optiplex745Win10/
    total 7519176
    drwxrwxrwx  2 root root       4096 Jun 16 10:19 .
    drwxrwxrwx 32 root root       4096 Jun 14 12:10 ..
    -rwxrwxrwx  1 root root          1 Jun 14 09:52 d1.fixed_size_partitions
    -rwxrwxrwx  1 root root    1048576 Jun 14 09:53 d1.mbr
    -rwxrwxrwx  1 root root        190 Jun 14 09:53 d1.minimum.partitions
    -rwxrwxrwx  1 root root         30 Jun 14 09:52 d1.original.fstypes
    -rwxrwxrwx  1 root root          0 Jun 14 09:52 d1.original.swapuuids
    -rwxrwxrwx  1 root root  325089680 Jun 14 09:53 d1p1.img
    -rwxrwxrwx  1 root root 7373459536 Jun 14 10:15 d1p2.img
    -rwxrwxrwx  1 root root        190 Jun 14 09:52 d1.partitions
    
    
    /Optiplex745Win10# cat d1.partitions
    label: dos
    label-id: 0x1288f3ca
    device: /dev/sda
    unit: sectors
    
    /dev/sda1 : start=        2048, size=     1024000, type=7, bootable
    /dev/sda2 : start=     1026048, size=   155273216, type=7
    root@RoyFogMasterNode:/images/Optiplex745Win10#
    
    cat d1.minimum.partitions
    label: dos
    label-id: 0x1288f3ca
    device: /dev/sda
    unit: sectors
    
    /dev/sda1 : start=        2048, size=     1024000, type=7, bootable
    /dev/sda2 : start=     1026048, size=    35327996, type=7
    
     cat d1.fixed_size_partitions
    
    root@RoyFogMasterNode:/images/Optiplex745Win10#
    

  • Developer

    @LJedi Please check the text file /images/<imagename>/d1.fixed_size_partions on your FOG server. From what you describe I suppose the file is empty but it should read 1 or 1: to work properly. Please show us the output of ls -al /images/<imagename>, cat /images/<imagename>/d1.partitions and cat /images/<imagename>/d1.minimum_partitions as well.



  • Did you change the Image Type without re-uploading? Also, a resizable image should never have this error, because it’s shrank way down to fit on basically any drive it’s deployed to and then expanded afterwards.

    Because you only have two partitions, I am assuming this is a MBR type image, taken from a BIOS type computer? Is the destination computer in BIOS mode?


 

468
Online

41.8k
Users

12.3k
Topics

116.0k
Posts