Rate This Document
Findability
Accuracy
Completeness
Readability

Determining the GPU Topology

This section describes how to obtain information about the GPU rendering nodes and their associated NUMA nodes on the server.

Configuration Scheme 1

  1. Query GPU rendering nodes.
    1
    ll /dev/dri/by-path/ | grep renderD
    

    Example command output:

    1
    2
    lrwxrwxrwx 1 root root 13 Oct 25 10:58 pci-0000:03:00.0-render -> ../renderD128
    lrwxrwxrwx 1 root root 13 Oct 25 10:58 pci-0000:83:00.0-render -> ../renderD129
    

    This indicates that two AMD GPUs are inserted into the server, and the rendering nodes are renderD128 and renderD129.

  2. Query the NUMA node to which a GPU rendering node belongs.
    1
    cat /sys/bus/pci/devices/0000\:XX\:00.0/numa_node 
    

    Replace XX in the command with the PCI address of a node queried in step 1. Take renderD128 as an example. The query command is as follows:

    1
    cat /sys/bus/pci/devices/0000\:03\:00.0/numa_node
    

    Command output:

    1
    0
    

    This indicates that renderD128 belongs to NUMA node 0.

Configuration Scheme 2/3

Check the NUMA node to which the GPU nodes belong.
1
lspci -vvv -d :0200 | grep NUMA
Each DaoCloud DC1000 has four GPU nodes. The following uses the 4 x DaoCloud DC1000 configuration as an example. Each line in the command output corresponds to a GPU node (renderD node, numbered from 128) in sequence. Example command output:
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
NUMA node: 0
NUMA node: 0
NUMA node: 0
NUMA node: 0
NUMA node: 0
NUMA node: 0
NUMA node: 0
NUMA node: 0
NUMA node: 2
NUMA node: 2
NUMA node: 2
NUMA node: 2
NUMA node: 2
NUMA node: 2
NUMA node: 2
NUMA node: 2

The command output shows that, in the /dev/dri/ directory, rendering nodes renderD128 to renderD135 belong to NUMA0 and renderD136 to renderD143 belong to NUMA2.