* [gentoo-user] Grub fails. I missed something. @ 2025-03-15 7:29 Dale 2025-03-15 9:18 ` Michael 2025-03-17 3:50 ` [gentoo-user] " Dale 0 siblings, 2 replies; 23+ messages in thread From: Dale @ 2025-03-15 7:29 UTC (permalink / raw To: gentoo-user Howdy, I have a Samsung SSD 500GB drive that I ended up not using in my new build, went with the m.2 stick thingy. I decided that I would put it in the NAS box and replace the spinning rust drive. I booted a sysrescue image. I created and mounted both drives, creating directories as needed. I then one at a time used cp -av to copy /bin, /boot and so on skipping /dev, /proc and such that is created on the fly so to speak. I did create /sys and /proc tho. I even copied the home directory, not that there is much in there that I need. Once I got it all copied, I chrooted into the new drive. I installed grub on it using grub-install /dev/sdb, since it is the second drive at this point. I went back and looked at the install docs to be sure I didn't need to run anything else. Since I already had a config file and all, it should just work. When I try to boot with the SSD drive, I get this on the screen, pardon my having to type it in. This comes up right after the BIOS screen. loading operating system . . . GRUB That's it. It can't be the BIOS because if I connect the old drive as first drive, it boots just fine. I've missed a command somewhere. I'm sure it isn't the OS itself since it is a clone basically. I am almost certain I missed a grub command somewhere but can't figure out what it is. Searching for the error got other hits but not what I'm seeing. Has someone seen this before and recall how to fix it? Remember what command it is that I missed? I'm not sure this SSD drive is going to make that old NAS mobo go any faster. LOL It is kinda old. Thanks. Dale :-) :-) Oh, after my friend and I finished cutting a huge tree into firewood, he went and cut two more slightly smaller trees. I'm about beat. I hope when we get done with these two, he puts the chainsaw on the shelf to give it, and ME, a break. :/ ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-15 7:29 [gentoo-user] Grub fails. I missed something Dale @ 2025-03-15 9:18 ` Michael 2025-03-15 20:42 ` Dale 2025-03-17 3:50 ` [gentoo-user] " Dale 1 sibling, 1 reply; 23+ messages in thread From: Michael @ 2025-03-15 9:18 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 2964 bytes --] On Saturday, 15 March 2025 07:29:32 Greenwich Mean Time Dale wrote: > Howdy, > > I have a Samsung SSD 500GB drive that I ended up not using in my new > build, went with the m.2 stick thingy. I decided that I would put it in > the NAS box and replace the spinning rust drive. I booted a sysrescue > image. I created and mounted both drives, creating directories as > needed. I then one at a time used cp -av to copy /bin, /boot and so on > skipping /dev, /proc and such that is created on the fly so to speak. I > did create /sys and /proc tho. I even copied the home directory, not > that there is much in there that I need. Once I got it all copied, I > chrooted into the new drive. The Handbook states you should -rbind the /dev of the host before you chroot. Did you do this? > I installed grub on it using grub-install > /dev/sdb, since it is the second drive at this point. Did you check if 'ls -l /dev/disk/by-id' within the chroot was mapping the correct disk to /dev/sdb? I'll assume your NAS is a legacy BIOS not an EFI MoBo and grub-install /dev/ sdb did not throw up any errors. > I went back and > looked at the install docs to be sure I didn't need to run anything > else. Since I already had a config file and all, it should just work. > > When I try to boot with the SSD drive, I get this on the screen, pardon > my having to type it in. This comes up right after the BIOS screen. > > > loading operating system . . . > GRUB > > > That's it. It can't be the BIOS because if I connect the old drive as > first drive, it boots just fine. I've missed a command somewhere. I'm > sure it isn't the OS itself since it is a clone basically. I am almost > certain I missed a grub command somewhere but can't figure out what it > is. Searching for the error got other hits but not what I'm seeing. You did not mention if you ran 'grub-mkconfig -o /boot/grub/grub.cfg' within the chroot. This would read UUID and PARTUID of the new disk and its / partition and add these to your grub.cfg file. Unless you used dd to clone the partitions from the old to the new, the new disk partitions and fs IDs will be different to the old disk. > Has someone seen this before and recall how to fix it? Remember what > command it is that I missed? I think if you follow the Handbook to chroot into your new drive and update your grub.cfg it /should/ work. While you're at it don't forget to edit your fstab, if you are specifying filesystems in it using UUIDs. > I'm not sure this SSD drive is going to make that old NAS mobo go any > faster. LOL It is kinda old. I have found SSDs even when installed on old SATA 2.0 MoBos give a performance boost - but it depends how slow the spinning disk was. Replacing a 10,000RPM disk with an SSD would not provide any celebratory performance difference. PS. Check the MoBo BIOS is set to use AHCI for the SATA port you're connecting this SSD on, or TRIM/discard won't work. [-- Attachment #2: This is a digitally signed message part. --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-15 9:18 ` Michael @ 2025-03-15 20:42 ` Dale 2025-03-15 21:43 ` eric 0 siblings, 1 reply; 23+ messages in thread From: Dale @ 2025-03-15 20:42 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 6361 bytes --] Michael wrote: > On Saturday, 15 March 2025 07:29:32 Greenwich Mean Time Dale wrote: >> Howdy, >> >> I have a Samsung SSD 500GB drive that I ended up not using in my new >> build, went with the m.2 stick thingy. I decided that I would put it in >> the NAS box and replace the spinning rust drive. I booted a sysrescue >> image. I created and mounted both drives, creating directories as >> needed. I then one at a time used cp -av to copy /bin, /boot and so on >> skipping /dev, /proc and such that is created on the fly so to speak. I >> did create /sys and /proc tho. I even copied the home directory, not >> that there is much in there that I need. Once I got it all copied, I >> chrooted into the new drive. > The Handbook states you should -rbind the /dev of the host before you chroot. > Did you do this? Yes, I did. I have a text file in my root directory for things like mounting other OSs that I plan to chroot into, how to run grub and such. This is how I mounted things, excluding the root and boot file system. mount -t proc proc /mnt/gentoo/proc mount --rbind /dev /mnt/gentoo/dev mount --rbind /sys /mnt/gentoo/sys cp -L /etc/resolv.conf /mnt/gentoo/etc/ chroot /mnt/gentoo /bin/bash source /etc/profile I also ran env-update, just in case. I need to add that to the file. ;-) > >> I installed grub on it using grub-install >> /dev/sdb, since it is the second drive at this point. > Did you check if 'ls -l /dev/disk/by-id' within the chroot was mapping the > correct disk to /dev/sdb? > > I'll assume your NAS is a legacy BIOS not an EFI MoBo and grub-install /dev/ > sdb did not throw up any errors. > Yes, it is the old BIOS type setup. EFI I don't think was a thing back when it was made. Poor old mobo. I did out of habit put a GPT partition table on the SSD tho. I should have used the old DOS partition table thingy. My bad. I dug out the parted command to make it so it will work and it has worked in the past. >> I went back and >> looked at the install docs to be sure I didn't need to run anything >> else. Since I already had a config file and all, it should just work. >> >> When I try to boot with the SSD drive, I get this on the screen, pardon >> my having to type it in. This comes up right after the BIOS screen. >> >> >> loading operating system . . . >> GRUB >> >> >> That's it. It can't be the BIOS because if I connect the old drive as >> first drive, it boots just fine. I've missed a command somewhere. I'm >> sure it isn't the OS itself since it is a clone basically. I am almost >> certain I missed a grub command somewhere but can't figure out what it >> is. Searching for the error got other hits but not what I'm seeing. > You did not mention if you ran 'grub-mkconfig -o /boot/grub/grub.cfg' within > the chroot. This would read UUID and PARTUID of the new disk and its / > partition and add these to your grub.cfg file. Unless you used dd to clone > the partitions from the old to the new, the new disk partitions and fs IDs > will be different to the old disk. > I did run that. I wasn't sure if I needed to or not but I did anyway. It's one of the commands in my little grub text file, for when I can't remember how to do things, exactly. >> Has someone seen this before and recall how to fix it? Remember what >> command it is that I missed? > I think if you follow the Handbook to chroot into your new drive and update > your grub.cfg it /should/ work. While you're at it don't forget to edit your > fstab, if you are specifying filesystems in it using UUIDs. It's been stormy here. My NAS box is connected to a UPS but I still try not to run it when there is a chance of power failure. In between the storms, I booted into the original OS then mounted and chrooted into the SSD OS. I updated the fstab file, I forgot to do that before. It wasn't even right since I went from a DOS partition table to a GPT one. The numbers changed. Anyway. I ran all the grub commands and such and when I tried to boot it with only the SSD drive connected, same screen. No boot. Grub isn't happy about something. > >> I'm not sure this SSD drive is going to make that old NAS mobo go any >> faster. LOL It is kinda old. > I have found SSDs even when installed on old SATA 2.0 MoBos give a performance > boost - but it depends how slow the spinning disk was. Replacing a 10,000RPM > disk with an SSD would not provide any celebratory performance difference. > > PS. Check the MoBo BIOS is set to use AHCI for the SATA port you're connecting > this SSD on, or TRIM/discard won't work. The biggest thing that slows that system is that the CPU doesn't have AES support for my encryption on the drives. Still, I wanted to play with it and see if it would go any faster. I kinda hate having a nice SSD drive laying on the shelf doing nothing. I got a good deal but still, needs to get some exercise. I know I'm missing a step somewhere. What I may do, start over and put a DOS partition table on it and just copy over /etc and the world file. Then let it rebuild everything. If I do that, I got to wait until this storm is gone and may have to wait until we finish that last tree. We got one finished yesterday and got the last one cut up and ready to split, haul to the barn and stack. It's a LOT of wood. He said it will last him two years at least. He keeps 3 to 5 years worth on hand. I think he is at about the 6 year mark now. He loves working with wood. Oh, trees were dead or dying for those who hate to read about wood being cut up. The two we cut was a danger to the guys home and outbuildings, depending on where the wind took it. The first tree was dead. It had no leaves last year and was rotting at the bottom. The two trees had insect damage and were starting to die as well. When it fell, the trunk actually broke in a couple places since it was weakening. Most of the trees he cuts, storms put them on the ground. Cutting down a tree isn't something he does a whole lot of unless a tree is dead. Anyway, I may just do a quick reinstall and change partition tables. Maybe that has something to do with it. One reason I'd like to figure it out tho, may help some other poor soul who is trying to use some older hardware and runs into this problem. Dale :-) :-) [-- Attachment #2: Type: text/html, Size: 9515 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-15 20:42 ` Dale @ 2025-03-15 21:43 ` eric 2025-03-16 2:15 ` William Kenworthy 2025-03-16 5:04 ` Dale 0 siblings, 2 replies; 23+ messages in thread From: eric @ 2025-03-15 21:43 UTC (permalink / raw To: gentoo-user On 3/15/25 13:42, Dale wrote: > The biggest thing that slows that system is that the CPU doesn't have > AES support for my encryption on the drives. Still, I wanted to play > with it and see if it would go any faster. I kinda hate having a nice > SSD drive laying on the shelf doing nothing. I got a good deal but > still, needs to get some exercise. > > I know I'm missing a step somewhere. What I may do, start over and put > a DOS partition table on it and just copy over /etc and the world file. > Then let it rebuild everything. If I do that, I got to wait until this > storm is gone and may have to wait until we finish that last tree. We > got one finished yesterday and got the last one cut up and ready to > split, haul to the barn and stack. It's a LOT of wood. He said it will > last him two years at least. He keeps 3 to 5 years worth on hand. I > think he is at about the 6 year mark now. He loves working with wood. > Oh, trees were dead or dying for those who hate to read about wood being > cut up. The two we cut was a danger to the guys home and outbuildings, > depending on where the wind took it. The first tree was dead. It had > no leaves last year and was rotting at the bottom. The two trees had > insect damage and were starting to die as well. When it fell, the trunk > actually broke in a couple places since it was weakening. Most of the > trees he cuts, storms put them on the ground. Cutting down a tree isn't > something he does a whole lot of unless a tree is dead. > > Anyway, I may just do a quick reinstall and change partition tables. > Maybe that has something to do with it. One reason I'd like to figure > it out tho, may help some other poor soul who is trying to use some > older hardware and runs into this problem. The only thing I can think of that you may have missed is to rebuild your initrd.img or what ever ram disk you may be using to boot up. You would have to do this while chrooted. As others have stated, make sure your fstab file is updated correctly as well as the grub.cfg. Regards, Eric ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-15 21:43 ` eric @ 2025-03-16 2:15 ` William Kenworthy 2025-03-16 5:04 ` Dale 1 sibling, 0 replies; 23+ messages in thread From: William Kenworthy @ 2025-03-16 2:15 UTC (permalink / raw To: gentoo-user On 16/3/25 05:43, eric wrote: > On 3/15/25 13:42, Dale wrote: >> The biggest thing that slows that system is that the CPU doesn't have >> AES support for my encryption on the drives. Still, I wanted to play >> with it and see if it would go any faster. I kinda hate having a >> nice SSD drive laying on the shelf doing nothing. I got a good deal >> but still, needs to get some exercise. >> >> I know I'm missing a step somewhere. What I may do, start over and >> put a DOS partition table on it and just copy over /etc and the world >> file. Then let it rebuild everything. If I do that, I got to wait >> until this storm is gone and may have to wait until we finish that >> last tree. We got one finished yesterday and got the last one cut up >> and ready to split, haul to the barn and stack. It's a LOT of wood. >> He said it will last him two years at least. He keeps 3 to 5 years >> worth on hand. I think he is at about the 6 year mark now. He loves >> working with wood. Oh, trees were dead or dying for those who hate >> to read about wood being cut up. The two we cut was a danger to the >> guys home and outbuildings, depending on where the wind took it. The >> first tree was dead. It had no leaves last year and was rotting at >> the bottom. The two trees had insect damage and were starting to die >> as well. When it fell, the trunk actually broke in a couple places >> since it was weakening. Most of the trees he cuts, storms put them >> on the ground. Cutting down a tree isn't something he does a whole >> lot of unless a tree is dead. >> >> Anyway, I may just do a quick reinstall and change partition tables. >> Maybe that has something to do with it. One reason I'd like to >> figure it out tho, may help some other poor soul who is trying to use >> some older hardware and runs into this problem. > > The only thing I can think of that you may have missed is to rebuild > your initrd.img or what ever ram disk you may be using to boot up. You > would have to do this while chrooted. As others have stated, make sure > your fstab file is updated correctly as well as the grub.cfg. > > Regards, > Eric > > > have you enabled the nvme settings in the kernel and loaded the module if selected? BillK ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-15 21:43 ` eric 2025-03-16 2:15 ` William Kenworthy @ 2025-03-16 5:04 ` Dale 2025-03-16 5:34 ` William Kenworthy 1 sibling, 1 reply; 23+ messages in thread From: Dale @ 2025-03-16 5:04 UTC (permalink / raw To: gentoo-user eric wrote: > On 3/15/25 13:42, Dale wrote: >> The biggest thing that slows that system is that the CPU doesn't have >> AES support for my encryption on the drives. Still, I wanted to play >> with it and see if it would go any faster. I kinda hate having a >> nice SSD drive laying on the shelf doing nothing. I got a good deal >> but still, needs to get some exercise. >> >> I know I'm missing a step somewhere. What I may do, start over and >> put a DOS partition table on it and just copy over /etc and the world >> file. Then let it rebuild everything. If I do that, I got to wait >> until this storm is gone and may have to wait until we finish that >> last tree. We got one finished yesterday and got the last one cut up >> and ready to split, haul to the barn and stack. It's a LOT of wood. >> He said it will last him two years at least. He keeps 3 to 5 years >> worth on hand. I think he is at about the 6 year mark now. He loves >> working with wood. Oh, trees were dead or dying for those who hate >> to read about wood being cut up. The two we cut was a danger to the >> guys home and outbuildings, depending on where the wind took it. The >> first tree was dead. It had no leaves last year and was rotting at >> the bottom. The two trees had insect damage and were starting to die >> as well. When it fell, the trunk actually broke in a couple places >> since it was weakening. Most of the trees he cuts, storms put them >> on the ground. Cutting down a tree isn't something he does a whole >> lot of unless a tree is dead. >> >> Anyway, I may just do a quick reinstall and change partition tables. >> Maybe that has something to do with it. One reason I'd like to >> figure it out tho, may help some other poor soul who is trying to use >> some older hardware and runs into this problem. > > The only thing I can think of that you may have missed is to rebuild > your initrd.img or what ever ram disk you may be using to boot up. You > would have to do this while chrooted. As others have stated, make sure > your fstab file is updated correctly as well as the grub.cfg. > > Regards, > Eric > > Now that lead to something. First, I hadn't rebuilt the init thingy. So, I booted up, mounted, chrooted and all that. I then created a new init thingy and replaced the old one. Second. Then I also noticed something else. There was very little in /boot. I don't know if I accidentally erased it or if the copy process failed without telling me. I know I mounted it and copied it. I actually copied /boot first, then did a ls / and went down the list skipping /dev, /proc and such. I also did a ls /boot while in the chroot to be sure things matched up to the original. Plus, when I did the grub update to find kernels, init thingys and the firmware image, it showed it found them. What happened in between, no clue. Now here's another strange thing, sda1 is /boot. When I'm booted from the SSD, I can't mount sda1 for /boot. It complains about file system type. It's ext2 by the way. I need to look into that. I'll go back to the old drive and see what I can figure out. So, I forgot to update fstab, but it failed before it got that far anyway. I also didn't know I needed to rebuild the init thingy. Then there is the weird missing files in /boot. Then there is the inability to mount /boot while booted from the SSD, which shows not file system at all. lsblk says the same. Weird. Extra question. On my main rig, I have the GPT tools installed with package sys-apps/gptfdisk. It is installed and it even works. I've used it on my new rig to set up several drives including the m.2 stick for the OS but others for my LVM drives. Check this out tho. root@Gentoo-1 / # which cgdisk /usr/bin/cgdisk root@Gentoo-1 / # equery b /usr/bin/cgdisk * Searching for /usr/bin/cgdisk ... root@Gentoo-1 / # equery list sys-apps/gptfdisk * Searching for gptfdisk in sys-apps ... [IP-] [ ] sys-apps/gptfdisk-1.0.10-r1:0 root@Gentoo-1 / # equery f sys-apps/gptfdisk * Searching for gptfdisk in sys-apps ... * Contents of sys-apps/gptfdisk-1.0.10-r1: /usr /usr/sbin /usr/sbin/cgdisk /usr/sbin/fixparts /usr/sbin/gdisk /usr/sbin/sgdisk /usr/share /usr/share/doc /usr/share/doc/gptfdisk-1.0.10-r1 /usr/share/doc/gptfdisk-1.0.10-r1/NEWS.bz2 /usr/share/doc/gptfdisk-1.0.10-r1/README.bz2 /usr/share/man /usr/share/man/man8 /usr/share/man/man8/cgdisk.8.bz2 /usr/share/man/man8/fixparts.8.bz2 /usr/share/man/man8/gdisk.8.bz2 /usr/share/man/man8/sgdisk.8.bz2 root@Gentoo-1 / # As you can see, the package is installed, the cgdisk command is installed by emerge and all. Thing is, equery b and equery list doesn't find it but equery f does. I'm scratching my head here. The equery b should show the package it belongs too and equery list should list it as installed. Did I mess up something or is there some sort of bug in equery? Now to reboot and see what is up with /boot on the SSD. :/ Thanks. Dale :-) :-) ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-16 5:04 ` Dale @ 2025-03-16 5:34 ` William Kenworthy 2025-03-16 7:30 ` Dale 0 siblings, 1 reply; 23+ messages in thread From: William Kenworthy @ 2025-03-16 5:34 UTC (permalink / raw To: gentoo-user On 16/3/25 13:04, Dale wrote: > eric wrote: >> On 3/15/25 13:42, Dale wrote: >>> The biggest thing that slows that system is that the CPU doesn't have >>> AES support for my encryption on the drives. Still, I wanted to play >>> with it and see if it would go any faster. I kinda hate having a >>> nice SSD drive laying on the shelf doing nothing. I got a good deal >>> but still, needs to get some exercise. >>> >>> I know I'm missing a step somewhere. What I may do, start over and >>> put a DOS partition table on it and just copy over /etc and the world >>> file. Then let it rebuild everything. If I do that, I got to wait >>> until this storm is gone and may have to wait until we finish that >>> last tree. We got one finished yesterday and got the last one cut up >>> and ready to split, haul to the barn and stack. It's a LOT of wood. >>> He said it will last him two years at least. He keeps 3 to 5 years >>> worth on hand. I think he is at about the 6 year mark now. He loves >>> working with wood. Oh, trees were dead or dying for those who hate >>> to read about wood being cut up. The two we cut was a danger to the >>> guys home and outbuildings, depending on where the wind took it. The >>> first tree was dead. It had no leaves last year and was rotting at >>> the bottom. The two trees had insect damage and were starting to die >>> as well. When it fell, the trunk actually broke in a couple places >>> since it was weakening. Most of the trees he cuts, storms put them >>> on the ground. Cutting down a tree isn't something he does a whole >>> lot of unless a tree is dead. >>> >>> Anyway, I may just do a quick reinstall and change partition tables. >>> Maybe that has something to do with it. One reason I'd like to >>> figure it out tho, may help some other poor soul who is trying to use >>> some older hardware and runs into this problem. >> The only thing I can think of that you may have missed is to rebuild >> your initrd.img or what ever ram disk you may be using to boot up. You >> would have to do this while chrooted. As others have stated, make sure >> your fstab file is updated correctly as well as the grub.cfg. >> >> Regards, >> Eric >> >> > > Now that lead to something. First, I hadn't rebuilt the init thingy. > So, I booted up, mounted, chrooted and all that. I then created a new > init thingy and replaced the old one. Second. Then I also noticed > something else. There was very little in /boot. I don't know if I > accidentally erased it or if the copy process failed without telling > me. I know I mounted it and copied it. I actually copied /boot first, > then did a ls / and went down the list skipping /dev, /proc and such. I > also did a ls /boot while in the chroot to be sure things matched up to > the original. Plus, when I did the grub update to find kernels, init > thingys and the firmware image, it showed it found them. What happened > in between, no clue. Now here's another strange thing, sda1 is /boot. > When I'm booted from the SSD, I can't mount sda1 for /boot. It > complains about file system type. It's ext2 by the way. I need to look > into that. I'll go back to the old drive and see what I can figure out. > > So, I forgot to update fstab, but it failed before it got that far > anyway. I also didn't know I needed to rebuild the init thingy. Then > there is the weird missing files in /boot. Then there is the inability > to mount /boot while booted from the SSD, which shows not file system at > all. lsblk says the same. Weird. > > Extra question. On my main rig, I have the GPT tools installed with > package sys-apps/gptfdisk. It is installed and it even works. I've > used it on my new rig to set up several drives including the m.2 stick > for the OS but others for my LVM drives. Check this out tho. > > > root@Gentoo-1 / # which cgdisk > /usr/bin/cgdisk > root@Gentoo-1 / # equery b /usr/bin/cgdisk > * Searching for /usr/bin/cgdisk ... > root@Gentoo-1 / # equery list sys-apps/gptfdisk > * Searching for gptfdisk in sys-apps ... > [IP-] [ ] sys-apps/gptfdisk-1.0.10-r1:0 > root@Gentoo-1 / # equery f sys-apps/gptfdisk > * Searching for gptfdisk in sys-apps ... > * Contents of sys-apps/gptfdisk-1.0.10-r1: > /usr > /usr/sbin > /usr/sbin/cgdisk > /usr/sbin/fixparts > /usr/sbin/gdisk > /usr/sbin/sgdisk > /usr/share > /usr/share/doc > /usr/share/doc/gptfdisk-1.0.10-r1 > /usr/share/doc/gptfdisk-1.0.10-r1/NEWS.bz2 > /usr/share/doc/gptfdisk-1.0.10-r1/README.bz2 > /usr/share/man > /usr/share/man/man8 > /usr/share/man/man8/cgdisk.8.bz2 > /usr/share/man/man8/fixparts.8.bz2 > /usr/share/man/man8/gdisk.8.bz2 > /usr/share/man/man8/sgdisk.8.bz2 > root@Gentoo-1 / # > > > As you can see, the package is installed, the cgdisk command is > installed by emerge and all. Thing is, equery b and equery list doesn't > find it but equery f does. I'm scratching my head here. The equery b > should show the package it belongs too and equery list should list it as > installed. Did I mess up something or is there some sort of bug in > equery? > > Now to reboot and see what is up with /boot on the SSD. :/ > > Thanks. > > Dale > > :-) :-) > > > Depending how you built the initrd, it will likely use the current fstab and /etc/conf.d/modules as to what will be included. If you make changes to the system, you should rebuild the initrd (especially important if dracut is used in hostonly mode). You can use lsinitrd to make sure it actually includes what you think it does (its really only a file system after all) BillK ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-16 5:34 ` William Kenworthy @ 2025-03-16 7:30 ` Dale 2025-03-16 9:58 ` Dale 0 siblings, 1 reply; 23+ messages in thread From: Dale @ 2025-03-16 7:30 UTC (permalink / raw To: gentoo-user William Kenworthy wrote: > > On 16/3/25 13:04, Dale wrote: >> eric wrote: >>> On 3/15/25 13:42, Dale wrote: >>>> The biggest thing that slows that system is that the CPU doesn't have >>>> AES support for my encryption on the drives. Still, I wanted to play >>>> with it and see if it would go any faster. I kinda hate having a >>>> nice SSD drive laying on the shelf doing nothing. I got a good deal >>>> but still, needs to get some exercise. >>>> >>>> I know I'm missing a step somewhere. What I may do, start over and >>>> put a DOS partition table on it and just copy over /etc and the world >>>> file. Then let it rebuild everything. If I do that, I got to wait >>>> until this storm is gone and may have to wait until we finish that >>>> last tree. We got one finished yesterday and got the last one cut up >>>> and ready to split, haul to the barn and stack. It's a LOT of wood. >>>> He said it will last him two years at least. He keeps 3 to 5 years >>>> worth on hand. I think he is at about the 6 year mark now. He loves >>>> working with wood. Oh, trees were dead or dying for those who hate >>>> to read about wood being cut up. The two we cut was a danger to the >>>> guys home and outbuildings, depending on where the wind took it. The >>>> first tree was dead. It had no leaves last year and was rotting at >>>> the bottom. The two trees had insect damage and were starting to die >>>> as well. When it fell, the trunk actually broke in a couple places >>>> since it was weakening. Most of the trees he cuts, storms put them >>>> on the ground. Cutting down a tree isn't something he does a whole >>>> lot of unless a tree is dead. >>>> >>>> Anyway, I may just do a quick reinstall and change partition tables. >>>> Maybe that has something to do with it. One reason I'd like to >>>> figure it out tho, may help some other poor soul who is trying to use >>>> some older hardware and runs into this problem. >>> The only thing I can think of that you may have missed is to rebuild >>> your initrd.img or what ever ram disk you may be using to boot up. You >>> would have to do this while chrooted. As others have stated, make sure >>> your fstab file is updated correctly as well as the grub.cfg. >>> >>> Regards, >>> Eric >>> >>> >> >> Now that lead to something. First, I hadn't rebuilt the init thingy. >> So, I booted up, mounted, chrooted and all that. I then created a new >> init thingy and replaced the old one. Second. Then I also noticed >> something else. There was very little in /boot. I don't know if I >> accidentally erased it or if the copy process failed without telling >> me. I know I mounted it and copied it. I actually copied /boot first, >> then did a ls / and went down the list skipping /dev, /proc and such. I >> also did a ls /boot while in the chroot to be sure things matched up to >> the original. Plus, when I did the grub update to find kernels, init >> thingys and the firmware image, it showed it found them. What happened >> in between, no clue. Now here's another strange thing, sda1 is /boot. >> When I'm booted from the SSD, I can't mount sda1 for /boot. It >> complains about file system type. It's ext2 by the way. I need to look >> into that. I'll go back to the old drive and see what I can figure out. >> >> So, I forgot to update fstab, but it failed before it got that far >> anyway. I also didn't know I needed to rebuild the init thingy. Then >> there is the weird missing files in /boot. Then there is the inability >> to mount /boot while booted from the SSD, which shows not file system at >> all. lsblk says the same. Weird. >> >> Extra question. On my main rig, I have the GPT tools installed with >> package sys-apps/gptfdisk. It is installed and it even works. I've >> used it on my new rig to set up several drives including the m.2 stick >> for the OS but others for my LVM drives. Check this out tho. >> >> >> root@Gentoo-1 / # which cgdisk >> /usr/bin/cgdisk >> root@Gentoo-1 / # equery b /usr/bin/cgdisk >> * Searching for /usr/bin/cgdisk ... >> root@Gentoo-1 / # equery list sys-apps/gptfdisk >> * Searching for gptfdisk in sys-apps ... >> [IP-] [ ] sys-apps/gptfdisk-1.0.10-r1:0 >> root@Gentoo-1 / # equery f sys-apps/gptfdisk >> * Searching for gptfdisk in sys-apps ... >> * Contents of sys-apps/gptfdisk-1.0.10-r1: >> /usr >> /usr/sbin >> /usr/sbin/cgdisk >> /usr/sbin/fixparts >> /usr/sbin/gdisk >> /usr/sbin/sgdisk >> /usr/share >> /usr/share/doc >> /usr/share/doc/gptfdisk-1.0.10-r1 >> /usr/share/doc/gptfdisk-1.0.10-r1/NEWS.bz2 >> /usr/share/doc/gptfdisk-1.0.10-r1/README.bz2 >> /usr/share/man >> /usr/share/man/man8 >> /usr/share/man/man8/cgdisk.8.bz2 >> /usr/share/man/man8/fixparts.8.bz2 >> /usr/share/man/man8/gdisk.8.bz2 >> /usr/share/man/man8/sgdisk.8.bz2 >> root@Gentoo-1 / # >> >> >> As you can see, the package is installed, the cgdisk command is >> installed by emerge and all. Thing is, equery b and equery list doesn't >> find it but equery f does. I'm scratching my head here. The equery b >> should show the package it belongs too and equery list should list it as >> installed. Did I mess up something or is there some sort of bug in >> equery? >> >> Now to reboot and see what is up with /boot on the SSD. :/ >> >> Thanks. >> >> Dale >> >> :-) :-) >> >> >> > Depending how you built the initrd, it will likely use the current > fstab and /etc/conf.d/modules as to what will be included. If you > make changes to the system, you should rebuild the initrd (especially > important if dracut is used in hostonly mode). > > You can use lsinitrd to make sure it actually includes what you think > it does (its really only a file system after all) > > BillK Well, this got interesting. I booted the spinning rust drive again and redone the /boot from the old system. I rebuilt the init thingy because the one that was there was for the old drive. I then ran the usual grub commands to generate the config file and even reinstalled grub just to be sure. When I tried to reboot the SSD drive, I was back to the original screen at the start of this thread. While I'd like to fix this and perhaps that fix help someone else in the future, this is just getting annoying. I should have put a DOS partition on the thing and it could be that is the problem despite the parted trick that I've used in the past. I dunno. So I'm just going to start over and use a DOS partition table this time. That may fix it. If that fails, I'll just reinstall from scratch. That should fix it for sure. I got all the config files, world file and such that I need. I just wish it was colder outside. That little mobo creates some heat. LOL In the future, if someone runs into this thread, try rebuilding the init thingy and all the grub update commands. It should work. It did here once. Thanks to all for helping. Dale :-) :-) Hmmm. I usually use dd or shred to erase a spinning rust drive. How in the heck do I do this on a SSD and not affect it in a negative way? I never thought about erasing one of those before. :-| ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-16 7:30 ` Dale @ 2025-03-16 9:58 ` Dale 2025-03-16 11:40 ` Michael 0 siblings, 1 reply; 23+ messages in thread From: Dale @ 2025-03-16 9:58 UTC (permalink / raw To: gentoo-user Dale wrote: > > Well, this got interesting. I booted the spinning rust drive again and > redone the /boot from the old system. I rebuilt the init thingy because > the one that was there was for the old drive. I then ran the usual grub > commands to generate the config file and even reinstalled grub just to > be sure. When I tried to reboot the SSD drive, I was back to the > original screen at the start of this thread. While I'd like to fix this > and perhaps that fix help someone else in the future, this is just > getting annoying. I should have put a DOS partition on the thing and it > could be that is the problem despite the parted trick that I've used in > the past. I dunno. > > So I'm just going to start over and use a DOS partition table this > time. That may fix it. If that fails, I'll just reinstall from > scratch. That should fix it for sure. I got all the config files, > world file and such that I need. I just wish it was colder outside. > That little mobo creates some heat. LOL > > In the future, if someone runs into this thread, try rebuilding the init > thingy and all the grub update commands. It should work. It did here > once. > > Thanks to all for helping. > > Dale > > :-) :-) > > Hmmm. I usually use dd or shred to erase a spinning rust drive. How in > the heck do I do this on a SSD and not affect it in a negative way? I > never thought about erasing one of those before. :-| > Update. I found a command that wipes partition tables in my little file, where I put things I forget about quite often. This is my little note. wipefs -a -f /dev/sdX # erase partition table for DOS or GPT It's very fast so I assume it erases only the needed bits but doesn't write to other areas, erase user data to prevent recovery or anything. Still, since I was going to put something else on it right away, I wasn't worried about that anyway. After all that, I partitioned the SSD, copied everything over, chrooted into the SSD OS and then made a new init thingy, updated grub, installed grub and I also re-emerged the linux firmware package. It puts a .img file in /boot and grub picks that up. I don't know if it matters but since I did everything else, that was one that I hadn't done before. Maybe it was wrong on the SSD and grub loads it first. If it fails, no boot. It's possible anyway. Oh, I also set the labels on the file systems for boot, root and home, like I usually do. I didn't have to update fstab this time. Those still matched up just fine with labels. Again, thanks to all who helped. It could be the GPT partition table or it might have been that firmware image. I dunno. It works now tho. Oh, it might boot a tiny bit faster. Maybe. Dale :-) :-) ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-16 9:58 ` Dale @ 2025-03-16 11:40 ` Michael 2025-03-16 14:05 ` Michael 0 siblings, 1 reply; 23+ messages in thread From: Michael @ 2025-03-16 11:40 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 3504 bytes --] On Sunday, 16 March 2025 09:58:42 Greenwich Mean Time Dale wrote: > Dale wrote: > > Well, this got interesting. I booted the spinning rust drive again and > > redone the /boot from the old system. I rebuilt the init thingy because > > the one that was there was for the old drive. I then ran the usual grub > > commands to generate the config file and even reinstalled grub just to > > be sure. When I tried to reboot the SSD drive, I was back to the > > original screen at the start of this thread. While I'd like to fix this > > and perhaps that fix help someone else in the future, this is just > > getting annoying. I should have put a DOS partition on the thing and it > > could be that is the problem despite the parted trick that I've used in > > the past. I dunno. > > > > So I'm just going to start over and use a DOS partition table this > > time. That may fix it. If that fails, I'll just reinstall from > > scratch. That should fix it for sure. I got all the config files, > > world file and such that I need. I just wish it was colder outside. > > That little mobo creates some heat. LOL > > > > In the future, if someone runs into this thread, try rebuilding the init > > thingy and all the grub update commands. It should work. It did here > > once. > > > > Thanks to all for helping. > > > > Dale > > > > :-) :-) > > > > Hmmm. I usually use dd or shred to erase a spinning rust drive. How in > > the heck do I do this on a SSD and not affect it in a negative way? I > > never thought about erasing one of those before. :-| > > Update. I found a command that wipes partition tables in my little > file, where I put things I forget about quite often. This is my little > note. > > > wipefs -a -f /dev/sdX # erase partition table for DOS or GPT > > > It's very fast so I assume it erases only the needed bits but doesn't > write to other areas, erase user data to prevent recovery or anything. > Still, since I was going to put something else on it right away, I > wasn't worried about that anyway. You can use fdisk/gdisk/parted to change the partition table from legacy DOS- MBR to GPT, then create the new partitions, finally format them with a suitable filesystem. However, you did not need to do this, GPT would be totally suitable for your disk. > After all that, I partitioned the SSD, copied everything over, chrooted > into the SSD OS and then made a new init thingy, updated grub, installed > grub and I also re-emerged the linux firmware package. It puts a .img > file in /boot and grub picks that up. I don't know if it matters but > since I did everything else, that was one that I hadn't done before. > Maybe it was wrong on the SSD and grub loads it first. If it fails, no > boot. It's possible anyway. I wouldn't think your aged system wouldn't boot if some firmware file was missing - unless such firmware was necessary to access your drives. > Oh, I also set the labels on the file systems for boot, root and home, > like I usually do. I didn't have to update fstab this time. Those > still matched up just fine with labels. > > Again, thanks to all who helped. It could be the GPT partition table or > it might have been that firmware image. I dunno. It works now tho. > Oh, it might boot a tiny bit faster. Maybe. > > Dale > > :-) :-) I think the problem was with your initrd, plus the missing grub and other files from /boot fs indicate you may have not mounted it the first time you chrooted. [-- Attachment #2: This is a digitally signed message part. --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-16 11:40 ` Michael @ 2025-03-16 14:05 ` Michael 2025-03-16 19:14 ` Dale 2025-03-17 1:01 ` [gentoo-user] " Grant Edwards 0 siblings, 2 replies; 23+ messages in thread From: Michael @ 2025-03-16 14:05 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 4572 bytes --] On Sunday, 16 March 2025 11:40:14 Greenwich Mean Time you wrote: > On Sunday, 16 March 2025 09:58:42 Greenwich Mean Time Dale wrote: > > Dale wrote: > > > Well, this got interesting. I booted the spinning rust drive again and > > > redone the /boot from the old system. I rebuilt the init thingy because > > > the one that was there was for the old drive. I then ran the usual grub > > > commands to generate the config file and even reinstalled grub just to > > > be sure. When I tried to reboot the SSD drive, I was back to the > > > original screen at the start of this thread. While I'd like to fix this > > > and perhaps that fix help someone else in the future, this is just > > > getting annoying. I should have put a DOS partition on the thing and it > > > could be that is the problem despite the parted trick that I've used in > > > the past. I dunno. > > > > > > So I'm just going to start over and use a DOS partition table this > > > time. That may fix it. If that fails, I'll just reinstall from > > > scratch. That should fix it for sure. I got all the config files, > > > world file and such that I need. I just wish it was colder outside. > > > That little mobo creates some heat. LOL > > > > > > In the future, if someone runs into this thread, try rebuilding the init > > > thingy and all the grub update commands. It should work. It did here > > > once. > > > > > > Thanks to all for helping. > > > > > > Dale > > > > > > :-) :-) > > > > > > Hmmm. I usually use dd or shred to erase a spinning rust drive. How in > > > the heck do I do this on a SSD and not affect it in a negative way? I > > > never thought about erasing one of those before. :-| > > > > Update. I found a command that wipes partition tables in my little > > file, where I put things I forget about quite often. This is my little > > note. > > > > > > wipefs -a -f /dev/sdX # erase partition table for DOS or GPT > > > > > > It's very fast so I assume it erases only the needed bits but doesn't > > write to other areas, erase user data to prevent recovery or anything. > > Still, since I was going to put something else on it right away, I > > wasn't worried about that anyway. > > You can use fdisk/gdisk/parted to change the partition table from legacy > DOS- MBR to GPT, then create the new partitions, finally format them with a > suitable filesystem. > > However, you did not need to do this, GPT would be totally suitable for your > disk. Ugh! I didn't provide a comprehensive answer - sorry. All this MBR nostalgia I've been trying to forget. LOL! If you are installing GRUB on a GPT disk, which is meant to boot on a legacy BIOS MoBo, you *must* create a BIOS Boot Partition (gdisk code EF02). GRUB will drop its boot.img in the disk's MBR (sector 0) then would try to install its core.img in sector 1, exactly where GPT has stored its own primary table. With a BIOS Boot Partition this clash is averted. Or, alternatively, you stick with a conventional MBR-DOS partition table which will work fine as long as the partitionable space is no larger than 2TB (using 512-byte sectors) and the total number of partitions (primary plus logical) is not ridiculously large. > > After all that, I partitioned the SSD, copied everything over, chrooted > > into the SSD OS and then made a new init thingy, updated grub, installed > > grub and I also re-emerged the linux firmware package. It puts a .img > > file in /boot and grub picks that up. I don't know if it matters but > > since I did everything else, that was one that I hadn't done before. > > Maybe it was wrong on the SSD and grub loads it first. If it fails, no > > boot. It's possible anyway. > > I wouldn't think your aged system wouldn't boot if some firmware file was > missing - unless such firmware was necessary to access your drives. > > > Oh, I also set the labels on the file systems for boot, root and home, > > like I usually do. I didn't have to update fstab this time. Those > > still matched up just fine with labels. > > > > Again, thanks to all who helped. It could be the GPT partition table or > > it might have been that firmware image. I dunno. It works now tho. > > Oh, it might boot a tiny bit faster. Maybe. > > > > Dale > > > > :-) :-) > > I think the problem was with your initrd, plus the missing grub and other > files from /boot fs indicate you may have not mounted it the first time you > chrooted. Rethinking all this techno-legacy, I think a critical problem was the lack of a BIOS Boot Partition as explained above. [-- Attachment #2: This is a digitally signed message part. --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-16 14:05 ` Michael @ 2025-03-16 19:14 ` Dale 2025-03-17 1:01 ` [gentoo-user] " Grant Edwards 1 sibling, 0 replies; 23+ messages in thread From: Dale @ 2025-03-16 19:14 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 6385 bytes --] Michael wrote: > On Sunday, 16 March 2025 11:40:14 Greenwich Mean Time you wrote: >> On Sunday, 16 March 2025 09:58:42 Greenwich Mean Time Dale wrote: >>> Dale wrote: >>>> Well, this got interesting. I booted the spinning rust drive again and >>>> redone the /boot from the old system. I rebuilt the init thingy because >>>> the one that was there was for the old drive. I then ran the usual grub >>>> commands to generate the config file and even reinstalled grub just to >>>> be sure. When I tried to reboot the SSD drive, I was back to the >>>> original screen at the start of this thread. While I'd like to fix this >>>> and perhaps that fix help someone else in the future, this is just >>>> getting annoying. I should have put a DOS partition on the thing and it >>>> could be that is the problem despite the parted trick that I've used in >>>> the past. I dunno. >>>> >>>> So I'm just going to start over and use a DOS partition table this >>>> time. That may fix it. If that fails, I'll just reinstall from >>>> scratch. That should fix it for sure. I got all the config files, >>>> world file and such that I need. I just wish it was colder outside. >>>> That little mobo creates some heat. LOL >>>> >>>> In the future, if someone runs into this thread, try rebuilding the init >>>> thingy and all the grub update commands. It should work. It did here >>>> once. >>>> >>>> Thanks to all for helping. >>>> >>>> Dale >>>> >>>> :-) :-) >>>> >>>> Hmmm. I usually use dd or shred to erase a spinning rust drive. How in >>>> the heck do I do this on a SSD and not affect it in a negative way? I >>>> never thought about erasing one of those before. :-| >>> Update. I found a command that wipes partition tables in my little >>> file, where I put things I forget about quite often. This is my little >>> note. >>> >>> >>> wipefs -a -f /dev/sdX # erase partition table for DOS or GPT >>> >>> >>> It's very fast so I assume it erases only the needed bits but doesn't >>> write to other areas, erase user data to prevent recovery or anything. >>> Still, since I was going to put something else on it right away, I >>> wasn't worried about that anyway. >> You can use fdisk/gdisk/parted to change the partition table from legacy >> DOS- MBR to GPT, then create the new partitions, finally format them with a >> suitable filesystem. >> >> However, you did not need to do this, GPT would be totally suitable for your >> disk. > Ugh! I didn't provide a comprehensive answer - sorry. All this MBR nostalgia > I've been trying to forget. LOL! > > If you are installing GRUB on a GPT disk, which is meant to boot on a legacy > BIOS MoBo, you *must* create a BIOS Boot Partition (gdisk code EF02). GRUB > will drop its boot.img in the disk's MBR (sector 0) then would try to install > its core.img in sector 1, exactly where GPT has stored its own primary table. > With a BIOS Boot Partition this clash is averted. > > Or, alternatively, you stick with a conventional MBR-DOS partition table which > will work fine as long as the partitionable space is no larger than 2TB (using > 512-byte sectors) and the total number of partitions (primary plus logical) is > not ridiculously large. > When I first did this and got through with the copy process, grub complained about that. I ran into that before and found a fix. Of course, I couldn't remember how to fix it tho. Off to my little cheat file, my memory file. This is what I put there to fix this, worked a couple times before. # grub-install fails with "grub-install: warning: this GPT partition label contains no BIOS Boot Partition; embedding won't be possible." Using parted command. # # parted /dev/sdX # set 1 boot off # set 1 bios_grub on # q # # then install grub. This happens on drives where GPT is used instead of MBR. I did that but I think it messed up the file system for /boot when I did it. I don't recall it doing that when I used it before tho. When I ran lsblk, it showed a file system for root and home but not /boot anymore. I know I formatted it because it was the first one I did and it is always ext2, others are ext4. I also ran du -shc /* after the copy process to make sure that /dev, /sys, /proc and such were empty and others that should have files were about the right size. I know I mounted and copied /boot. When I finish mounting things to chroot, I type in mount to be sure I did them all right. >>> After all that, I partitioned the SSD, copied everything over, chrooted >>> into the SSD OS and then made a new init thingy, updated grub, installed >>> grub and I also re-emerged the linux firmware package. It puts a .img >>> file in /boot and grub picks that up. I don't know if it matters but >>> since I did everything else, that was one that I hadn't done before. >>> Maybe it was wrong on the SSD and grub loads it first. If it fails, no >>> boot. It's possible anyway. >> I wouldn't think your aged system wouldn't boot if some firmware file was >> missing - unless such firmware was necessary to access your drives. >> >>> Oh, I also set the labels on the file systems for boot, root and home, >>> like I usually do. I didn't have to update fstab this time. Those >>> still matched up just fine with labels. >>> >>> Again, thanks to all who helped. It could be the GPT partition table or >>> it might have been that firmware image. I dunno. It works now tho. >>> Oh, it might boot a tiny bit faster. Maybe. >>> >>> Dale >>> >>> :-) :-) >> I think the problem was with your initrd, plus the missing grub and other >> files from /boot fs indicate you may have not mounted it the first time you >> chrooted. > Rethinking all this techno-legacy, I think a critical problem was the lack of > a BIOS Boot Partition as explained above. I think me fixing not having it is what caused the problem. I figure if we kept banging at the problem, we could have fixed it. Thing is, given things I got going on, I don't have time to keep arguing with that old thing. LOL It was easier to just start over and put a DOS partition table on it and be done with it. Now it is done the right way, for that old thing anyway. I booted it up twice now. I think it is going to be OK. I'll update my backups later. I got some new videos to rename first tho. Found some vintage stuff. :-D Dale :-) :-) [-- Attachment #2: Type: text/html, Size: 8579 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* [gentoo-user] Re: Grub fails. I missed something. 2025-03-16 14:05 ` Michael 2025-03-16 19:14 ` Dale @ 2025-03-17 1:01 ` Grant Edwards 2025-03-17 2:34 ` Dale 2025-03-17 13:28 ` Grant Edwards 1 sibling, 2 replies; 23+ messages in thread From: Grant Edwards @ 2025-03-17 1:01 UTC (permalink / raw To: gentoo-user On 2025-03-16, Michael <confabulate@kintzios.com> wrote: > Ugh! I didn't provide a comprehensive answer - sorry. All this MBR nostalgia > I've been trying to forget. LOL! > > If you are installing GRUB on a GPT disk, which is meant to boot on > a legacy BIOS MoBo, you *must* create a BIOS Boot Partition (gdisk > code EF02). GRUB will drop its boot.img in the disk's MBR (sector > 0) then would try to install its core.img in sector 1, exactly where > GPT has stored its own primary table. With a BIOS Boot Partition > this clash is averted. You /can/ use an embedded block list to install legacy BIOS boot mode grub using an MBR table without a BIOS Boot Partition, but don't do it. It requires manual intervention any time grub gets updated, so it's a pain to maintain. The "right" answer is to create a BIOS boot partition. Then it will "just work". ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Re: Grub fails. I missed something. 2025-03-17 1:01 ` [gentoo-user] " Grant Edwards @ 2025-03-17 2:34 ` Dale 2025-03-17 8:21 ` Michael 2025-03-17 13:28 ` Grant Edwards 1 sibling, 1 reply; 23+ messages in thread From: Dale @ 2025-03-17 2:34 UTC (permalink / raw To: gentoo-user Grant Edwards wrote: > On 2025-03-16, Michael <confabulate@kintzios.com> wrote: > >> Ugh! I didn't provide a comprehensive answer - sorry. All this MBR nostalgia >> I've been trying to forget. LOL! >> >> If you are installing GRUB on a GPT disk, which is meant to boot on >> a legacy BIOS MoBo, you *must* create a BIOS Boot Partition (gdisk >> code EF02). GRUB will drop its boot.img in the disk's MBR (sector >> 0) then would try to install its core.img in sector 1, exactly where >> GPT has stored its own primary table. With a BIOS Boot Partition >> this clash is averted. > You /can/ use an embedded block list to install legacy BIOS boot mode > grub using an MBR table without a BIOS Boot Partition, but don't do > it. It requires manual intervention any time grub gets updated, so it's > a pain to maintain. The "right" answer is to create a BIOS boot > partition. Then it will "just work". > I can second that, from experience. I might add while I'm typing, I'm getting ready to update my backups. I just booted the NAS box. I hit the power button on the way to my chair. By the time I read your reply, it was already sitting at the login prompt. I think it boots a little faster. Having the OS on a SSD might be a little faster. While I like the new GPT way, I really need to use the old way on the older hardware. I just keep forgetting to. :/ Dale :-) :-) ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Re: Grub fails. I missed something. 2025-03-17 2:34 ` Dale @ 2025-03-17 8:21 ` Michael 0 siblings, 0 replies; 23+ messages in thread From: Michael @ 2025-03-17 8:21 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 1747 bytes --] On Monday, 17 March 2025 02:34:47 Greenwich Mean Time Dale wrote: > Grant Edwards wrote: > > On 2025-03-16, Michael <confabulate@kintzios.com> wrote: > >> Ugh! I didn't provide a comprehensive answer - sorry. All this MBR > >> nostalgia I've been trying to forget. LOL! > >> > >> If you are installing GRUB on a GPT disk, which is meant to boot on > >> a legacy BIOS MoBo, you *must* create a BIOS Boot Partition (gdisk > >> code EF02). GRUB will drop its boot.img in the disk's MBR (sector > >> 0) then would try to install its core.img in sector 1, exactly where > >> GPT has stored its own primary table. With a BIOS Boot Partition > >> this clash is averted. > > > > You /can/ use an embedded block list to install legacy BIOS boot mode > > grub using an MBR table without a BIOS Boot Partition, but don't do > > it. It requires manual intervention any time grub gets updated, so it's > > a pain to maintain. The "right" answer is to create a BIOS boot > > partition. Then it will "just work". > > I can second that, from experience. I might add while I'm typing, I'm > getting ready to update my backups. I just booted the NAS box. I hit > the power button on the way to my chair. By the time I read your reply, > it was already sitting at the login prompt. I think it boots a little > faster. Having the OS on a SSD might be a little faster. > > While I like the new GPT way, I really need to use the old way on the > older hardware. I just keep forgetting to. :/ > > Dale > > :-) :-) Details on size recommendation for storing GRUB Stage 2 image is details here, including the parted stanza for creating a BIOS Boot Partition on GPT disks: https://www.gnu.org/software/grub/manual/grub/grub.html#BIOS-installation [-- Attachment #2: This is a digitally signed message part. --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* [gentoo-user] Re: Grub fails. I missed something. 2025-03-17 1:01 ` [gentoo-user] " Grant Edwards 2025-03-17 2:34 ` Dale @ 2025-03-17 13:28 ` Grant Edwards 1 sibling, 0 replies; 23+ messages in thread From: Grant Edwards @ 2025-03-17 13:28 UTC (permalink / raw To: gentoo-user On 2025-03-17, Grant Edwards <grant.b.edwards@gmail.com> wrote: > You /can/ use an embedded block list to install legacy BIOS boot mode > grub using an MBR table without a BIOS Boot Partition, but don't do > it. [,,,] Oops, I meant to say "legacy BIOS boot mode grub using a GPT partition table..." > It requires manual intervention any time grub gets updated, so it's > a pain to maintain. The "right" answer is to create a BIOS boot > partition. Then it will "just work". ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-15 7:29 [gentoo-user] Grub fails. I missed something Dale 2025-03-15 9:18 ` Michael @ 2025-03-17 3:50 ` Dale 2025-03-17 8:10 ` Michael 2025-03-18 22:35 ` Frank Steinmetzger 1 sibling, 2 replies; 23+ messages in thread From: Dale @ 2025-03-17 3:50 UTC (permalink / raw To: gentoo-user Dale wrote: > Howdy, > > New problem. As I mentioned in another reply, I booted the NAS box to update my backups. The thing won't let me login. I type in root, it sits there for 20 or 30 seconds then returns to a login prompt. I also tried the user dale but no joy there either. I'm back to spinning rust to update my backups. Now what in the heck causes that? I'm about ready to just reinstall the OS. This copy process just isn't working well. If it's not one thing, it's something else. Thoughts? Just reinstall and get it over with? LOL Dale :-) :-) ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-17 3:50 ` [gentoo-user] " Dale @ 2025-03-17 8:10 ` Michael 2025-03-20 2:25 ` Dale 2025-03-18 22:35 ` Frank Steinmetzger 1 sibling, 1 reply; 23+ messages in thread From: Michael @ 2025-03-17 8:10 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 1192 bytes --] You could chroot from a liveUSB or better your old hdd and check you have /etc /root and /home/dale in place and the contents and access rights have been copied over correctly - rsync should do this fast enough. Before you start nuking things indiscriminately please note your /etc/fstab is now different(?). Alternatively, you're into checking /etc/passwd, /etc/shadow, /etc/group, / etc/pam.d/* to see what may have been missed out and copying over or perhaps reinstalling whatever package may have gone bad. On Monday, 17 March 2025 03:50:05 Greenwich Mean Time Dale wrote: > Dale wrote: > > Howdy, > > New problem. As I mentioned in another reply, I booted the NAS box to > update my backups. The thing won't let me login. I type in root, it > sits there for 20 or 30 seconds then returns to a login prompt. I also > tried the user dale but no joy there either. I'm back to spinning rust > to update my backups. > > Now what in the heck causes that? I'm about ready to just reinstall the > OS. This copy process just isn't working well. If it's not one thing, > it's something else. > > Thoughts? Just reinstall and get it over with? LOL > > Dale > > :-) :-) [-- Attachment #2: This is a digitally signed message part. --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-17 8:10 ` Michael @ 2025-03-20 2:25 ` Dale 2025-03-23 5:41 ` Dale 0 siblings, 1 reply; 23+ messages in thread From: Dale @ 2025-03-20 2:25 UTC (permalink / raw To: gentoo-user Michael wrote: > You could chroot from a liveUSB or better your old hdd and check you have /etc > /root and /home/dale in place and the contents and access rights have been > copied over correctly - rsync should do this fast enough. Before you start > nuking things indiscriminately please note your /etc/fstab is now > different(?). > > Alternatively, you're into checking /etc/passwd, /etc/shadow, /etc/group, / > etc/pam.d/* to see what may have been missed out and copying over or perhaps > reinstalling whatever package may have gone bad. > Sorry it took me a bit to do anything with this. We still working on that tree. We getting close to being done. Anyway, I mounted the new SSD OS on the old OS and copied over /etc and /root again. I really don't need /home much since I only use root on that thing. Oh, for fstab, I used the same labels on each. After doing that, I shutdown, unplugged the old drive and booted the SSD OS up. I was able to login over ssh even. I'm sure something in /etc was messed up somehow. I think it worked a couple times before failing. So, this time, I did several reboots and shutdowns just to be as sure as I could be. It worked each time. After I hit send, I'll reboot again and it will fail. Isn't that how it usually works???? ROFL I might be back in a few minutes. o_O Dale :-) :-) ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-20 2:25 ` Dale @ 2025-03-23 5:41 ` Dale 2025-03-23 22:28 ` Frank Steinmetzger 0 siblings, 1 reply; 23+ messages in thread From: Dale @ 2025-03-23 5:41 UTC (permalink / raw To: gentoo-user Dale wrote: > > Sorry it took me a bit to do anything with this. We still working on > that tree. We getting close to being done. Anyway, I mounted the new > SSD OS on the old OS and copied over /etc and /root again. I really > don't need /home much since I only use root on that thing. Oh, for > fstab, I used the same labels on each. After doing that, I shutdown, > unplugged the old drive and booted the SSD OS up. I was able to login > over ssh even. I'm sure something in /etc was messed up somehow. I > think it worked a couple times before failing. So, this time, I did > several reboots and shutdowns just to be as sure as I could be. It > worked each time. > > After I hit send, I'll reboot again and it will fail. Isn't that how it > usually works???? ROFL > > I might be back in a few minutes. o_O > > Dale > > :-) :-) > Well, it took a little longer than I expected. I booted the NAS box to update my backups. It booted just fine, couldn't login tho. I usually use ssh and meant to save the error but already cleared the Konsole. Force of habit. My plan, reinstall the OS on the SSD and be done with it. It likely has a simple fix but it's either reinstall or target practice. O_o Oh, it did this after I removed the old spinning rust drive and mounted the SSD in its place. Go figure. If I had waited to swap the hardware, it would have likely still worked fine. It would only fail after I bag up the spinning rust drive and put it on the shelf. ;-) LOL Weird problem tho. Dale :-) :-) ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-23 5:41 ` Dale @ 2025-03-23 22:28 ` Frank Steinmetzger 2025-03-24 0:38 ` Dale 0 siblings, 1 reply; 23+ messages in thread From: Frank Steinmetzger @ 2025-03-23 22:28 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 2005 bytes --] Am Sun, Mar 23, 2025 at 12:41:31AM -0500 schrieb Dale: > Dale wrote: > > > > Sorry it took me a bit to do anything with this. We still working on > > that tree. We getting close to being done. Anyway, I mounted the new > > SSD OS on the old OS and copied over /etc and /root again. I really > > don't need /home much since I only use root on that thing. Oh, for > > fstab, I used the same labels on each. After doing that, I shutdown, > > unplugged the old drive and booted the SSD OS up. I was able to login > > over ssh even. I'm sure something in /etc was messed up somehow. I > > think it worked a couple times before failing. So, this time, I did > > several reboots and shutdowns just to be as sure as I could be. It > > worked each time. > > Well, it took a little longer than I expected. I booted the NAS box to > update my backups. It booted just fine, couldn't login tho. How do you know it booted fine? Did you have a monitor attached? Could you log in locally with a keyboard? > I usually > use ssh and meant to save the error but already cleared the Konsole. > Force of habit. My plan, reinstall the OS on the SSD and be done with > it. Would be really helpful to know the error message. For instance whether it came from ssh, the network, PAM or whatever else is involved in the login process. Perhaps it’s got something to do with ssh host keys, because after moving the SSD, the system has a different IP, but your machine still knows the host key from a different IP. Did the error message start with @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@? > It likely has a simple fix but it's either reinstall or target practice. Due to the nature of Gentoo, I’d always prefer fixing over reinstall. It’s just faster and better for the environment. -- Grüße | Greetings | Salut | Qapla’ Please do not share anything from, with or about me on any social network. The best thing of Sundays is Saturday evening. [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-23 22:28 ` Frank Steinmetzger @ 2025-03-24 0:38 ` Dale 0 siblings, 0 replies; 23+ messages in thread From: Dale @ 2025-03-24 0:38 UTC (permalink / raw To: gentoo-user Frank Steinmetzger wrote: > Am Sun, Mar 23, 2025 at 12:41:31AM -0500 schrieb Dale: >> Dale wrote: >>> Sorry it took me a bit to do anything with this. We still working on >>> that tree. We getting close to being done. Anyway, I mounted the new >>> SSD OS on the old OS and copied over /etc and /root again. I really >>> don't need /home much since I only use root on that thing. Oh, for >>> fstab, I used the same labels on each. After doing that, I shutdown, >>> unplugged the old drive and booted the SSD OS up. I was able to login >>> over ssh even. I'm sure something in /etc was messed up somehow. I >>> think it worked a couple times before failing. So, this time, I did >>> several reboots and shutdowns just to be as sure as I could be. It >>> worked each time. >> Well, it took a little longer than I expected. I booted the NAS box to >> update my backups. It booted just fine, couldn't login tho. > How do you know it booted fine? Did you have a monitor attached? > Could you log in locally with a keyboard? > I do have a monitor hooked up. Keep saying I'm going to put the monitor on the shelf before I bump it and knock it over or something and break it. Those screens are touchy. Nothing like the old CRT days for sure. I first tried to login over ssh from my main rig. Didn't work. When I tried to login with the keyboard connected to the machine itself, I could type in root, hit return and it would sit for a bit, then return to a login prompt. It never asked for a password. I had to use the alt sysrq key trick to shut it down as graceful as I could without being able to login. >> I usually >> use ssh and meant to save the error but already cleared the Konsole. >> Force of habit. My plan, reinstall the OS on the SSD and be done with >> it. > Would be really helpful to know the error message. For instance whether it > came from ssh, the network, PAM or whatever else is involved in the login > process. Perhaps it’s got something to do with ssh host keys, because after > moving the SSD, the system has a different IP, but your machine still knows > the host key from a different IP. > Did the error message start with @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@? I meant to leave the one where I tried to ssh in on my screen. Thing is, when I complete a task, I tend to clear the screen. I forgot and cleared it out of habit and the error was gone. I don't recall any @ stuff. To be honest tho, when it failed, I just grabbed the keyboard and tried it. I didn't really read it. It wasn't the usual key don't match thingy tho. >> It likely has a simple fix but it's either reinstall or target practice. > Due to the nature of Gentoo, I’d always prefer fixing over reinstall. It’s > just faster and better for the environment. > I wouldn't have minded fixing it but it was taking way longer than just reinstalling from scratch. I did have backups but just copied what I needed, nfs, make.conf and such from the old drive. I didn't need to copy much over really. Mostly just settings like make.conf and my exports file. Oh, /root as well. Got my little so called scripts in there. Anyway, the install is done now. It worked last time I booted anyway. Could break next time I boot tho, I guess. :/ Dale :-) :-) ^ permalink raw reply [flat|nested] 23+ messages in thread
* Re: [gentoo-user] Grub fails. I missed something. 2025-03-17 3:50 ` [gentoo-user] " Dale 2025-03-17 8:10 ` Michael @ 2025-03-18 22:35 ` Frank Steinmetzger 1 sibling, 0 replies; 23+ messages in thread From: Frank Steinmetzger @ 2025-03-18 22:35 UTC (permalink / raw To: gentoo-user [-- Attachment #1: Type: text/plain, Size: 729 bytes --] Am Sun, Mar 16, 2025 at 10:50:05PM -0500 schrieb Dale: >Dale wrote: >> Howdy, >> >> > > >New problem. As I mentioned in another reply, I booted the NAS box to >update my backups. The thing won't let me login. I type in root, it >sits there for 20 or 30 seconds then returns to a login prompt. I also >tried the user dale but no joy there either. I'm back to spinning rust >to update my backups. Did you copy over /root? I’m not in the mood to test this hypothesis by moving-away my live /root. -- Grüße | Greetings | Qapla’ Please do not share anything from, with or about me on any social network. Many who were ahead of their times had to wait for it in uncomfortable accomodations. [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 833 bytes --] ^ permalink raw reply [flat|nested] 23+ messages in thread
end of thread, other threads:[~2025-03-24 0:39 UTC | newest] Thread overview: 23+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2025-03-15 7:29 [gentoo-user] Grub fails. I missed something Dale 2025-03-15 9:18 ` Michael 2025-03-15 20:42 ` Dale 2025-03-15 21:43 ` eric 2025-03-16 2:15 ` William Kenworthy 2025-03-16 5:04 ` Dale 2025-03-16 5:34 ` William Kenworthy 2025-03-16 7:30 ` Dale 2025-03-16 9:58 ` Dale 2025-03-16 11:40 ` Michael 2025-03-16 14:05 ` Michael 2025-03-16 19:14 ` Dale 2025-03-17 1:01 ` [gentoo-user] " Grant Edwards 2025-03-17 2:34 ` Dale 2025-03-17 8:21 ` Michael 2025-03-17 13:28 ` Grant Edwards 2025-03-17 3:50 ` [gentoo-user] " Dale 2025-03-17 8:10 ` Michael 2025-03-20 2:25 ` Dale 2025-03-23 5:41 ` Dale 2025-03-23 22:28 ` Frank Steinmetzger 2025-03-24 0:38 ` Dale 2025-03-18 22:35 ` Frank Steinmetzger
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox