public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
From: Matti Nykyri <matti.nykyri@iki.fi>
To: "gentoo-user@lists.gentoo.org" <gentoo-user@lists.gentoo.org>
Subject: Re: [gentoo-user] making bootable USB
Date: Tue, 2 Sep 2014 15:29:48 +0300	[thread overview]
Message-ID: <2A6E3C95-467D-4053-A2B9-AFD9DAB0D727@iki.fi> (raw)
In-Reply-To: <20140902055515.GL15640@syscon7>

> On Sep 2, 2014, at 8:55, Joseph <syscon780@gmail.com> wrote:
> 
>> On 09/02/14 06:36, Mick wrote:
>>> On Tuesday 02 Sep 2014 01:26:05 Joseph wrote:
>>> On 09/02/14 01:08, Neil Bothwick wrote:
>>> >On Mon, 1 Sep 2014 17:42:47 -0600, Joseph wrote:
>>> >> I just tried "usb_instal.sh" script from systemrescuecd-x86-4.3.0.iso
>>> >> and my box boots just fine. So why do I have problem using "unetbootin"
>>> >> and generating bootable USB manually.
>>> >
>>> >unetbootin uses some $MAGIC that doesn't work with all ISOs. isohybrid
>>> >seems to work with everything and is much simpler to use too.
>>> 
>>> I just tried it as root:
>>> isohybrid  install-amd64-minimal-20140828.iso
>>> dd if=/home/joseph/Downloads/install-amd64-minimal-20140828.iso of=/dev/sda
>>> bs=4096 sync
>>> 
>>> And the USB still can not boot it :-/
>> 
>> This is rather strange.
>> 
>> What do you see when you run
>> 
>> fdisk -l /dev/sda
>> 
>> *after* you have completed dd and sync as you show above?
>> 
>> -- 
>> Regards,
>> Mick
> 
> Yes, indeed I find it very strange as well.
> I just re-run the dd on my faster box.
> 
> dd if=/home/joseph/Downloads/install-amd64-minimal-20140828.iso of=/dev/sdb bs=4096
> 48640+0 records in
> 48640+0 records out
> 199229440 bytes (199 MB) copied, 318.573 s, 625 kB/s
> sync
> 
> fdisk -l /dev/sdb
> 
> Disk /dev/sdb: 960 MiB, 1006632960 bytes, 1966080 sectors
> Units: sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 512 bytes
> I/O size (minimum/optimal): 512 bytes / 512 bytes
> Disklabel type: dos
> Disk identifier: 0x1047d058
> 
> Device    Boot Start       End Blocks  Id System
> /dev/sdb1 *        0    389119 194560  17 Hidden HPFS/NTFS
> 
> -- 
> Joseph

Hi,

Just wanna say few words to clarify few things about bootstraping. If you know what you are doing, this all is very simple.

What you need for a working system is a working root filesystem that contains all the scripts, modules and executables. A minimal cd contains this. You could also use stage3 tar ball.

Then you need a working kernel image and possibly a initrd. There is a working kernel on minimal cd.

All begins with boot loader. That loader is loaded by BIOS first. Then boot loader starts executing and loads kernel with right parameters. Kernel takes over and loads rootfs and so on.

On normal disk (USB, sata, ATA, SCSI (and DVD i think)) you have a normal MBR (first 512 bytes of disk) which BIOS loads to 0x07C0 address in memory and starts executing. So just install boot loader (like grub) to the beginning of the disk and it will boot. With right commands/config you can load the kernel correctly and boot.

CD is different. BIOS can't read ISO file system. For CD boot you will need to create image of a floppy-disk and install your boot loader into that image. The boot loader has to have drivers to read the real ISO file system so that it can load the kernel into memory and boot. Because of this a plain cd isoimage is unbootable although all necessary stuff is there. It is easily arranged so that it becomes a bootable USB disk.

-- 
-Matti
  

  parent reply	other threads:[~2014-09-02 12:30 UTC|newest]

Thread overview: 71+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-30  5:37 [gentoo-user] making bootable USB Joseph
2014-08-30  6:15 ` J. Roeleveld
2014-08-30  6:32   ` Joseph
2014-08-30  7:08     ` J. Roeleveld
2014-08-31 18:06 ` Joseph
2014-09-01  0:55   ` Will Tomlinson
2014-09-01  1:28     ` wraeth
2014-09-01  2:06     ` Joseph
2014-09-01  2:16       ` wraeth
2014-09-01  6:48         ` Joseph
2014-09-01  7:18           ` Alan McKinnon
2014-09-01 15:44             ` Joseph
2014-09-01  8:02           ` Peter Humphrey
2014-09-01 15:45             ` Joseph
2014-09-01  9:46           ` wraeth
2014-09-01  9:32       ` J. Roeleveld
2014-09-01 16:00         ` Joseph
2014-09-02 11:20           ` J. Roeleveld
2014-09-01  8:51     ` Neil Bothwick
2014-09-01  9:13       ` Mick
2014-09-01 10:12         ` Neil Bothwick
2014-09-01  9:42       ` wraeth
2014-09-01  9:58         ` Neil Bothwick
2014-09-01 16:29         ` Joseph
2014-09-01 16:38           ` Christopher Jones
2014-09-01 16:41             ` Christopher Jones
2014-09-01 19:12               ` Joseph
2014-09-01 20:05                 ` Neil Bothwick
2014-09-01 18:53             ` Christian Kruse
2014-09-01 19:50               ` Will Tomlinson
2014-09-01 23:42                 ` Joseph
2014-09-02  0:08                   ` Neil Bothwick
2014-09-02  0:26                     ` Joseph
2014-09-02  5:36                       ` Mick
2014-09-02  5:55                         ` Joseph
2014-09-02  6:23                           ` Dale
2014-09-02  7:21                             ` Christian Kruse
2014-09-02  7:35                             ` Neil Bothwick
2014-09-02  8:00                               ` Dale
2014-09-02  9:56                                 ` Mick
2014-09-02 10:16                                   ` Dale
2014-09-02 13:10                                   ` Joseph
2014-09-02 13:26                                     ` Neil Bothwick
2014-09-02  9:38                                       ` Alec Ten Harmsel
2014-09-02 13:38                                     ` thegeezer
2014-09-02 14:10                                       ` Joseph
2014-09-02 14:40                                         ` Peter Humphrey
2014-09-02 14:42                                         ` Neil Bothwick
2014-09-02 16:16                                         ` thegeezer
2014-09-02 22:32                                         ` Frank Steinmetzger
2014-09-02 14:46                                     ` Alan McKinnon
2014-09-02 16:50                                       ` Joseph
2014-09-02 17:21                                         ` Neil Bothwick
2014-09-02 18:12                                           ` Joseph
2014-09-02 21:09                                             ` Neil Bothwick
2014-09-02 18:17                                         ` J. Roeleveld
2014-09-02 21:55                                         ` Walter Dnes
2014-09-02 12:29                           ` Matti Nykyri [this message]
2014-09-01 20:13               ` Neil Bothwick
2014-09-01 21:58                 ` Alan McKinnon
2014-09-01 22:03                   ` Neil Bothwick
2014-09-01 22:14                     ` Mick
2014-09-02 22:27                       ` Frank Steinmetzger
2014-09-02 22:43                         ` Neil Bothwick
2014-09-02 22:49                         ` Dale
2014-09-01 23:51                     ` Joseph
2014-09-02  0:09                       ` Neil Bothwick
2014-09-02  0:29                         ` Joseph
2014-09-02  0:36                           ` wraeth
2014-09-02  9:48                 ` Christian Kruse
2014-09-01 20:05           ` Neil Bothwick

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2A6E3C95-467D-4053-A2B9-AFD9DAB0D727@iki.fi \
    --to=matti.nykyri@iki.fi \
    --cc=gentoo-user@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox