Re: [opensuse-arm] How to resize 13.2 Raspberry Pi image
![](https://seccdn.libravatar.org/avatar/0ab1491ab50291fb6654bd364f499a4f.jpg?s=120&d=mm&r=g)
Op dinsdag 25 november 2014 14:09:06 schreef u:
On 25/11/14 09:32, Freek de Kruijf wrote:
Op dinsdag 25 november 2014 04:00:44 schreef Sid Boyce:
I use large sizes of SD cards.
After burning the image, e.g to /dev/sdb, remove the SD card and insert it again.
"gparted /dev/sdb"
Add the space of the rootfs partition to the unused space and change rootfs to the total calculated, click resize and Apply. Regards Sid.
I did that on a 16 GB card and removed /var/lib/YaST2/reconfig_system in order to be able to use it headless, but that did not work. However putting the freshly burned image in the RPi removing the card a little later from the RPi, removing /var/lib/YaST2/reconfig_system and reinserting the card in the RPi gave me a working system, accessible via ssh and with a large rootfs. There is also a swap partition at the end of about 500 MiB. Will try to remove that reconfig file right after burning to see if I get a working headless system with expanded rootfs.
That's strange as I have always done it that way on Beaglebone, Pandaboard, ODROID-X, ODROID-U3 and Parallella-16.
I always do "fsck -a /dev/sdb[12]" after resizing and on the odd occasion it reports that it cleared a dirty bit on the VFAT partition. Successfully boots every time. Regards Sid.
When applying the 13.2 image on the SD card, now there are three partitions on the card. A FAT partition, an ext3 partition and the rootfs is ext4. After initial use on the RPi there is a fourth partition at the end, a swap partition. So are we talking about the same type of image, a 13.2 image? I tried the procedure to remove the reconfig file right after burning and before actually using the card in the RPi, but that did not work. Did not do a "fsck -a /dev/sdg{123}" after burning. Should I? BTW. I noticed a change in naming of the image, first I used: openSUSE-13.2-ARM-JeOS-raspberrypi.armv7l-1.12.1-Build29.4.raw.xz now I use: openSUSE-13.2-ARM-JeOS-raspberrypi.armv6l-1.12.1-Build30.1.raw.xz If I am right the architecture of the RPi is armv6l and not armv7l, isn't it? So now we have a properly named image? -- fr.gr. member openSUSE Freek de Kruijf -- To unsubscribe, e-mail: opensuse-arm+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-arm+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/3faa48f7f462ca17481ecd1e2f45d53f.jpg?s=120&d=mm&r=g)
On 26.11.14 10:00, Freek de Kruijf wrote:
Op dinsdag 25 november 2014 14:09:06 schreef u:
On 25/11/14 09:32, Freek de Kruijf wrote:
Op dinsdag 25 november 2014 04:00:44 schreef Sid Boyce:
I use large sizes of SD cards.
After burning the image, e.g to /dev/sdb, remove the SD card and insert it again.
"gparted /dev/sdb"
Add the space of the rootfs partition to the unused space and change rootfs to the total calculated, click resize and Apply. Regards Sid.
I did that on a 16 GB card and removed /var/lib/YaST2/reconfig_system in order to be able to use it headless, but that did not work. However putting the freshly burned image in the RPi removing the card a little later from the RPi, removing /var/lib/YaST2/reconfig_system and reinserting the card in the RPi gave me a working system, accessible via ssh and with a large rootfs. There is also a swap partition at the end of about 500 MiB. Will try to remove that reconfig file right after burning to see if I get a working headless system with expanded rootfs.
That's strange as I have always done it that way on Beaglebone, Pandaboard, ODROID-X, ODROID-U3 and Parallella-16.
I always do "fsck -a /dev/sdb[12]" after resizing and on the odd occasion it reports that it cleared a dirty bit on the VFAT partition. Successfully boots every time. Regards Sid.
When applying the 13.2 image on the SD card, now there are three partitions on the card. A FAT partition, an ext3 partition and the rootfs is ext4. After initial use on the RPi there is a fourth partition at the end, a swap partition. So are we talking about the same type of image, a 13.2 image?
I tried the procedure to remove the reconfig file right after burning and before actually using the card in the RPi, but that did not work. Did not do a "fsck -a /dev/sdg{123}" after burning. Should I?
BTW. I noticed a change in naming of the image, first I used: openSUSE-13.2-ARM-JeOS-raspberrypi.armv7l-1.12.1-Build29.4.raw.xz now I use: openSUSE-13.2-ARM-JeOS-raspberrypi.armv6l-1.12.1-Build30.1.raw.xz
If I am right the architecture of the RPi is armv6l and not armv7l, isn't it? So now we have a properly named image?
I fixed the build to virtually run on an armv6 CPU rather than an armv7 CPU to fix up the file name. The contents should still be identical. The trick with the RPi image really is to synchronize GPT and MBR into a working hybrid GPT setup, just like on Apple Macs. You can also use the "gptsync" tool if you like. Alex -- To unsubscribe, e-mail: opensuse-arm+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-arm+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/0ab1491ab50291fb6654bd364f499a4f.jpg?s=120&d=mm&r=g)
Op woensdag 26 november 2014 10:06:41 schreef Alexander Graf:
The trick with the RPi image really is to synchronize GPT and MBR into a working hybrid GPT setup, just like on Apple Macs. You can also use the "gptsync" tool if you like.
I have no idea what you are talking about above. Should I do anything different? -- fr.gr. member openSUSE Freek de Kruijf -- To unsubscribe, e-mail: opensuse-arm+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-arm+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/3faa48f7f462ca17481ecd1e2f45d53f.jpg?s=120&d=mm&r=g)
On 26.11.14 11:49, Freek de Kruijf wrote:
Op woensdag 26 november 2014 10:06:41 schreef Alexander Graf:
The trick with the RPi image really is to synchronize GPT and MBR into a working hybrid GPT setup, just like on Apple Macs. You can also use the "gptsync" tool if you like.
I have no idea what you are talking about above. Should I do anything different?
You need to make sure that the hybrid GPT stays hybrid. An easy tool to do this with is gptsync: http://sourceforge.net/p/refind/code/ci/master/tree/gptsync/ IIRC gdisk also has a command to create the hybrid MBR entries from GPT. For information on what a hybrid GPT is, check out this web page: http://www.rodsbooks.com/gdisk/hybrid.html The reason we're using a hybrid GPT is that this was the easiest way to tell kiwi that we need another FAT partition that is not /boot. Alex -- To unsubscribe, e-mail: opensuse-arm+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-arm+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/0ab1491ab50291fb6654bd364f499a4f.jpg?s=120&d=mm&r=g)
Op woensdag 26 november 2014 11:58:11 schreef Alexander Graf:
On 26.11.14 11:49, Freek de Kruijf wrote:
Op woensdag 26 november 2014 10:06:41 schreef Alexander Graf:
The trick with the RPi image really is to synchronize GPT and MBR into a working hybrid GPT setup, just like on Apple Macs. You can also use the "gptsync" tool if you like.
I have no idea what you are talking about above. Should I do anything different?
You need to make sure that the hybrid GPT stays hybrid. An easy tool to do this with is gptsync:
http://sourceforge.net/p/refind/code/ci/master/tree/gptsync/
IIRC gdisk also has a command to create the hybrid MBR entries from GPT. For information on what a hybrid GPT is, check out this web page:
http://www.rodsbooks.com/gdisk/hybrid.html
The reason we're using a hybrid GPT is that this was the easiest way to tell kiwi that we need another FAT partition that is not /boot.
Alex
Excuse my ignorance. I am always thinking in cookbook procedures and only when strictly needed I get into the technology. So what you are suggesting is: 1. burn the image on the SD 2. remove the reconfig file 3. run gptsync on the SD 4. use the SD on the RPi and it should work as a headless system? -- fr.gr. member openSUSE Freek de Kruijf -- To unsubscribe, e-mail: opensuse-arm+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-arm+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/3faa48f7f462ca17481ecd1e2f45d53f.jpg?s=120&d=mm&r=g)
On 26.11.14 12:17, Freek de Kruijf wrote:
Op woensdag 26 november 2014 11:58:11 schreef Alexander Graf:
On 26.11.14 11:49, Freek de Kruijf wrote:
Op woensdag 26 november 2014 10:06:41 schreef Alexander Graf:
The trick with the RPi image really is to synchronize GPT and MBR into a working hybrid GPT setup, just like on Apple Macs. You can also use the "gptsync" tool if you like.
I have no idea what you are talking about above. Should I do anything different?
You need to make sure that the hybrid GPT stays hybrid. An easy tool to do this with is gptsync:
http://sourceforge.net/p/refind/code/ci/master/tree/gptsync/
IIRC gdisk also has a command to create the hybrid MBR entries from GPT. For information on what a hybrid GPT is, check out this web page:
http://www.rodsbooks.com/gdisk/hybrid.html
The reason we're using a hybrid GPT is that this was the easiest way to tell kiwi that we need another FAT partition that is not /boot.
Alex
Excuse my ignorance. I am always thinking in cookbook procedures and only when strictly needed I get into the technology.
So what you are suggesting is: 1. burn the image on the SD 2. remove the reconfig file 3. run gptsync on the SD 4. use the SD on the RPi and it should work as a headless system?
If you only want it headless, you need to do 1. burn the image on the SD 2. remove the reconfig file 3. use the SD on the RPi (boot at least once!) If you also want to change the partition layout, you need to 4. change the partition layout 5. run gptsync on the SD Alex -- To unsubscribe, e-mail: opensuse-arm+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-arm+owner@opensuse.org
![](https://seccdn.libravatar.org/avatar/0ab1491ab50291fb6654bd364f499a4f.jpg?s=120&d=mm&r=g)
Op woensdag 26 november 2014 12:22:28 schreef Alexander Graf:
Excuse my ignorance. I am always thinking in cookbook procedures and only when strictly needed I get into the technology.
So what you are suggesting is: 1. burn the image on the SD 2. remove the reconfig file 3. run gptsync on the SD 4. use the SD on the RPi and it should work as a headless system?
If you only want it headless, you need to do
1. burn the image on the SD 2. remove the reconfig file 3. use the SD on the RPi (boot at least once!)
If you also want to change the partition layout, you need to
4. change the partition layout 5. run gptsync on the SD
Your above procedure does not work for a headless system. The first boot of the burned SD, whether one removed the reconfig file or not, will repartition the SD. So no need to do that afterward, unless one really wants to have a different partition layout. I don't. So no need for gptsync in my case. When one did not remove the reconfig file the resulting RPi system does not work headless, but at least one has a repartitioned SD. So after that, one can remove the reconfig file and boot the SD again, after which headless works. This works for me. When one removed the reconfig file before the first boot of the SD card the system does not work headless. I have no clue how to fix that. Maybe removing the reconfig file and repartitioning of the SD card to your liking using gparted and after that using gptsync, booting that SD for the first time may give you a headless working system. I tried that without gptsync and that did not work. -- fr.gr. member openSUSE Freek de Kruijf -- To unsubscribe, e-mail: opensuse-arm+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-arm+owner@opensuse.org
participants (2)
-
Alexander Graf
-
Freek de Kruijf