epretorious

interface-rename subsystem (XenServer 6.5.0)

Oct 27th, 2015
231
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.93 KB | None | 0 0
  1. [root@xs1-pdx0 ~]# interface-rename -l
  2. Name MAC PCI ethN Phys SMBios Driver Version Firmware
  3. eth0 00:1b:78:5c:74:34 0000:4b:00.0 eth4 e1000e 3.1.0.2-NAPI 5.11-2
  4. eth1 00:1b:78:5c:74:35 0000:4b:00.1 eth5 e1000e 3.1.0.2-NAPI 5.11-2
  5. eth2 00:26:55:d2:ee:50 0000:48:00.0 eth2 e1000e 3.1.0.2-NAPI 5.11-2
  6. eth3 00:26:55:d2:ee:51 0000:48:00.1 eth3 e1000e 3.1.0.2-NAPI 5.11-2
  7. eth4 00:1f:29:c4:9d:ba 0000:42:00.0 eth0 em1 bnx2 2.2.5f bc 1.9.6
  8. eth5 00:1f:29:c4:9d:c2 0000:44:00.0 eth1 em2 bnx2 2.2.5f bc 1.9.6
  9.  
  10. [root@xs1-pdx0 ~]# lspci -k
  11. ...
  12. 42:00.0 Ethernet controller: Broadcom Corporation NetXtreme II BCM5708 Gigabit Ethernet (rev 12)
  13. Subsystem: Hewlett-Packard Company NC373i Integrated Multifunction Gigabit Server Adapter
  14. Kernel driver in use: bnx2
  15. Kernel modules: bnx2
  16. ...
  17. 44:00.0 Ethernet controller: Broadcom Corporation NetXtreme II BCM5708 Gigabit Ethernet (rev 12)
  18. Subsystem: Hewlett-Packard Company NC373i Integrated Multifunction Gigabit Server Adapter
  19. Kernel driver in use: bnx2
  20. Kernel modules: bnx2
  21. ...
  22. 48:00.0 Ethernet controller: Intel Corporation 82571EB Gigabit Ethernet Controller (rev 06)
  23. Subsystem: Hewlett-Packard Company NC360T PCI Express Dual Port Gigabit Server Adapter
  24. Kernel driver in use: e1000e
  25. Kernel modules: e1000e
  26. 48:00.1 Ethernet controller: Intel Corporation 82571EB Gigabit Ethernet Controller (rev 06)
  27. Subsystem: Hewlett-Packard Company NC360T PCI Express Dual Port Gigabit Server Adapter
  28. Kernel driver in use: e1000e
  29. Kernel modules: e1000e
  30. 4b:00.0 Ethernet controller: Intel Corporation 82571EB Gigabit Ethernet Controller (rev 06)
  31. Subsystem: Hewlett-Packard Company NC360T PCI Express Dual Port Gigabit Server Adapter
  32. Kernel driver in use: e1000e
  33. Kernel modules: e1000e
  34. 4b:00.1 Ethernet controller: Intel Corporation 82571EB Gigabit Ethernet Controller (rev 06)
  35. Subsystem: Hewlett-Packard Company NC360T PCI Express Dual Port Gigabit Server Adapter
  36. Kernel driver in use: e1000e
  37. Kernel modules: e1000e
  38.  
  39.  
  40. [root@xs1-pdx0 ~]# cat /etc/sysconfig/network-scripts/interface-rename-data/dynamic-rules.json
  41. # Automatically adjusted file. Do not edit unless you are certain you know how to
  42. {
  43. "lastboot": [
  44. [
  45. "00:1f:29:c4:9d:ba",
  46. "0000:42:00.0",
  47. "eth4"
  48. ],
  49. [
  50. "00:1f:29:c4:9d:c2",
  51. "0000:44:00.0",
  52. "eth5"
  53. ],
  54. [
  55. "00:26:55:d2:ee:50",
  56. "0000:48:00.0",
  57. "eth2"
  58. ],
  59. [
  60. "00:26:55:d2:ee:51",
  61. "0000:48:00.1",
  62. "eth3"
  63. ],
  64. [
  65. "00:1b:78:5c:74:34",
  66. "0000:4b:00.0",
  67. "eth0"
  68. ],
  69. [
  70. "00:1b:78:5c:74:35",
  71. "0000:4b:00.1",
  72. "eth1"
  73. ]
  74. ],
  75. "old": []
  76. }[root@xs1-pdx0 ~]#cat /etc/sysconfig/network-scripts/interface-rename-data/static-rules.conf
  77. # Static rules. Autogenerated by the installer from the answerfile or previous install
  78. # WARNING - rules in this file override the 'lastboot' assignment of names,
  79. # so editing it may cause unexpected renaming on next boot
  80.  
  81. # Rules are of the form:
  82. # target name: id method = "value"
  83.  
  84. # target name must be in the form eth*
  85. # id methods are:
  86. # mac: value should be the mac address of a device (e.g. DE:AD:C0:DE:00:00)
  87. # pci: value should be the pci bus location of the device (e.g. 0000:01:01.1)
  88. # ppn: value should be the result of the biosdevname physical naming policy of a device (e.g. p1p1)
  89. # label: value should be the SMBios label of a device (for SMBios 2.6 or above)
  90.  
  91. [root@xs1-pdx0 ~]# /etc/sysconfig/network-scripts/interface-rename.py --update eth0 eth5
  92. ERROR [2015-10-27 10:59:41] No valid update rules after processing. Doing nothing
Advertisement
Add Comment
Please, Sign In to add comment