{"id":187,"date":"2017-04-28T10:05:24","date_gmt":"2017-04-28T10:05:24","guid":{"rendered":"http:\/\/info.ffteixeira.net\/2017\/04\/28\/linux-show-list-of-network-cards\/"},"modified":"2017-04-28T10:05:24","modified_gmt":"2017-04-28T10:05:24","slug":"linux-show-list-of-network-cards","status":"publish","type":"post","link":"https:\/\/blog.ffteixeira.net\/?p=187","title":{"rendered":"Linux Show List Of Network Cards"},"content":{"rendered":"<div>&nbsp;<\/div>\n<div>You can use any one of the following command to list network cards installed under Linux operating systems.<\/div>\n<div>Please note that the ifconfig and ip commands will also display interfaces information about vpn, loopback, and other configured interfaces.<\/div>\n<div>&nbsp;<\/div>\n<ol>\n<li><strong>lspci <\/strong>: List all PCI devices.<\/li>\n<li><strong>lshw <\/strong>: List all hardware.<\/li>\n<li><strong>dmidecode <\/strong>: List all hardware data from BIOS.<\/li>\n<li><strong>ifconfig <\/strong>: Outdated network config utility.<\/li>\n<li><strong>ip <\/strong>: Recommended new network config utility.<\/li>\n<\/ol>\n<div>&nbsp;<\/div>\n<div><strong>lspci&nbsp;<\/strong><\/div>\n<div>Type the following command:<\/div>\n<div><em># lspci | egrep -i &#8211;color &#039;network|ethernet&#039;<\/em><\/div>\n<div>&nbsp;<\/div>\n<div><strong>lshw&nbsp;<\/strong><\/div>\n<div>The lshw command can extract detailed information on the hardware configuration of the machine including network cards. Type the following command:<\/div>\n<div><em># lshw -class network<\/em><\/div>\n<div>&nbsp;<\/div>\n<div><strong><span style=\"font-size: 13.008px\">dmidecode&nbsp;<\/span><\/strong><\/div>\n<div><span style=\"font-size: 13.008px\">Getting HW information about BIOS.<\/span><\/div>\n<div><em># dmidecode -t bios<\/em><\/div>\n<div>\n<div>Getting HW information about system.<\/div>\n<div><em># dmidecode -t system<\/em><\/div>\n<div><span style=\"font-size: 13.008px\">Getting HW information about baseboard.<\/span><\/div>\n<div><em># dmidecode -t baseboard<\/em><\/div>\n<div><span style=\"font-size: 13.008px\">Getting HW information about chassis.<\/span><\/div>\n<div><em># dmidecode -t chassis<\/em><\/div>\n<div>&nbsp;<\/div>\n<div>OR<\/div>\n<div>&nbsp;<\/div>\n<div><em># dmidecode -t cashe<\/em><\/div>\n<div><em># dmidecode -t processor<\/em><\/div>\n<div><em># dmidecode -t connector<\/em><\/div>\n<div><em># dmidecode -t slot<\/em><\/div>\n<\/div>\n<div>&nbsp;<\/div>\n<div><strong>ifconfig and ip command<\/strong><\/div>\n<div><span style=\"font-size: 13.008px\">To see all configured network devices, enter:<\/span><\/div>\n<div><em># ifconfig -a<\/em><\/div>\n<div>&nbsp;<\/div>\n<div>OR<\/div>\n<div><em># ip link show<\/em><\/div>\n<div>&nbsp;<\/div>\n<div>OR<\/div>\n<div><em># ip a<\/em><\/div>\n<div>&nbsp;<\/div>\n<div><strong style=\"font-size: 13.008px\">\/proc\/net\/dev<\/strong><\/div>\n<div><span style=\"font-size: 13.008px\">The dev pseudo-file contains network device status information. This gives the number of received and sent packets, the number of errors and collisions and other basic statistics.<\/span><\/div>\n<div><em>$ cat \/proc\/net\/dev<\/em><\/div>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp; You can use any one of the following command to list network cards installed under Linux operating systems. Please note that the ifconfig and ip commands will also display interfaces information about vpn, loopback, and other configured interfaces. &nbsp; &hellip; <a href=\"https:\/\/blog.ffteixeira.net\/?p=187\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-187","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=\/wp\/v2\/posts\/187","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=187"}],"version-history":[{"count":0,"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=\/wp\/v2\/posts\/187\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=187"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=187"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.ffteixeira.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=187"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}