NEW iMac problems
-
Hi @sebastian-roth ,
Attached link to Download d1.mbr .
I attached the content of d1.partitions
root@fogserver:/images/MASTERMACOS2017# vi d1.partitions label: gpt label-id: EB5F756F-5E64-4990-8B9C-5F2826AFDEC2 device: /dev/sda unit: sectors first-lba: 34 last-lba: 234441614 /dev/sda1 : start= 40, size= 409600, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=F803B6B4-FAF1-4700-814F-4CC7B6AA693D, name="EFI System Partition" /dev/sda2 : start= 409640, size= 232762432, type=48465300-0000-11AA-AA11-00306543ECAC, uuid=2CA043B5-1BA4-4052-AC59-AA30F67E556D /dev/sda3 : start= 233172072, size= 1269536, type=426F6F74-0000-11AA-AA11-00306543ECAC, uuid=989E4FD8-2721-4B58-A6B4-24E3334F1165, attrs="GUID:49"
-
@Abuelika Sorry for taking a while to get onto this. Too many other things going on at the moment. I tried your d1.mbr now and it worked like a charm. Then I looked at the pictures you posted more closely again and I am sure I see what’s wrong here. See the message printed in red:
GPT PMBR size mismatch (234441647 != 61279343) will be corrected by w(rite).
When I first saw this I thought FOG is doing something wrong but then I noticed the second number being smaller than the first and so I tried your d1.mbr on a smaller destination disk and that failed with the exact same error (just different number). You cannot deploy a non-resizable image to a smaller destination disk!
So what you have to do is create a new image in the FOG web UI, e.g. name it
MASTERMACOS2017_RESIZABLE
and setImage Type
to “Single Disk - Resizable”. Do not delete your other image yet. Keep this as a backup for now just in case something is going wrong with the resizable image. Now set your master Mac machine to use this newly createdMASTERMACOS2017_RESIZABLE
image and schedule an upload task. Let it do it’s job. Then configure the machine you wanted to deploy to use the new resizable image as well and do the deploy. You might want to keep the debug kernel options for now just in case it runs into an error again.Please let us know how it went and post a picture in case you run into an issue.
-
Hi @sebastian-roth when I try to capture the image, the following error appears:
-
@Abuelika Oh … why the he** do I always forget about we are not able to resize HFS+ filesystems. Don’t know why! Sorry for that. Just forget what I said!
So this leaves you to maybe try shrinking the Mac OS X system by hand I am afraid. Search the web on how to do this. I am not sure this can be done at all but I think I’ve read about it somewhere.
Would be an awesome feature to add to FOG to have resize work for Mac OS X as well. But seems like there are no reliable tools out there to do this as of now.
-
I have been reviewing, and the source is a 120Gb disk and the destination is 250Gb.
It is rare that the problem is of disk size, when the source is smaller than the destination.
tnx!
-
Is it possible this is related to the 32 bit issue in HFS as it was in the other thread @Sebastian-Roth?
-
@Tom-Elliott Don’t think so. But what do I know…?
@Abuelika Please do me a favour and boot up both clients in debug task (capture or deploy, doesn’t matter). When you get to the shell run
fdisk -l /dev/sda
(that’s for the source machine andfdisk -l /dev/nvme0n1
… Post pictures here.Ahhhhhha, now that I am writing this I have an idea. Possibly we are not able to move from a SATA disk (/dev/sda) to one of these new disks (/dev/nvme0n1). Not sure if I can test this.
Give this a try: Make a backup copy of the partition layout file and then edit those files which you find in
/images/MASTERMACOS2017/d1.partitions
. Make it look like this:label: gpt label-id: EB5F756F-5E64-4990-8B9C-5F2826AFDEC2 device: /dev/nvme0n1 unit: sectors first-lba: 34 last-lba: 234441614 /dev/nvme0n1p1 : start= 40, size= 409600, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=F803B6B4-FAF1-4700-814F-4CC7B6AA693D, name="EFI System Partition" /dev/nvme0n1p2 : start= 409640, size= 232762432, type=48465300-0000-11AA-AA11-00306543ECAC, uuid=2CA043B5-1BA4-4052-AC59-AA30F67E556D /dev/nvme0n1p3 : start= 233172072, size= 1269536, type=426F6F74-0000-11AA-AA11-00306543ECAC, uuid=989E4FD8-2721-4B58-A6B4-24E3334F1165, attrs="GUID:49"
Save the file and try deploying the
MASTERMACOS2017
image again. -
Hi @sebastian-roth ,
Source:
Destination:
I have modified “/images/MASTERMACOS2017/d1.partitions” with the information provided and the error is the same.
-
@abuelika This appears to be a 4k disk then? I mean, the sector size is correct for 512, but not for 4096.
E.G.:
234441647 * 512 = 120034123264 (about 120 GB)
234441647 * 4096 = 960272986112 (about 960 GB)Where:
61279344 * 512 = 31375024128 (about 32 GB)
61279344 * 4096 = 251000193024 (about 250 GB)@Sebastian-Roth I don’t know how to handle this anymore. We have to use 512 for blockdev elements. Getting the block size is actually quite easy, though I’m still sure it’s working properly RC’s - but if this is 1.4.4 those changes should be present as well.
-
I imagine, however, resizable or not, this is a problem as the way the disk is presented on one system (512 byte sector sizes) to another system (4096 byte sector sizes).
I know there’s a way to adjust a disks byte sector size. Something like:
blockdev --setbsz 512 /dev/nvme0n1
-
Maybe we can use information from this posting to help us out? It’s coming from Rod Smith directly and he would probably be the guy who knows his stuff considering he wrote gpt disk utilities.
-
Ahh, now I see. Give me a bit of time with this and I am sure I’ll comes up with a solution to this. Though it might sound like a good idea to set the NVME drive to 512 I don’t think this is wise to do. I have a bit of free time tomorrow and will dive into this more deeply…
-
@sebastian-roth I totally understand. I tried in the past and failed miserably, so I don’t mean to put more on your shoulders, I just don’t know how to best approach. In particular, fixing this issue for resize should be simple, but how can we fix for non-resizable images?
-
In the first instance
Many thanks to @sebastian-roth and @Tom-Elliott for the work you are doing.
The fastest solution I have found is the following:
My Solution:
-
Mac with SATA ( Sector size: 512 bytes ) hard disk cloned with “FOG”, we created a “TimeMachine” and restored in iMAC computer with M2 disks ( Sector size: 4096 bytes ) .
-
We create an image with FOG Multiple Partition Image - Single Disk (Not Resizable)
-
Perform a capture of the equipment with disk M2 with “FOG”
-
We deploy the image to all iMac computers with M2 hard disks
Work fine!
-
-
@tom-elliott While I’m not sure what I can add to this thread, I do have to say I have several 4K sata drives that were purchased before I realized that ESXi didn’t support 4K drives (yet). If you need me to test anything (under linux or ms windows) I have the facilities to do so.
-
@Abuelika Good to hear that you could make this work but I think this is a general issue that we’ll be seeing more and we need to figure this out. I’ve dug my head in the sector count swamp and would like to ask you to test something that I came up with.
Hope you still have that 512 based image somewhere. Please edit thed1.partitions
file again and make it look like this:label: gpt label-id: EB5F756F-5E64-4990-8B9C-5F2826AFDEC2 device: /dev/nvme0n1 unit: sectors first-lba: 5 last-lba: 61279312 /dev/nvme0n1p1 : start= 5, size= 51200, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=F803B6B4-FAF1-4700-814F-4CC7B6AA693D, name="EFI System Partition" /dev/nvme0n1p2 : start= 51205, size= 29095304, type=48465300-0000-11AA-AA11-00306543ECAC, uuid=2CA043B5-1BA4-4052-AC59-AA30F67E556D /dev/nvme0n1p3 : start= 29146509, size= 158692, type=426F6F74-0000-11AA-AA11-00306543ECAC, uuid=989E4FD8-2721-4B58-A6B4-24E3334F1165, attrs="GUID:49"
Make sure to get the values for
*-lba
,start
andsize
right. I didn’t change the type or uuid values at all. Then do a deploy to the 4096 machine again. -
okay. now I’m not in the office, tomorrow at 8:00 am I will do the test. I still have the image.
I leave you the content of d1.partition of the new image made to imac with m2, in case you are interested.
label: dos label-id: 0x00000000 device: /dev/nvme0n1 unit: sectors /dev/nvme0n1p1 : start= 2, size= 61279342, type=af
root@fogserver:/images/MASTERMACOS2017_modelnou# ls -l total 28790796 -rwxrwxrwx 1 root root 1024 sep 13 11:01 d1.mbr -rwxrwxrwx 1 root root 29481762309 sep 13 11:17 d1p1.img -rwxrwxrwx 1 root root 132 sep 13 11:01 d1.partitions
-
@abuelika said in NEW iMac problems:
label: dos
What?!??!?! This doesn’t make any sense to me. Mac OS X is UEFI as far as I know, why would they use a legacy DOS/MBR partition layout? You said you transfered the system using TimeMachine? And it does boot properly? That’s crazy I reckon.
-
Hi @sebastian-roth ,
I have modified the file d1.particiones with the facilitated content.
I have now unpacked another iMac with m2 and I’m capturing the image to review the d1.partitions and check the label to see if dos or gpt.
This is the content I have modified from d1.partitions.
label: gpt label-id: EB5F756F-5E64-4990-8B9C-5F2826AFDEC2 device: /dev/nvme0n1 unit: sectors first-lba: 5 last-lba: 61279312 /dev/nvme0n1p1 : start= 5, size= 51200, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=F803B6B4-FAF1-4700-814F-4CC7B6AA693D, name="EFI System Partition" /dev/nvme0n1p2 : start= 51205, size= 29095304, type=48465300-0000-11AA-AA11-00306543ECAC, uuid=2CA043B5-1BA4-4052-AC59-AA30F67E556D /dev/nvme0n1p3 : start= 29146509, size= 158692, type=426F6F74-0000-11AA-AA11-00306543ECAC, uuid=989E4FD8-2721-4B58-A6B4-24E3334F1165, attrs="GUID:49"
Result:
-
I’ve unpacked an imac with M2 and I captured the image.
The contents of the d1.partitions file:label: gpt label-id: 7D761C2A-8679-400C-9795-BFCB65054221 device: /dev/nvme0n1 unit: sectors first-lba: 6 last-lba: 61279338 /dev/nvme0n1p1 : start= 6, size= 76800, type=C12A7328-F81F-11D2-BA4B-00A0C93EC93B, uuid=E40E5108-F939-489B-BC7B-0E77CE5E42E3, name="EFI System Partition" /dev/nvme0n1p2 : start= 76806, size= 61043841, type=53746F72-6167-11AA-AA11-00306543ECAC, uuid=81584085-44EC-4186-A82C-FC857C07A63E /dev/nvme0n1p3 : start= 61120647, size= 158692, type=426F6F74-0000-11AA-AA11-00306543ECAC, uuid=0C9A6601-5C3C-4A73-8E52-A74AFAE873CC, name="Booter", attrs="GUID:49"
the contents of the folder
root@fogserver:/images/MACNOU-NET# ls -l total 18645544 -rwxrwxrwx 1 root root 17920 sep 14 09:06 d1.mbr -rwxrwxrwx 1 root root 249 sep 14 09:06 d1.original.uuids -rwxrwxrwx 1 root root 14480899 sep 14 09:06 d1p1.img -rwxrwxrwx 1 root root 18527785416 sep 14 09:58 d1p2.img -rwxrwxrwx 1 root root 550725927 sep 14 09:59 d1p3.img -rwxrwxrwx 1 root root 610 sep 14 09:06 d1.partitions
I think the problem of label: dos is that an empty disc was recovered with “TimeMachine” without an operating system.
Now I am doing a capture of an iMac with M2 with operating system and restored with TimeMachine.