It might be a setting in the UEFI firmware, that the Ubuntu directory is prioritized before the BOOT folder. Does it help to delete the former from the 1st partition?
This is a known problem, and the key issue is exactly that GRUB can use UUIDs of filesystems, but not of partitions. And Mender would need the latter, as filesystem UUIDs are neither stable nor unique in Mender context. This is something that could probably quite easily be implemented in GRUB, but no one has taken on the task yet. There is a task for it in our bug tracker.
There is no out-of-the-box workaround, but it should not be too hard to tweak the grub scripts to look for some key file on the available hard drives, and then assign the right one.