Questions tagged [mbr]

Master Boot Record: the first sector on disk, containing partition info

A Master Boot Record (MBR) is a special type of boot sector at the very beginning of partitioned computer mass storage devices. The MBR holds the information on how the logical partitions, containing file systems, are organized on that medium.

It identifies how and where an operating system is located, so that it can be bootstrapped.

Wikipedia with full partition table info

136 questions
2
votes
2 answers

Basic NASM bootstrap

I've recently been researching Operating Systems, the boot process, and NASM. On my journeys I ran into a piece of useful bootstrapping code which I partially understand and have tested via a virtual floppy disk. My basic question is to what some of…
anon
1
vote
1 answer

Issue while resizing Azure Managed data disks

Below are my configurations: Azure VM is in West Europe Region NOTE : It is a Generation 1 VM Current size: Standard_D2_v2_Promo Actual Requirement: Our requirement is to have a one 4TB disk instead of 2*2 TB disks . Disks: In the above image I…
Learning_Learning
  • 317
  • 1
  • 5
  • 18
1
vote
1 answer

Interpreting the boot sector assembly code

I am going through os-dev by Nick Blundell. There he has taken through the hex data inside a bin file after compiling the boot sector assembly code using NASM. Is there a way to interpret all the 512 bytes manually, just by looking at the code. Say,…
kumarp
  • 135
  • 3
  • 11
1
vote
1 answer

DosBox boot MBR, wrong value in dl for int 13h

I have a custom MBR that I compile with NASM to a binary and I can boot it just fine in qemu and bochs. I am trying to boot this MBR in DosBox using boot mbr.bin. This works fine as long as the MBR is tiny and does not call int 13h to read sectors…
Gerard
  • 107
  • 1
  • 7
1
vote
2 answers

Master Boot Record using GNU Assembly: extra bytes in flat binary output

I am try to compile the simple following MBR: .code16 .globl _start .text _start: end: jmp end ; Don't bother with 0xAA55 yet I run the following commands: > as --32 -o boot.o boot.s > ld -m elf_i386 boot.o --oformat=binary -o mbr -Ttext…
manzerbredes
  • 310
  • 2
  • 13
1
vote
1 answer

Bochs enhanced debugger does not show 16-bit registers in 16-bit mode

I'm using the Bochs enhanced debugger on Windows 10 x64 to debug an MBR in 16-bit mode. It all works perfectly fine, except that the debugger shows me 32-bit registers instead of 16-bit ones. I can still see all the info I need, but it gets a bit…
Gerard
  • 107
  • 1
  • 7
1
vote
0 answers

USB drive not bootable if multi-sector bootloader is written to it's first sector

I have been working with bootloaders and tiny kernels for some time. I found that when using real USB drive, if my bootloader overwrites the partition table and other data of the MBR on target drive, it is not bootable. But if I use a chainloader…
user13387119
1
vote
0 answers

Boot time segment register value change

When the BIOS passes control to the code loaded from the MBR, the first instruction seems to be jmpi go, BOOTSEG where go is another label preceding the next instruction and BOOTSEG is 0x07c0. The reasoning for executing such an instruction seems to…
learnlearnlearn
  • 946
  • 1
  • 8
  • 16
1
vote
1 answer

Are SPATIAL Geometry indices performance dependant on the size and density of geometry shapes?

Spatial Indexes Given a spatial index, is the index utility, that is to say the overall performance of the index, only as good as the overall geometrys. For example, if I were to take a million geometry data types and insert them into a table so…
Layke
  • 51,422
  • 11
  • 85
  • 111
1
vote
1 answer

What is the usage of MBR hex dump and what kind of think can be do using it?

I take copy bytes dump using my Ubuntu os(MBR sector) following command. dc3dd if=/dev/sda of=x cnt=1 ssz=512 hash=sha256 mlog=hashes And I convert it to hexdump using following command. hexdump x > hex_x I receive out put like this . I have…
uma
  • 1,477
  • 3
  • 32
  • 63
1
vote
1 answer

Some Details of The Boot Process of OSes on x86 32-bit machines

I'm trying to write a OS for my own use, I want to show a blank (black) screen with VGA output but I have some problems(questions): Under FAT32, I have MBR bootloader to read the first sector of the virtual disk image generated by bximage from…
Cro
  • 338
  • 4
  • 18
1
vote
1 answer

How is a MBR signature stored on a hard-disk?

I have a dump from a hard-disk which has aa55 at offset 510. But the places where I have read about it says it is 55aa in dump. 000001fe: aa55 So, I'm wondering if the data is stored in big-endian or little-endian on my disk? Thanks
1
vote
0 answers

C++ - How to specify offset of MBR?

I have been able to modify such that the MBR is overwritten with 0 values. However, is it possible to make it such that I only overwrite the last 2 bytes (55h AAh) of the MBR (Boot Signature) to become 00h 00h ? My code is: char dataWrite[3] =…
x3kuro
  • 11
  • 2
1
vote
2 answers

Reading Boot Sector on Windows

I created a little program on python that reads the boot sector at a low level so it will not corrupt the device. I successfully ran this program yesterday in Linux and I got the idea to do the same thing in Windows. But the only problem that came…
Zeiad Badawy
  • 51
  • 1
  • 10
1
vote
2 answers

How to create file with help of P/Invoke to read boot sector and display .MBR?

I've browsed through the CreateFile documentation... still wondering how should I use P/Invoke to call CreateFile and to read the boot sector, to display out the .MBR? Any reference code for this portion? Thank you in advance!
yen
  • 117
  • 1
  • 2
  • 3