hd-media/boot.img.gz resize

Help with issues regarding installation of Debian

hd-media/boot.img.gz resize

Postby blockbuster5 » 2019-08-19 23:51

Hi,

Is there a way I can resize or get a bigger boot.img.gz of debian? I would like to put in a bigger image than the current 1G limitation.

Thanks!
blockbuster5
 
Posts: 3
Joined: 2019-08-19 23:48

Re: hd-media/boot.img.gz resize

Postby p.H » 2019-08-20 08:34

I guess you can uncompress the image, extend it, extend the partition and filesystem inside, and compress the image again.
May I ask why you want to use this image ?
p.H
 
Posts: 1091
Joined: 2017-09-17 07:12

Re: hd-media/boot.img.gz resize

Postby blockbuster5 » 2019-08-20 16:54

Once the image is uncompressed, how can I extend it (extend the partition)? Any commands or tools?

I looked online and tried: sudo qemu-img resize boot.img 3G
But when I write it to a drive zcat boot.img.gz > /dev/sdb The filesystem is still 1G. How can I extend it?

I am going to add my own stuff to the image which will make it larger than 1G.

thanks!
blockbuster5
 
Posts: 3
Joined: 2019-08-19 23:48

Re: hd-media/boot.img.gz resize

Postby p.H » 2019-08-20 17:44

You must resize the partition with any partition tool (fdisk, parted...) and the filesystem with that filesystem-specific resize tool (resize2fs for ext*, fatresize for FAT...). Thinking of it, I seem to remember observing that fatresize mangled the filesystem boot sector, so the image may not boot properly.

You know that the installation manual describes other methods to use a bigger image, don't you ?
p.H
 
Posts: 1091
Joined: 2017-09-17 07:12

Re: hd-media/boot.img.gz resize

Postby blockbuster5 » 2019-08-20 20:06

p.H wrote:You know that the installation manual describes other methods to use a bigger image, don't you ?


Can you point me to method to use bigger custom image?

thanks!
blockbuster5
 
Posts: 3
Joined: 2019-08-19 23:48

Re: hd-media/boot.img.gz resize

Postby p.H » 2019-08-21 07:44

4.3.3. Manually copying files to the USB stick — the flexible way
https://www.debian.org/releases/stable/i386/ch04s03.en.html#usb-copy-flexible
p.H
 
Posts: 1091
Joined: 2017-09-17 07:12


Return to Installation

Who is online

Users browsing this forum: No registered users and 11 guests

fashionable
cron