Hi,
"hammer host list" show null when i to try to sort IP or MAC
select host list without sort:
hammer host list --hostgroup-title general_server/DN
--------|---------------|------------------|------------|----------|------------------
ID | NAME | OPERATING SYSTEM | HOST GROUP | IP | MAC |
---|---|---|---|---|---|
150666 | dn001.abc.com | CentOS 7.2 | DataNodes | 1.2.3.10 |
a1:b2:c3:d4:e5:57
150678 | dn002.abc.com | CentOS 7.2 | DataNodes | 1.2.3.11 |
a1:b2:c3:d4:e5:19
150688 | dn003.abc.com | CentOS 7.2 | DataNodes | 1.2.3.12 |
a1:b2:c3:d4:e5:1f
193119 | dn004.abc.com | CentOS 7.2 | DataNodes | 1.2.3.13 |
a1:b2:c3:d4:e5:f1
330874 | dn005.abc.com | CentOS 7.2 | DataNodes | 1.2.3.14 |
a1:b2:c3:d4:e5:b1
379538 | dn006.abc.com | CentOS 7.2 | DataNodes | 1.2.3.15 |
a1:b2:c3:d4:e5:df
193122 | dn007.abc.com | CentOS 7.2 | DataNodes | 1.2.3.16 |
a1:b2:c3:d4:e5:59
193121 | dn008.abc.com | CentOS 7.2 | DataNodes | 1.2.3.17 |
a1:b2:c3:d4:e5:97
193576 | dn009.abc.com | CentOS 7.2 | DataNodes | 1.2.3.18 |
a1:b2:c3:d4:e5:57
193565 | dn010.abc.com | CentOS 7.2 | DataNodes | 1.2.3.19 |
a1:b2:c3:d4:e5:19
193566 | dn011.abc.com | CentOS 7.2 | DataNodes | 1.2.3.20 |
a1:b2:c3:d4:e5:9f
193567 | dn012.abc.com | CentOS 7.2 | DataNodes | 1.2.3.21 |
a1:b2:c3:d4:e5:d9
193564 | dn013.abc.com | CentOS 7.2 | DataNodes | 1.2.3.22 |
a1:b2:c3:d4:e5:5f
232138 | dn014.abc.com | CentOS 7.2 | DataNodes | 1.2.3.23 |
a1:b2:c3:d4:e5:59
193200 | dn015.abc.com | CentOS 7.2 | DataNodes | 1.2.3.24 |
a1:b2:c3:d4:e5:17
193552 | dn016.abc.com | CentOS 7.2 | DataNodes | 1.2.3.25 |
a1:b2:c3:d4:e5:57
193560 | dn017.abc.com | CentOS 7.2 | DataNodes | 1.2.3.26 |
a1:b2:c3:d4:e5:d9
2289696 | dn018.abc.com | CentOS 7.2 | DataNodes | 1.2.3.27 |
a1:b2:c3:d4:e5:f1
2284342 | dn019.abc.com | CentOS 7.2 | DataNodes | 1.2.3.28 |
a1:b2:c3:d4:e5:99
2284124 | dn020.abc.com | CentOS 7.2 | DataNodes | 1.2.3.29 |
a1:b2:c3:d4:e5:31
2283754 | dn021.abc.com | CentOS 7.2 | DataNodes | 1.2.3.30 |
a1:b2:c3:d4:e5:1f
2277706 | dn022.abc.com | CentOS 7.2 | DataNodes | 1.2.3.31 |
a1:b2:c3:d4:e5:5f
2274149 | dn023.abc.com | CentOS 7.2 | DataNodes | 1.2.3.32 |
a1:b2:c3:d4:e5:b1
2274043 | dn024.abc.com | CentOS 7.2 | DataNodes | 1.2.3.33 |
a1:b2:c3:d4:e5:97
193563 | dn025.abc.com | CentOS 7.2 | DataNodes | 1.2.3.34 |
a1:b2:c3:d4:e5:99
193571 | dn026.abc.com | CentOS 7.2 | DataNodes | 1.2.3.35 |
a1:b2:c3:d4:e5:d7
--------|---------------|------------------|------------|----------|------------------
select host list with sort ip:
hammer host list --hostgroup-title general_server/DN --order ip
--------|---------------|------------------|------------|----------|------------------
ID | NAME | OPERATING SYSTEM | HOST GROUP | IP | MAC |
---|---|---|---|---|---|
150666 | dn001.abc.com | CentOS 7.2 | DataNodes | ||
150678 | dn002.abc.com | CentOS 7.2 | DataNodes | ||
150688 | dn003.abc.com | CentOS 7.2 | DataNodes | ||
193119 | dn004.abc.com | CentOS 7.2 | DataNodes | ||
330874 | dn005.abc.com | CentOS 7.2 | DataNodes | ||
379538 | dn006.abc.com | CentOS 7.2 | DataNodes | ||
193122 | dn007.abc.com | CentOS 7.2 | DataNodes | ||
193121 | dn008.abc.com | CentOS 7.2 | DataNodes | ||
193576 | dn009.abc.com | CentOS 7.2 | DataNodes | ||
193565 | dn010.abc.com | CentOS 7.2 | DataNodes | ||
193566 | dn011.abc.com | CentOS 7.2 | DataNodes | ||
193567 | dn012.abc.com | CentOS 7.2 | DataNodes | ||
193564 | dn013.abc.com | CentOS 7.2 | DataNodes | ||
232138 | dn014.abc.com | CentOS 7.2 | DataNodes | ||
193200 | dn015.abc.com | CentOS 7.2 | DataNodes | ||
193552 | dn016.abc.com | CentOS 7.2 | DataNodes | ||
193560 | dn017.abc.com | CentOS 7.2 | DataNodes | ||
2289696 | dn018.abc.com | CentOS 7.2 | DataNodes | ||
2284342 | dn019.abc.com | CentOS 7.2 | DataNodes | ||
2284124 | dn020.abc.com | CentOS 7.2 | DataNodes | ||
2283754 | dn021.abc.com | CentOS 7.2 | DataNodes | ||
2277706 | dn022.abc.com | CentOS 7.2 | DataNodes | ||
2274149 | dn023.abc.com | CentOS 7.2 | DataNodes | ||
2274043 | dn024.abc.com | CentOS 7.2 | DataNodes | ||
193563 | dn025.abc.com | CentOS 7.2 | DataNodes | ||
193571 | dn026.abc.com | CentOS 7.2 | DataNodes | ||
-------- | --------------- | ------------------ | ------------ | ---------- | ------------------ |
select host list with sort mac:
hammer host list --hostgroup-title general_server/DN --order mac
--------|---------------|------------------|------------|----------|------------------
ID | NAME | OPERATING SYSTEM | HOST GROUP | IP | MAC |
---|---|---|---|---|---|
150666 | dn001.abc.com | CentOS 7.2 | DataNodes | ||
150678 | dn002.abc.com | CentOS 7.2 | DataNodes | ||
150688 | dn003.abc.com | CentOS 7.2 | DataNodes | ||
193119 | dn004.abc.com | CentOS 7.2 | DataNodes | ||
330874 | dn005.abc.com | CentOS 7.2 | DataNodes | ||
379538 | dn006.abc.com | CentOS 7.2 | DataNodes | ||
193122 | dn007.abc.com | CentOS 7.2 | DataNodes | ||
193121 | dn008.abc.com | CentOS 7.2 | DataNodes | ||
193576 | dn009.abc.com | CentOS 7.2 | DataNodes | ||
193565 | dn010.abc.com | CentOS 7.2 | DataNodes | ||
193566 | dn011.abc.com | CentOS 7.2 | DataNodes | ||
193567 | dn012.abc.com | CentOS 7.2 | DataNodes | ||
193564 | dn013.abc.com | CentOS 7.2 | DataNodes | ||
232138 | dn014.abc.com | CentOS 7.2 | DataNodes | ||
193200 | dn015.abc.com | CentOS 7.2 | DataNodes | ||
193552 | dn016.abc.com | CentOS 7.2 | DataNodes | ||
193560 | dn017.abc.com | CentOS 7.2 | DataNodes | ||
2289696 | dn018.abc.com | CentOS 7.2 | DataNodes | ||
2284342 | dn019.abc.com | CentOS 7.2 | DataNodes | ||
2284124 | dn020.abc.com | CentOS 7.2 | DataNodes | ||
2283754 | dn021.abc.com | CentOS 7.2 | DataNodes | ||
2277706 | dn022.abc.com | CentOS 7.2 | DataNodes | ||
2274149 | dn023.abc.com | CentOS 7.2 | DataNodes | ||
2274043 | dn024.abc.com | CentOS 7.2 | DataNodes | ||
193563 | dn025.abc.com | CentOS 7.2 | DataNodes | ||
193571 | dn026.abc.com | CentOS 7.2 | DataNodes | ||
-------- | --------------- | ------------------ | ------------ | ---------- | ------------------ |
$ hammer --version
hammer (0.7.0)
- hammer_cli_foreman (0.7.0)
- hammer_cli_foreman_discovery (0.0.3)
Foreman version:
Version 1.12.2