예제 #1
0
def _print_cpu_show(cpu):
    fields = ['cpu', 'numa_node', 'core', 'thread',
              'cpu_model', 'cpu_family',
              'capabilities',
              'uuid', 'host_uuid', 'node_uuid',
              'created_at', 'updated_at']
    labels = ['logical_core', 'processor (numa_node)', 'physical_core',
              'thread', 'processor_model', 'processor_family',
              'capabilities',
              'uuid', 'host_uuid', 'node_uuid',
              'created_at', 'updated_at']
    data = [(f, getattr(cpu, f, '')) for f in fields]
    utils.print_tuple_list(data, labels)
예제 #2
0
def _print_lldp_agent_show(agent):
    fields = [
        'uuid', 'host_uuid', 'created_at', 'updated_at', 'uuid', 'port_name',
        'chassis_id', 'port_identifier', 'ttl', 'system_description',
        'system_name', 'system_capabilities', 'management_address',
        'port_description', 'dot1_lag', 'dot1_vlan_names', 'dot3_mac_status',
        'dot3_max_frame'
    ]
    labels = [
        'uuid', 'host_uuid', 'created_at', 'updated_at', 'uuid', 'local_port',
        'chassis_id', 'port_identifier', 'ttl', 'system_description',
        'system_name', 'system_capabilities', 'management_address',
        'port_description', 'dot1_lag', 'dot1_vlan_names', 'dot3_mac_status',
        'dot3_max_frame'
    ]
    data = [(f, getattr(agent, f, '')) for f in fields]
    utils.print_tuple_list(data, labels)
예제 #3
0
파일: port_shell.py 프로젝트: xe1gyq/metal
def _print_port_show(port):
    fields = ['name', 'namedisplay',
              'type', 'pciaddr', 'dev_id', 'numa_node',
              'sriov_totalvfs', 'sriov_numvfs',
              'sriov_vfs_pci_address', 'driver',
              'pclass', 'pvendor', 'pdevice',
              'capabilities',
              'uuid', 'host_uuid', 'interface_uuid',
              'dpdksupport',
              'created_at', 'updated_at']
    labels = ['name', 'namedisplay',
              'type', 'pciaddr', 'dev_id', 'processor',
              'sriov_totalvfs', 'sriov_numvfs',
              'sriov_vfs_pci_address', 'driver',
              'pclass', 'pvendor', 'pdevice',
              'capabilities',
              'uuid', 'host_uuid', 'interface_uuid',
              'accelerated',
              'created_at', 'updated_at']
    data = [(f, getattr(port, f, '')) for f in fields]
    utils.print_tuple_list(data, labels)
예제 #4
0
파일: node_shell.py 프로젝트: xe1gyq/metal
def _print_node_show(node):
    fields = ['numa_node',
              'uuid', 'host_uuid',
              'created_at']
    data = [(f, getattr(node, f, '')) for f in fields]
    utils.print_tuple_list(data)