VNFM CLI

F5 provides two sets of CLI commands:

Common options

These options are supported by all VNFM CLI Commands. They can be passed as either an argument to the command itself, eg. vnfm blueprints list -v, or as an argument to vnfm itself, eg. vnfm -v blueprints list, which has the same effect as the previous call.

  • -q, --quiet - Show only critical logs
  • --format [plain|json] - Choose the output format
  • -v, --verbose - Show verbose output. You can supply this up to three times (i.e. -vvv)
  • --json - Force JSON output

Verbose Output

The -v/--verbose flag is available for all commands. It sets the command verbosity level. There are five verbosity levels:

  • Running a command with the --quiet flag limits the log output to critical logs only.
  • Running a command without the verbose flag. (The default).
  • Running a command with -v prints tracebacks where relevant, in addition to the normal output.
  • Running a command with -vv in addition to the tracebacks, displays the DEBUG log statements of local/remote execution events.
  • Running a command with -vvv in addition to the tracebacks and debug log statements, sets all loggers declared in the config file to debug mode.
  • --debug is equivalent to -vvv

Server maintenance

cluster

The vnfm cluster command is used to manage VNFM Manager cluster. Optional flags These commands support the common CLI flags. Commands Status Usage vnfm cluster status [OPTIONS] Display the current status of the VNFM Manager cluster Example $ vnfm cluster status Retrieving VNFM cluster status… [ip=10.239.1.160] Current cluster status is OK: Cluster status services:

+--------------------------------+----------+ | service | status | +--------------------------------+----------+ | manager | OK | | db | OK | | broker | OK | +--------------------------------+----------+ Detailed status For a JSON formatted detailed cluster status use vnfm cluster status --json

config

The vnfm config command is used to manage VNFM Manager’s configuration. Optional flags vnfm config commands support the common CLI flags. Commands List Usage vnfm config list [OPTIONS] List all configurations Example $ vnfm config list Config:

+-----------------------------------+--------------------------------------------------+------------+------------+-------------+ | name | value | scope | updated_at | is_editable | +-----------------------------------+--------------------------------------------------+------------+------------+-------------+ | account_lock_period | -1 | rest | | True | | broker_port | 5671 | agent | | True | | default_page_size | 1000 | rest | | True | | failed_logins_before_account_lock | 4 | rest | | True | | file_server_root | /opt/manager/resources | rest | | False | | file_server_url | https://172.

init

The vnfm init command is used to initialize a working VNFM directory. Before you can use vnfm, you must initialize a working directory for it, in which relevant functional information will be stored. Running vnfm intall or vnfm profiles use initializes an environment automatically. Usage vnfm init [OPTIONS] [BLUEPRINT_PATH] Initialize a VNFM environment. This is required to perform many actions and should be the first action performed after installing VNFM.

ldap

The vnfm ldap command is used to set LDAP authentication to enable you to integrate your LDAP users and groups with VNFM. Optional flags These commands support the common CLI flags. Commands set Usage vnfm LDAP set [OPTIONS] Set VNFM Manager to use the LDAP authenticator. Required flags -s, –ldap-server TEXT - The LDAP address against which to authenticate, for example: ldaps://ldap.domain.com. -u, --ldap-username TEXT- The LDAP admin username to be set on the VNFM Manager.

license

The vnfm license command is used to manage VNFM license on the Manager. Optional flags vnfm license commands support the common CLI flags. Commands Upload Usage vnfm license upload [OPTIONS] <license-path> Upload a VNFM license to a Manager. Example $ vnfm license upload vnfm_license.yaml … Uploading VNFM License vnfm_license.yaml to the Manager… VNFM license successfully uploaded. … list Usage vnfm license list [OPTIONS] List details of the VNFM license.

profiles

The vnfm profiles command is used to manage VNFM profiles. Each profile can have its own credentials for managers and VNFM various environmental settings Optional flags These commands support the common CLI flags. Commands list Usage vnfm profiles list [OPTIONS] List all profiles. Example $ vnfm profiles list ... Listing all profiles... Profiles:

+---------------+--------------+----------+-------------------------------------+----------+-----------+---------------+------------------+----------------+-----------------+ | name | manager_ip | ssh_user | ssh_key_path | ssh_port | rest_port | rest_protocol | manager_username | manager_tenant | bootstrap_state | +---------------+--------------+----------+-------------------------------------+----------+-----------+---------------+------------------+----------------+-----------------+ | *10.

sites

The vnfm sites command is used to manage sites and their location in VNFM Manager. Optional flags vnfm sites commands support the common CLI flags. Commands List Usage vnfm sites list [OPTIONS] List all sites Optional flags

  • --sort-by TEXT - Key for sorting the list.
  • --descending - Sort list in descending order. [default: False] -t,
  • --tenant-name TEXT - The name of the tenant from which to list the sites.

snapshots

The vnfm snapshots command is used to manage data snapshots of VNF manager. You must have admin credentials to create and restore snapshots. You can use the command to create, upload, download, delete and list snapshots and also to restore a Manager using a snapshot archive. For more about working with snapshots, go to: snapshots. Optional flags These commands support the common CLI flags. Commands create Usage vnfm snapshots create [OPTIONS] [SNAPSHOT_ID]

ssh

The vnfm ssh command is used to connect to a VNF manager via SSH. You can use the command to create a new terminal session, run a command, or connect to a shared tmux-based session. Usage vnfm ssh [OPTIONS] Connects to a running manager via SSH. host starts a tmux session (for example, tmux new -s ssh_session_vi120m) after which a command for a client is printed in the tmux session for the host to send to the client.

tenants

The vnfm tenants command is used to create and manage tenants on VNFM Manager. You can run commands on a tenant other than the one that you are logged into by specifying the name of the tenant to which the command applies. For example, vnfm tenants add-user USERNAME -t TENANT_NAME can be used to add a user to a different tenant. Requirements To use the command you must have VNFM sys_admin credentials.

user-groups

The vnfm user-groups command is used to define and manage user groups on VNFM Manager. To use the command you must have VNFM admin credentials. If your VNFM Manager is integrated with LDAP/AD. ensure that the group names that you define exactly match those defined in LDAP. Requirements To use the command you must have VNFM admin credentials. User names and passwords must conform to the following requirements:

users

The vnfm users command is used to manage users and passwords on VNFM Manager. If you choose not to integrate VNFM Manager with LDAP-based user management system, you must add each user individually with a unique username and a password.You can also create user groups and add users to them. The users and user groups can be assigned to one or more tenants, with different roles in each tenant.

Orchestration

agents

Used to manage VNFM agents on existing deployments.

blueprints

Used to manage blueprints on a VNF Manager instance.

deployments

Used to manage running deployments on a VNF manager.

dev

used to run fabric tasks on a VNF manager via SSH.

events

Used to view events of a specific execution.

executions

Used to manage workflow executions on VNF Manager.

groups

Used to view information on the different groups in a deployment.

install

Used to install an application using a VNF manager without having to manually go through the process of uploading a blueprint, creating a deployment and executing a workflow.

logs

Used to manage log files on VNF Manager.

maintenance-mode

Used to restrict REST access to the manager.

node-instances

Used to view information about the different node-instances of a deployment.

nodes

Used to view information on the different nodes of a deployment.

plugins

Used to manage plugins stored on a VNF manager.

secrets

Used to manage VNFM secrets (key-value pairs).

status

Used to display the status of a running VNF Manager.

tokens

Used to receive a REST token from the VNF Manager.

uninstall

Used to uninstall an application using VNF Manager, without having to manually go through the process of executing a workflow, deleting a deployment and deleting a blueprint.

workflows

Used to view information about the different workflows of a deployment.

What’s Next?

Server maintenance commands

Orchestration commands