类别 | Nova V2 REST API Action | Nova CLI | Horizon | 解释 |
虚机操作 | POST | boot | Launch Instance |
启动一个新的虚机 |
DELETE | delete | Terminate Instance |
关闭和删除一个虚机
|
|
confirmResize | resize-confirm | N/A |
确认 resize 操作 |
|
revertResize | resize-revert | N/A |
取消 resize 操作 |
|
reboot | reboot [--hard] |
Soft Reboot Instance Hard Reboot Instance |
重启虚机 |
|
changePassword | root-password | libvirt driver 没有实现 | ||
resize | resize | Resize Instance | 迁移虚机或者改变虚机的flavor | |
rebuild | rebuild | Rebuild Instance | 先调用 driver.destroy (destroy domain,detach volume connections,plug VIF), 然后再调用 driver.spawn | |
createImage | image-create | N/A | 快照 | |
os-start | start | Launch Instance | = hard reboot | |
os-stop | stop | Shut Off Instance | call dom.destroy | |
admin action | pause | pause | Pause Instance | call dom.suspend |
unpause | unpause | Resume Instance | call dom.resume | |
suspend | suspend | N/A |
|
|
resume | resume | N/A |
|
|
migrate | migrate | N/A | 迁移 | |
resetNetwork | N/A | libvirt 没有实现 | ||
injectNetworkInfo | N/A | Set up basic filtering (MAC, IP, and ARP spoofing protection),调用 _conn.nwfilterDefineXML(xml) | ||
lock | lock | N/A | 直接在数据库中 instance 上面设置 lock = true | |
unlock | unlock | N/A | 直接在数据库中 instance 上面设置 lock = false | |
createBackup | backup | N/A |
同 createImage,可以指定类型(daily 或者 weekly),和保存的 image 的最大数目,老的 image 会被删除 {"backup_type": "daily", "rotation": "2", "name": "bk"} |
|
os-migrateLive | live-migration | N/A | 热迁移 | |
os-resetState | reset-state | N/A | 传入 state 参数,直接修改数据库中 instance 的状态 | |
bare metal | add_interface | baremetal-interface-add | TBD | |
remove_interface | baremetal-interface-remove | TBD | ||
cloudpipe | update | cloudpipe-configure | TBD | |
console | os-getVNCConsole | get-vnc-console | Console |
|
os-getSPICEConsole | get-spice-console | TBD | ||
os-getRDPConsole | get-rdp-console | TBD | ||
os-getSerialConsole | TBD | |||
os-getConsoleOutput | console-log | View Log | 读取 虚机的 console.log 文件并返回其内容;如果没有这文件的话,则使用 “pty”,将其内容写入到 consolue文件并返回其内容。 | |
delete | restore | restore | Terminate Instance | Restore a previously deleted (but not reclaimed) instance。直接修改数据库。 |
forceDelete | force-delete | N/A |
有 snapshot,则全部删除;然后从 DB 中删除 instance. |
|
evacuate | evacuate | evacuate | 从 DB 中读取 instance 数据,在一个新的主机上 rebuild。 | |
flavor access | addTenantAccess | flavor-access-add | Flavor - Modify Access | 修改 DB 中 flavor 表 |
removeTenantAccess | flavor-access-remove | Flavor - Modify Access | 修改 DB 中 flavor 表 | |
flavor manage | delete | flavor-delete | Flavor - Delete Flavor | 直接 DB 操作 |
create | flavor-create | Flavor - Create Flavor | 直接 DB 操作 | |
floating ip | addFloatingIp | floating-ip-create | Associate Floating IP | 调用 network_api.associate_floating_ip |
removeFloatingIp | floating-ip-delete | Disassociate Floating IP | 调用 network_api.disassociate_floating_ip | |
NIC | addFixedIp | fixed-ip-reserve |
参数 "networkId"。
|
|
removeFixedIp | fixed-ip-unreserve |
参数 "address"。
|
||
network associate | disassociate_host | Associate or disassociate host or project to network。 call network_api.associate | ||
disassociate_project | network-disassociate | call network_api.associate | ||
associate_host | network-associate-host | call network_api.associate | ||
os network | disassociate | call network_api.associate | ||
rescue | rescue | rescue | ||
unrescue | unrescue | |||
security group | addSecurityGroup | add-secgroup | call security_group_rpcapi.refresh_security_group_rules | |
removeSecurityGroup | secgroup-delete | call security_group_rpcapi.refresh_security_group_rules | ||
shelve | shelve | shelve | ||
shelveOffload | shelve-offload | |||
unshelve | unshelve |
0条评论