Vijay, Look into if_nameindex but before using this you must see issues related to changes into kernel 2.4.18+ and glibc. Use glibc3+ then you will not have any issue. -- Sumit - : send the line "unsubscribe linux-net" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html