在 Oracle® Solaris 中安装和配置 OpenStack (Kilo)

退出打印视图

更新时间: 2016 年 6 月
 
 

获取命令行帮助

在 OpenStack 中,命令对应于 OpenStack 组件。例如,nova 命令适用于计算操作,cinder 适用于存储,neutron 适用于网络。

要获取有关使用这些命令的帮助,如正确的语法、支持的子命令、可能的选项等,请使用 command-component help 命令,例如 nova helpneutron help。可以使用 grep 命令过滤可与 command-component 命令一起使用的子命令列表。例如,要列出与路由器相关的 neutron 子命令,可键入以下命令:

# neutron help | grep router
  l3-agent-list-hosting-router   List L3 agents hosting a router.
  l3-agent-router-add            Add a router to a L3 agent.
  l3-agent-router-remove         Remove a router from a L3 agent.
  net-gateway-connect            Add an internal network interface to a router.
  router-create                  Create a router for a given tenant.
  router-delete                  Delete a given router.
  router-gateway-clear           Remove an external network gateway from a router.
  router-gateway-set             Set the external network gateway for a router.
  router-interface-add           Add an internal network interface to a router.
  router-interface-delete        Remove an internal network interface from a router.
  router-list                    List routers that belong to a given tenant.
  router-list-on-l3-agent        List the routers on a L3 agent.
  router-port-list               List ports that belong to a given tenant, with specified router.
  router-show                    Show information of a given router.
  router-update                  Update router's information.

然后,要获取有关子命令(例如,用于标识云中路由器的 router-list)的特定详细信息,可键入以下命令:

# neutron help router-list

由于 OpenStackClient (OSC) 的实现所致,基于组件的某些命令已过时。相反,将 openstack 作为主命令与相应的子命令一起使用。有关 OSC 的简要说明,请参见OpenStackClient 的实现

要获取有关 openstack 命令及其子命令的信息,请使用以下命令之一:

  • openstack help subcommand

  • openstack --help

键入不带任何子命令的 openstack 将切换到交互模式,可以在其中键入 help [subcommand] 以了解信息。要退出交互模式,请键入 quit

有关 OSC 的更多信息,请参见 http://docs.openstack.org/developer/python-openstackclient/index.html

有关以前的命令及其在 OSC 中等效项的列表,请参见OpenStackClient 命令