Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

debian-12.2.0-amd64-netinst.iso usb grub boot error "invalid buffer alignment"

380 views
Skip to first unread message

Zenaan Harkness

unread,
Nov 20, 2023, 3:40:06 AM11/20/23
to
Attempting a fresh Debian stable install with
debian-12.2.0-amd64-netinst.iso (latest default amd64 boot image), `cp
deiban-...iso /dev/sdX; sync`, and rebooted to the usb stick with the
grub graphical screen, but all of the grub menu options (Graphical
install, Graphical expert install, Expert install, etc) give 2 errors:

1) "..invalid buffer alignment... " with some long number beginning with minus.
2) kernel fail to load error, presumably due to error 1

Any ideas of how I can boot this usb stick and install debian?

I'm on a laptop...

Zenaan Harkness

unread,
Nov 20, 2023, 4:00:07 AM11/20/23
to
In case it's useful, my laptop is currently running Ubuntu - I'm
wondering if it's possible to do some sort of chroot from Ubuntu into
the USB stick, so that I can format the laptop's SSD and begin the
install process that way? Surely that has been thought of before?

(That said, I ought ensure I can boot the USB stick, so that I can do
a rescue install if needed for any fat finger reason...)

I notice the package debian-installer-launcher - should I be able to
use that, with the debian netinst image, and by using that, can I get
a "clean" install i.e format the laptop's SSD?

Tom Furie

unread,
Nov 20, 2023, 4:20:07 AM11/20/23
to
Zenaan Harkness <zen...@gmail.com> writes:

> Attempting a fresh Debian stable install with
> debian-12.2.0-amd64-netinst.iso (latest default amd64 boot image), `cp
> deiban-...iso /dev/sdX; sync`, and rebooted to the usb stick with the

You can't just copy the iso to the stick and get it to boot. This stick
must have already had an image written to it, the leftovers of which is
getting as far as GRUB.

I noticed you posted a follow-up saying you're on Ubuntu - in which case
you should be able to use dd to write the image to the stick.

Cheers,
Tom

to...@tuxteam.de

unread,
Nov 20, 2023, 4:30:07 AM11/20/23
to
On Mon, Nov 20, 2023 at 08:59:02AM +0000, Tom Furie wrote:
> Zenaan Harkness <zen...@gmail.com> writes:
>
> > Attempting a fresh Debian stable install with
> > debian-12.2.0-amd64-netinst.iso (latest default amd64 boot image), `cp
> > deiban-...iso /dev/sdX; sync`, and rebooted to the usb stick with the
>
> You can't just copy the iso to the stick and get it to boot.

Actually... if you copy to the whole device (not to a partition), as
OP seems to have done, it should work. The only advantage of dd over
cp is that you have more control over the buffer cache (oflag=sync).

> This stick
> must have already had an image written to it, the leftovers of which is
> getting as far as GRUB.

...no: all blocks of the block device get overwritten, including the
boot loader.

> I noticed you posted a follow-up saying you're on Ubuntu - in which case
> you should be able to use dd to write the image to the stick.

Cp should be the same than dd; with dd you can control block size (with
sticks, my experience is that bs=1M is much faster than the default of
512), turn off buffer cache (oflag=sync), so no more waiting for a sync
to come back without knowing how long it's going to take) and a progress
indicator (status=progress), which is nice.

The result should be the same (if you wait for sync to finish its job,
that is).

Cheers
--
t
signature.asc

Zenaan Harkness

unread,
Nov 20, 2023, 5:20:06 AM11/20/23
to
On Monday, November 20, 2023, <to...@tuxteam.de> wrote:
> On Mon, Nov 20, 2023 at 08:59:02AM +0000, Tom Furie wrote:
>> Zenaan Harkness <zen...@gmail.com> writes:
>>
>> > Attempting a fresh Debian stable install with
>> > debian-12.2.0-amd64-netinst.iso (latest default amd64 boot image), `cp
>> > deiban-...iso /dev/sdX; sync`, and rebooted to the usb stick with the
>>
>> You can't just copy the iso to the stick and get it to boot.
>
> Actually... if you copy to the whole device (not to a partition), as
...

Thank you both. I tried dd first, then cp, then ubuntu-disk-creator (?) -- then I tried a different usb stick.

Used that old stick many times and never had a problem before now...

Thanks heaps, I'm on track again now.

(Last night ubuntu snapd would not start, so ffox, chrome, blender, nothing worked. apt update, snap refresh, reboot. Had to wait till the bug got fixed in the repos today! That was the straw that broke this camel's back... returning to debian)

to...@tuxteam.de

unread,
Nov 20, 2023, 5:20:07 AM11/20/23
to
On Mon, Nov 20, 2023 at 09:13:01PM +1100, Zenaan Harkness wrote:
> On Monday, November 20, 2023, <to...@tuxteam.de> wrote:
> > On Mon, Nov 20, 2023 at 08:59:02AM +0000, Tom Furie wrote:
> >> Zenaan Harkness <zen...@gmail.com> writes:
> >>
> >> > Attempting a fresh Debian stable install with
> >> > debian-12.2.0-amd64-netinst.iso (latest default amd64 boot image), `cp
> >> > deiban-...iso /dev/sdX; sync`, and rebooted to the usb stick with the
> >>
> >> You can't just copy the iso to the stick and get it to boot.
> >
> > Actually... if you copy to the whole device (not to a partition), as
> ...
>
> Thank you both. I tried dd first, then cp, then ubuntu-disk-creator (?) --
> then I tried a different usb stick.

For reference, what I do is

sudo dd if=image.file of=/dev/sdX bs=1M oflag=sync status=progress

Cheers
--
t
signature.asc

to...@tuxteam.de

unread,
Nov 20, 2023, 5:30:06 AM11/20/23
to
On Mon, Nov 20, 2023 at 11:17:15AM +0100, to...@tuxteam.de wrote:

[...]

> For reference, what I do is
>
> sudo dd if=image.file of=/dev/sdX bs=1M oflag=sync status=progress

(and oh, it hasn't been mentioned: make super-sure some smart and
overly helpful automounter has got hold of the USB).

Cheers
--
t
signature.asc

Thomas Schmitt

unread,
Nov 20, 2023, 5:30:06 AM11/20/23
to
Hi,

Zenaan Harkness wrote:
> > > all of the grub menu options (Graphical
> > > install, Graphical expert install, Expert install, etc) give 2 errors:
> > > 1) "..invalid buffer alignment... " with some long number beginning with
> > > minus.
> > > 2) kernel fail to load error, presumably due to error 1

Before discussing the tanget about copying bootable ISOs to USB stick:

I suspect that something is wrong with the software in the ISO or with
the hardware or with the involved firmware.
The mailing list for such problems would be debi...@lists.debian.org
but some maintainers of debian-cd are subscribed to debian-user, too.


Tom Furie wrote:
> > You can't just copy the iso to the stick and get it to boot.

to...@tuxteam.de wrote:
> Actually... if you copy to the whole device (not to a partition), as
> OP seems to have done, it should work.

Indeed.
The only pitfall would be a GPT backup block at the end of the device's
writable capacity. Some software could take it as indication that a
clueless user damaged the GPT. Perky software might try to re-create
the old GPT and thus hide the EFI partiton of the ISO.

But since Zenaan Harkness reports GRUB to have started and offering the
expected installation menu, it's improbable that such a mishap occured.


> all blocks of the block device get overwritten,

Not all. Only as far as the new image reaches. That's how the GPT backup
can survive (xorriso-dd-target would explicitely overwrite the last block
by zeros).
EFI firmwares are not known to react on GPT backups, although this cannot
be ruled out completely.


Have a nice day :)

Thomas

to...@tuxteam.de

unread,
Nov 20, 2023, 5:40:07 AM11/20/23
to
On Mon, Nov 20, 2023 at 11:27:45AM +0100, Thomas Schmitt wrote:

[...]
> to...@tuxteam.de wrote:

[...]

> > all blocks of the block device get overwritten,
>
> Not all. Only as far as the new image reaches. That's how the GPT backup
> can survive (xorriso-dd-target would explicitely overwrite the last block
> by zeros).
> EFI firmwares are not known to react on GPT backups, although this cannot
> be ruled out completely.

Indeed, thanks for the correction :-)

Cheers
--
t "all generalizations suck"
signature.asc

Tixy

unread,
Nov 20, 2023, 6:20:06 AM11/20/23
to
On Mon, 2023-11-20 at 11:21 +0100, to...@tuxteam.de wrote:
> (and oh, it hasn't been mentioned: make super-sure some smart and
> overly helpful automounter has got hold of the USB).

That's a good point. I tend to use an Ubuntu live image to do things
like cloning my main disk, and I've wasted quite a few hours after not
noticing it's auto-mounting the disk I'm copying too and so trashing my
clone. (I find out the copy is bad when doing a binary compare after
the multi-hour copying is done.)

--
Tixy
0 new messages