我使用的是XenServer,我正在连接池,获取所有虚拟机的列表。 现在我需要登录到VM。 并在所有VM上执行一个exe文件。 任何人有任何想法?java,xenserver,有没有人知道如何在虚拟机上运行命令?
谢谢!
connection = new Connection(url);
Session.loginWithPassword(connection, userName, Password, APIVersion.latest().toString());
Map<VM, VM.Record> vms = VM.getAllRecords(connection);
for (VM.Record record : vms.values()){
if (!record.isATemplate){
// now i need somehow to connect with the VM username and password
// now i need to run an exe file.
}
}