Linux : How to generate UUID for network interface on RHEL/CentOS

By | March 11, 2014

UUIDs (Universal Unique Identifier) for network interface card can be generated using the following command :

uuidgen <DEVICE>

Example :

uuidgen eth0

Then you can add it to your NIC config file (assuming your interface is eth0) :

/etc/sysconfig/network-scripts/ifcfg-eth0

Add/modify the following :

UUID=<uuid>