How to install bootloader for a frugal install to the drive itself?

Moderators: 666philb, Forum moderators

Post Reply
User avatar
user1234
Posts: 414
Joined: Sat Feb 26, 2022 5:48 am
Location: Somewhere on earth
Has thanked: 155 times
Been thanked: 88 times

How to install bootloader for a frugal install to the drive itself?

Post by user1234 »

I have got an external hard disk on which I have frugally installed puppy in a seperate directory. The hard disk also contains a lot of files of my work (~300gb out of 1tb). I use a seperate fat32 partitioned USB for bootloader.

So when booting I connect my bootloader USB to one port and the external hard disk to the other. It all just works fine. But now what I am thinking of using that USB to save some of my work (by the way the USB is of 4gb).

So can I install the bootloader to the external hard drive containing no bootloader or os (ntfs partitioned), but without damaging any of the files on the hdd? I don't want to repartition or just resize the partition because I know that there are chances of losing data.

If that can't be done, then can I make a directory inside the USB that I'm currently using as bootloader, without having any effect on the bootloader (by effect I mean that anything goes wrong while bootloading)?

PuppyLinux 🐾 gives new life to old computers ✨

User avatar
wizard
Posts: 1845
Joined: Sun Aug 09, 2020 7:50 pm
Has thanked: 2523 times
Been thanked: 601 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by wizard »

So can I install the bootloader to the external hard drive containing no bootloader or os (ntfs partitioned), but without damaging any of the files on the hdd?

Yes, but to be safe you should backup your data first.

If that can't be done, then can I make a directory inside the USB that I'm currently using as bootloader, without having any effect on the bootloader (by effect I mean that anything goes wrong while bootloading)?

Yes

wizard

Big pile of OLD computers

User avatar
wizard
Posts: 1845
Joined: Sun Aug 09, 2020 7:50 pm
Has thanked: 2523 times
Been thanked: 601 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by wizard »

Assuming your computer is using legacy (mbr) booting.

1. Use gparted to set the boot flag on the hdd
2. install grub2config-2.0.1.pet in your USB Puppy
3. Use grub2config to install the grub boot loader to hdd

If your system is using UEFI boot, it will require partitioning the hdd which is riskier.

wizard

Big pile of OLD computers

User avatar
user1234
Posts: 414
Joined: Sat Feb 26, 2022 5:48 am
Location: Somewhere on earth
Has thanked: 155 times
Been thanked: 88 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by user1234 »

wizard wrote: Wed May 11, 2022 2:11 pm

Assuming your computer is using legacy (mbr) booting.

1. Use gparted to set the boot flag on the hdd
2. install grub2config-2.0.1.pet in your USB Puppy
3. Use grub2config to install the grub boot loader to hdd

If your system is using UEFI boot, it will require partitioning the hdd which is riskier.

wizard

Yeah, sorry I forgot to mention that. Mine does not use UEFI.

Do you mean to set the boot flag to the whole partition that puppy is also installed in, or create a different partition (which I don't want to)?

PuppyLinux 🐾 gives new life to old computers ✨

User avatar
wizard
Posts: 1845
Joined: Sun Aug 09, 2020 7:50 pm
Has thanked: 2523 times
Been thanked: 601 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by wizard »

Do you mean to set the boot flag to the whole partition that puppy is also installed in

Yes, set it for the external hdd ntfs partition.

wizard

Big pile of OLD computers

User avatar
bigpup
Moderator
Posts: 6836
Joined: Tue Jul 14, 2020 11:19 pm
Location: Earth, South Eastern U.S.
Has thanked: 874 times
Been thanked: 1472 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by bigpup »

To make sure we give you 100% correct info.

How is the external hard drive partitioned?

One single partition formatted what format?

Several partitions and their formats?

Do you know how to use Gparted program?

I assume the external drive is connected to the computer by USB?

The things you do not tell us, are usually the clue to fixing the problem.
When I was a kid, I wanted to be older.
This is not what I expected :o

User avatar
mikeslr
Posts: 2915
Joined: Mon Jul 13, 2020 11:08 pm
Has thanked: 175 times
Been thanked: 893 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by mikeslr »

One other thing. Is the external drive connected directly to the computer --i.e. USB-Hard drive-- or is it a hard-drive connected using an adapter --for example these, hard-drive to usb-adapter or a docking station such as these, https://www.amazon.com/hard-drive-docki ... ng+station?

I know it won't work if a docking station is involved: too many connections each requiring information to be processed, altered, transmitted. I doubt that even the an adapter would result in a functioning system as that would involve the change in transmission of information from a USB-device to a Sata device.

I think an external USB-Hard-Drive will be recognized as a USB-Device with the boot argument defining it as such.

Since you don't have a UEFI computer, as wizard noted it won't be necessary to partition the drive in order to create a Fat32 boot partition. Linux can --but doesn't have to-- have its boot-loader on a Fat32 partition. A Linux formatted partition will suffice.

User avatar
wizard
Posts: 1845
Joined: Sun Aug 09, 2020 7:50 pm
Has thanked: 2523 times
Been thanked: 601 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by wizard »

@mikeslr

OP has stated the hdd is NTFS and grub2config will install grub boot loader to NTFS as well as to Linux ext or fat32, a great tool.

I think an external USB-Hard-Drive will be recognized as a USB-Device with the boot argument defining it as such.

Yes, I have one working, NTFS, and it boots.

wizard

Big pile of OLD computers

User avatar
user1234
Posts: 414
Joined: Sat Feb 26, 2022 5:48 am
Location: Somewhere on earth
Has thanked: 155 times
Been thanked: 88 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by user1234 »

bigpup wrote: Wed May 11, 2022 7:23 pm

How is the external hard drive partitioned?

One single partition formatted what format?

Several partitions and their formats?

Do you know how to use Gparted program?

I assume the external drive is connected to the computer by USB?

I have answered your questions in order-

NTFS partitioned.

Only a single partition MBR.

No, not several partitions.

Yes.

Am not sure about that. Actually it is connected by a usb lead sort of thing I think. Maybe would click a picture and send you later this day.

And I forgot to mention, my laptop uses bios not legacy, though I can set it to work as legacy.

PuppyLinux 🐾 gives new life to old computers ✨

User avatar
bigpup
Moderator
Posts: 6836
Joined: Tue Jul 14, 2020 11:19 pm
Location: Earth, South Eastern U.S.
Has thanked: 874 times
Been thanked: 1472 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by bigpup »

Actually it is connected by a usb lead sort of thing I think. Maybe would click a picture and send you later this day.

What type port do you plug it into?
By description, seems to be a standard external HDD that plugs into a USB port.

This may just be your words, but this is a little confusing.

my laptop uses bios not legacy, though I can set it to work as legacy.

Bios is the original boot process firmware, all computers used, until they developed UEFI firmware.
Most UEFI firmware has a setting where you can select it to run in legacy mode.
This makes it work like the old style bios.

If it is bios firmware.
Really, any boot loader you install on the external HDD should work.
Just make sure the boot loader installer is selected to install the boot loader on the external HDD and make a boot menu for only the external HDD.

When you get a boot loader on the external drive.
The computer should now identify it as a boot able drive.
Should be now listed as a selectable boot device in the bios boot setup or boot device selection menu.

The things you do not tell us, are usually the clue to fixing the problem.
When I was a kid, I wanted to be older.
This is not what I expected :o

User avatar
user1234
Posts: 414
Joined: Sat Feb 26, 2022 5:48 am
Location: Somewhere on earth
Has thanked: 155 times
Been thanked: 88 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by user1234 »

Here is the image of the lead I connect my laptop to (got the picture from amazon)-
hdd.

Here one end connects to laptop (I think it is called USB 2.0), while the other end connects to hdd.

Attachments
images.jpeg
images.jpeg (13.98 KiB) Viewed 907 times

PuppyLinux 🐾 gives new life to old computers ✨

Clarity
Posts: 3673
Joined: Fri Jul 24, 2020 10:59 pm
Has thanked: 1548 times
Been thanked: 493 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by Clarity »

That is merely a standard cable for some of the HDDs in the past: One end (blue tip) is standard USB-A while the other is a standard USB end that is used for connecting some external drive controllers.

Nothing unusual about the cabling. And since your system can see it and can read/write to it, the physical connection is OK.

User avatar
user1234
Posts: 414
Joined: Sat Feb 26, 2022 5:48 am
Location: Somewhere on earth
Has thanked: 155 times
Been thanked: 88 times

Re: How to install bootloader for a frugal install to the drive itself?

Post by user1234 »

wizard wrote: Wed May 11, 2022 2:11 pm

Assuming your computer is using legacy (mbr) booting.

1. Use gparted to set the boot flag on the hdd
2. install grub2config-2.0.1.pet in your USB Puppy
3. Use grub2config to install the grub boot loader to hdd

If your system is using UEFI boot, it will require partitioning the hdd which is riskier.

wizard

That worked :D. Thanks :)!

Couldn't try earlier due to some work.

PuppyLinux 🐾 gives new life to old computers ✨

Post Reply

Return to “Fossapup64”