From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,HTML_MESSAGE,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ot1-x33b.google.com (mail-ot1-x33b.google.com [IPv6:2607:f8b0:4864:20::33b]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id bf35836b for ; Wed, 26 Jun 2019 05:46:08 +0000 (UTC) Received: by mail-ot1-x33b.google.com with SMTP id b25sf505490otp.12 for ; Tue, 25 Jun 2019 22:46:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20161025; h=sender:date:from:to:message-id:in-reply-to:references:subject :mime-version:x-original-sender:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-subscribe:list-unsubscribe; bh=FM/eZChYkXETvcDpj22/6iZYqMPyFNjgGI9ZBV/vkWw=; b=P4u3I/9kCqXGSkHUgv11IW9dWwcSaZOYdBFgJ4kvQRzHR5cL2w9FCDz84REkv9n8km YAT06lRZBD9WGgkHU5kUu4cVB143sy8eSoboIftWDIlnQJtX/+Qq0r/aG4+ltWJ9wchD 2V/pbqVc1D4kkmt7rZDjlxCHJVyaAqKbs+9liE8sJCNuLkJ1mGt+nxF3AZGf11MmP6JZ oeSYB53a3eEqTnga/wP4qzVF0dXBmALw38wFNvidae2FlvgDWlAuQ9hWOiW7BpCRQSvA 7jKrxmH2YQ/AaO6IzXFrGlFHbTqfMHBeMtU40qxGVQKPDK1WKG7eDcKWs1tO3RRUI9sq oi/w== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:message-id:in-reply-to:references:subject:mime-version :x-original-sender:precedence:mailing-list:list-id:list-post :list-help:list-archive:list-subscribe:list-unsubscribe; bh=FM/eZChYkXETvcDpj22/6iZYqMPyFNjgGI9ZBV/vkWw=; b=XMIw1ydiNTG+uQpwNb2OPl3zhj7TNMSUj/RXQmgmmweKepk0zZ+ZKmTxRNtf6jZLb4 AHGXRVRnwMG8D3g7GPw+vycjZVFcjz6KoDvH5VPSHPvg044jvvVjJkfeRLCPnPIY++Go lP3luBjbYVJUrmXCAvnGGPXpAw9e/kB4eol5K/Mj6CNl/ikUQcRvDmGLhAGs9UL1kHat QAyB1qEKYt9a2+oGEtq7DJGMfmlIjrLgTWEEJoi+gYLQLXV/bFXHpcABQOh03j5rKFlb XoQ+1UlE4zqzv4NdQl+gw4xPynX1XAgBqqTMvpJDotB4LC2JxTOwO391bHO20g72Ex7Z t4cw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:date:from:to:message-id:in-reply-to :references:subject:mime-version:x-original-sender:precedence :mailing-list:list-id:x-spam-checked-in-group:list-post:list-help :list-archive:list-subscribe:list-unsubscribe; bh=FM/eZChYkXETvcDpj22/6iZYqMPyFNjgGI9ZBV/vkWw=; b=ntWoTfFhFESiANOZ0a0QNa53ocpLNBhsnpmScAZoS7FUL15v8Pt0L9bJTWxchF38OZ Inu34DbAMDrwGHVA7dvnnMmzBQhiz07v2MEEkE/7dw+I9WHJBt1ObV8ef3hQ02TfDo15 NcRUYLd1QHPOPSwDRpOIsnEGKAnc+zPvcHA7UcgrQdsxXmKYiynUZrbG+a/Lh9AUtbLj TQV7SKA81ykqChXsznj72SElDctR7GIui5wQpCiaWrua73N+cmOndXca0alu8kaVKR8y a28ZfW+zcStLCd4mwuU2FLO7HGEH2dZCv83zETyqKlwMRlK1MLQKKSabn3o8UXDOkc2P 3Mww== Sender: voidlinux@googlegroups.com X-Gm-Message-State: APjAAAWJPN9VNrHPft7OXEFni+9asGmSC+qRbxvN35GnLBd9G1kzEzYO vgxXz5VIpifQqrE+SZknFbc= X-Google-Smtp-Source: APXvYqzDB72Xx+WLnNVGeBJ2iujXy/n9gpCkv52xRaqI2go6CR6O/EAvz8URUPwmNSm7nPINZrQzfg== X-Received: by 2002:a9d:1d22:: with SMTP id m31mr2008466otm.92.1561527967114; Tue, 25 Jun 2019 22:46:07 -0700 (PDT) X-BeenThere: voidlinux@googlegroups.com Received: by 2002:a9d:3cb:: with SMTP id f69ls156954otf.5.gmail; Tue, 25 Jun 2019 22:46:06 -0700 (PDT) X-Received: by 2002:a05:6830:157:: with SMTP id j23mr1900147otp.198.1561527966764; Tue, 25 Jun 2019 22:46:06 -0700 (PDT) Date: Tue, 25 Jun 2019 22:46:06 -0700 (PDT) From: jacksprat To: voidlinux Message-Id: In-Reply-To: <5d119bc6-2440-4bed-8f81-841ba285c876@googlegroups.com> References: <5d119bc6-2440-4bed-8f81-841ba285c876@googlegroups.com> Subject: Re: Trying to Install on USB drive using GRUB MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_2342_1963483080.1561527966257" X-Original-Sender: picamanic@gmail.com Precedence: list Mailing-list: list voidlinux@googlegroups.com; contact voidlinux+owners@googlegroups.com List-ID: X-Google-Group-Id: 289663804196 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , ------=_Part_2342_1963483080.1561527966257 Content-Type: multipart/alternative; boundary="----=_Part_2343_1464222243.1561527966257" ------=_Part_2343_1464222243.1561527966257 Content-Type: text/plain; charset="UTF-8" This all happened because the hard drive on my shiny HP laptop was failing, and I decided to try and create a bootable USB drive with GRUB and and the Void Linux MUSL Live image. As my route to finding a solution was a bit messy, I just wanted to let you know what eventually worked. I started from Void Linux Live MUSL image, which I opted to load into RAM from USB, so that I could unmount the installation medium and remove. This avoids getting confused with the target USB device: a Samsung 250gb 860 Evo SSD [SATA] connected via a STAR USB adaptor. The void-installer script fails when running grub-install [it wanted UEFI], and my attempts to fix it failed. However, as the basic system had been installed, I just needed to make it boot. I ensured that the /dev/sdb1 partition was bootable by running fdisk /dev/sdb and use the "a" command to toggle the "bootable" flag. Next, I crafted a simple grub.cfg file: menuentry 'Void GNU/Linux MUSL 4.18.17 [sdb1]' { insmod gzio insmod part_msdos insmod ext2 set root='hd0,msdos1' linux /boot/vmlinuz-4.18.17_1 root=/dev/sdb1 ro initrd /boot/initramfs-4.18.17_1.img } I don't understand "hd0" for the sdb device [why not "hd1"?], but only it works. This is then installed with mkdir /usb mount /dev/sdb1 /usb grub-install --target=i386-pc --boot-directory=/usb/boot /dev/sdb umount /usb At this point the the system can be rebooted. This all happened because the void-installer insisted that I use the crazy efi method, even though I have been using BIOS-based installs for ever. On older [pre-efi] computers, the void-installer seems to just work. Maybe I will embrace uefi one day [joke]. On Tuesday, June 25, 2019 at 10:25:30 AM UTC+1, jacksprat wrote: > > My laptop hard drive died, so as an interim solution, I wanted to install > Void Linux on a removable hard drive [/dev/sdb1]. > > I started with the current 64-bit MUSL live image. The void-installer > script, run as root, fails to complete, complaining about expecting to find > an efi setup. Rather than get involved with efi , I tried > > mkdir /usb > mount /dev/sdb1 /usb > > grub-install --target=i384-pc --boot-directory=/usb/boot /dev/sdb > umount /usb > > which completed without errors. However, on reboot, I get the grub menu > from the failed hard drive. > > I also ran fdisk on /dev/sdb to mark the partition bootable. What have I > missed? Thanks. > > -- You received this message because you are subscribed to the Google Groups "voidlinux" group. To unsubscribe from this group and stop receiving emails from it, send an email to voidlinux+unsubscribe@googlegroups.com. To post to this group, send email to voidlinux@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/voidlinux/a63f086d-48c8-4039-9892-295194715d87%40googlegroups.com. For more options, visit https://groups.google.com/d/optout. ------=_Part_2343_1464222243.1561527966257 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
This all happened because the hard drive on my shiny HP la= ptop was failing, and I decided to try and create a bootable USB drive with= GRUB and and the Void Linux MUSL Live image.

As my route to finding= a solution was a bit messy, I just wanted to let you know what eventually = worked.

I started from Void Linux Live MUSL image, which I opted to = load into RAM from USB, so that I could unmount the installation medium and= remove.=C2=A0 This avoids getting confused with the target USB device:=C2= =A0 a Samsung 250gb 860 Evo SSD [SATA] connected via a STAR USB adaptor.=C2=A0
The void-installer script fails when running grub-install [it wa= nted UEFI], and my attempts to fix it failed.=C2=A0 However, as the basic s= ystem had been installed, I just needed to make it boot.

I ensured t= hat the /dev/sdb1 partition was bootable by running fdisk /dev/sdb and use = the "a" command to toggle the "bootable" flag.=C2=A0
Next, I crafted a simple grub.cfg file:

=C2=A0 menuentry '= Void GNU/Linux MUSL 4.18.17 [sdb1]' {
=C2=A0=C2=A0=C2=A0 insmod gzio=
=C2=A0=C2=A0=C2=A0 insmod part_msdos
=C2=A0=C2=A0=C2=A0 insmod ext2<= br>=C2=A0=C2=A0=C2=A0 set root=3D'hd0,msdos1'
=C2=A0=C2=A0=C2=A0= linux /boot/vmlinuz-4.18.17_1 root=3D/dev/sdb1 ro=C2=A0
=C2=A0=C2=A0= =C2=A0 initrd /boot/initramfs-4.18.17_1.img
=C2=A0 }

I don't = understand "hd0" for the sdb device [why not "hd1"?], b= ut only it works.=C2=A0 This is then installed with

=C2=A0 mkdir /us= b
=C2=A0 mount /dev/sdb1 /usb
=C2=A0 grub-install --target=3Di386-pc = --boot-directory=3D/usb/boot=C2=A0 /dev/sdb
=C2=A0 umount /usb

At= this point the the system can be rebooted.

This all happened becaus= e the void-installer insisted that I use the crazy efi method, even though = I have been using BIOS-based installs for ever.=C2=A0 On older [pre-efi] co= mputers, the void-installer seems to just work.=C2=A0 Maybe I will embrace = uefi one day [joke].




On Tuesday, June 25, 2019 at 10:25:= 30 AM UTC+1, jacksprat wrote:
<= div dir=3D"ltr">My laptop hard drive died, so as an interim solution, I wan= ted to install Void Linux on a removable hard drive [/dev/sdb1].=C2=A0
=
I started with the current 64-bit MUSL live image.=C2=A0 The void-insta= ller script, run as root, fails to complete, complaining about expecting to= find an efi setup.=C2=A0 Rather than get involved with efi , I tried
=C2=A0 mkdir /usb
=C2=A0 mount /dev/sdb1 /usb
=C2=A0 <create /us= b/boot/grub/grub.cfg with suitable menu item>
=C2=A0 grub-install --t= arget=3Di384-pc --boot-directory=3D/usb/boot=C2=A0 /dev/sdb
=C2=A0 umoun= t /usb

which completed without errors.=C2=A0 However, on reboot, I g= et the grub menu from the failed hard drive.

I also ran fdisk on /de= v/sdb to mark the partition bootable.=C2=A0 What have I missed?=C2=A0 Thank= s.

--
You received this message because you are subscribed to the Google Groups &= quot;voidlinux" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to voidlinux= +unsubscribe@googlegroups.com.
To post to this group, send email to voidlinux@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid= /voidlinux/a63f086d-48c8-4039-9892-295194715d87%40googlegroups.com.
For more options, visit http= s://groups.google.com/d/optout.
------=_Part_2343_1464222243.1561527966257-- ------=_Part_2342_1963483080.1561527966257--