You sound confused.
/boot
is a directory. It is possible to put the contents of /boot
on a different partition, but /boot
itself is a normal directory. It doesn't really make sense to say "/boot
is a partition".
It is customary to have a directory named /dev
, which contains "device nodes" such as sda
, sda1
, and so on. These look like files, but if you open (say) /dev/sda
and read bytes from it, you see the raw bytes on the first harddisk. And if you write to it, the bytes are written directly to the harddisk (thereby destroying your disk partition table and other information, so don't actually try this!)
There are other device nodes; for example, if you open the file /dev/zero
and read from it, no matter how many bytes you ask to read, you never reach the end of the file, and the bytes are always zeros. It's as if /dev/zero
is a file that contains infinity bytes of zeros!
Of course, /dev/zero
doesn't really contain infinity bytes. It's actually just a small stub with some magic code numbers in it telling the Linux kernel to talk to a specific device driver. Likewise, /dev/sda
points to a different driver (the one for harddisks), /dev/sr0
points to another (the CD-ROM driver), and so on. (You might find /dev/soundcard
, /dev/tty3
, and so on.)
I think your question is basically "We need /dev
to access disks, but /dev
is stored on disk, so... wuh?!"
Once the partition that contains /dev
is mounted, you can just access /dev
normally. But how do we get to that position in the first place? Well, that's the black magic of the Linux boot sequence. ;-)
The old way was to write a Linux kernel parameter that says something like root=(hd0,3)
to say to mount partition #3 on disk #0 as the root filesystem, and continue from there. (In particular, the kernel loads /bin/init
as process #1.)
The new way is using something called an "initial RAM-disk" ("initrd"). The even newer way is "initramfs", which is subtly different in a way I won't bore you with now. Either way, your bootloader (typically GRUB) loads the Linux kernel and initrd into memory.
Basically initrd contains a little mini-version of your operating system; it contains files and folders and stuff. In particular, it contains the boot scripts that knew where to find the real boot partition, and mount it for you. One of the things the initrd contains is a /dev
folder full of device nodes. Eventually, when the boot scripts do their thing, you find the real boot device, and mount it over the top of the initrd contents. And from there, you can access your real files as normal.