Did you consider installing each of your systems with just the hard drive attached that will hold the system. Only drive A inserted to install windows. Only drive B inserted to install ubuntu.