I think this should be a general linux kernel (or kernel module) related question, though I'm facing the issue while preseeding debian for an automated installation.
Every time I boot the installer from a usb disk, the usb disk turns out to be /dev/sda, but the preseed file I'm using assumes the first hard disk (sata in this case) should be /dev/sda. I'm using the same system for a pxe network installation, and I would prefer to keep them consistent. I also fear that if I wrote a preseed config that assumed the first disk was sdb instead, that for some reason it might not be at some point.
I've tried writing udev rules that changes the device name of the usb disk to "INSTALLMEDIA" which seems to work, however it does not cause the SATA disk to start at sda, they still start at sdb.
What determines the order that disks are discovered and named?
What, if anything, can I do to control this?
If I cannot do anything to control it, would it be safe to assume when booting from USB that the USB disk can be more or less guaranteed to be sda and the first SATA disk would always be sdb?