Invalid signature in boot block:0000. How to fix?

Well, it is obvious I screwed up...again.

First, I was trying to build a second installation of FreeBSD 14.3 on a much larger, 6TB, HDD, on my desktop computer.

I had to tweak the mobo settings to get the bios to recognize the 6TB drive, and in doing so, obviously corrupted the bootblock on my previously-working system, which is installed on a 320 GB drive.

One of the tweaks I tried was to activate "safe boot" or CSM. Undoubtedly, this is what caused the error. I have since turned that back off.

After looking for a solution, I tried the following commands:

gpart bootcode -b /boot/pmbr -p

But that command string is not recognized by gpart.

So, how do I fix the original error message and what other info might folks here need to help me figure out a solution?

BTW, due to some serious problems with Windows 10, I have been forced to have my FreeBSD installation become my daily driver. I like it very much despite there being a rather steep learning curve to all the unfamiliar software.

Ken Gordon
 
I tried was to activate "safe boot" or CSM
Turn off "safe boot". CSM can be on or off, CSM "on" is the traditional BIOS boot, off will probably only allow UEFI boot. Depends a bit on what you used for the disk, GPT + freebsd-boot partition, or an efi partition, or even both.

what other info might folks here need
gpart show of the disk in question might be nice.
 
I will post that asap. And thanks....again.

Oh. And I have turned off both CSM and safeboot, as far as I can tell.

Ken Gordon
 
root0:~ # gpart show ada1
+> 40 625140256 ada1 GPT (298G)
40 532380 1 efi (269M)
532520 1024 2 freebsd-boot (512K)
533544 984 - free - (492K)
534528 4195304 3 freebsd-swap (2.06G)
4728832 610420880 4 freebsd-zfs (296G)
625139712 584 - free - (292K)


Formatting didn't work out as I wished.

Ken Gordon
 
Strange. Seems to come from sbin/fsck_msdosfs/boot.c, but it complains about the lack of executable sector marks 0X55, 0xAA (also know as "magic number"). Do you see something before this message?

You can always copy pmbr with: gpart bootcode -b /boot/pmbr ada1 (there no "-p"). I suppose it will rewrite the executable marks.
 
Well, at this point, I cannot see that I have much choice: I'll give that a shot.

And, no, there were no messages before what I posted.

I also turned CSM back on so I could see all my drives. Since, so far at least, I have been unable to install another instance of FreeBSD on my 6TB drive, maybe I can use it as storage.

Thanks.

Later


Ken Gordon
 
I had to tweak the mobo settings to get the bios to recognize the 6TB drive, and in doing so, obviously corrupted the bootblock on my previously-working system, which is installed on a 320 GB drive.
If you go back to the previous settings, does the system boot off the 320GB drive correctly?
Yes, I understand you will lose the 6TB drive.

A theory is mucking with the settings to get the 6TB drive visible broke any kind of mapping on the 320GB drive.
Basically sector 0 is at the same place but maybe sector 1 maps differently with the changed settings.
 
Where I screwed up was turning on safe boot in the bios.

And no, it will not boot from either drive: both return the same error message when attempting to boot from either one.

FYI, the system also has a Windows 10 opsys installed on yet another HDD. That hasnt successfully booted for the past month, but as long as I can access its files from within FreeBSD, I really no longer care.

I really dont like Windows: for one thing, it was taking 15 minutes to complete a boot from cold, among other things.

Ken Gordon
 
After doing gpart bootcode -b /boot/boot-pmbr ada1

It returns bootcode written to ada1

Attempting to boot from my Freebsd install now returns a different set of error messages:
Invalid signature in boot block:0000
msdosfs /dev/gpt/efiboot ( /boot/efi)


It also says Run fsck_msdos manually

But, if course, there is no such command.

When I then run fsck -yf ada0 I get further errors, which, at this point, I would like to ignore.

Ken Gordon
 
When I then run fsck -yf ada0 I get further errors, which, at this point, I would like to ignore.
Well you shouldn't. You are trying to fsck a whole disk with that command. You need to work on partitions:
fsck -y /dev/ada0s1 or fsck -y/dev/ada0p1

Something is not right because you don't flash boot code and use EFI. One or the other.
 
Well, I am now back into my working FreeBSD desktop.

In order to get it operating, I powered down the box by shutdown -p now, then physically disconnected all drives except the 320 GB HDD which had my working FreeBSD installation on it

Then I had to use gpart show in order to find the correct drive name, which had changed from the way it was titled previously, and then edit fstab in order to 1) change a pointer in that file to access the correct HDD, and 2) to edit out the two external HDDs which I was no longer using.

Upon doing that, the system booted with no errors from the 320 GB HDD.

One thing that bothers me is that the File Type shown in fstab for the efi boot partition is msdos, which I feel is an error.

Now, I will add back into the system, one at a time, the HDDs I need to have attached to the system and which have many of my files on them.

So, I still have tons of work to do to get this thing back in complete operation.

Ken Gordon
 
One reason I asked that question is that the system kept complaining about an msdos partition somewhere, and I have not yet tracked that down.

I modified the UEFI bios to permit hot-plugging of some of the storage media. I will add back into the system my other HDDs until one of them causes problems, then will attack that issue.

Ken Gordon

(BTW, I turned 84 years old on April 23 of this year. I am kinda tired now. :-) )
 
Back
Top