the boot directory exist on both the ESP(sda1) and root(sda5) partition.
when i use this sample command to copy vmlinuz and initrd files:
sudo cp -a initrd.img-4.15.0-43-generic /boot
i was able to get the system to boot and thought i had copied the file to the ESP. i also checked the root partition after using the command and confirmed it does not exist.
however, after a few days, i discovered the files had appeared in the boot directory of the root partition.
before that, i had also manually moved the files to the boot directory of the root partition using a file manager(dolphin) but was unable to get the system to boot.
so i would like to ask what is the command to copy files to the ESP partition, and the command to copy the same file to the root partition? basically, i would like to know how the linux system differentiate between the ESP and root partition for the same sets of command, i.e, cp, mkdir..etc