A Network Interface Card is a computer component which connects to a physical network in order to send and receive data.
Questions tagged [nic]
321 questions
102
votes
15 answers
How can I get the IP address from a NIC (network interface controller) in Python?
When an error occurs in a Python script on Unix, an email is sent.
I have been asked to add {Testing Environment} to the subject line of the email if the IP address is 192.168.100.37 which is the testing server. This way we can have one version of a…

Memor-X
- 2,870
- 6
- 33
- 57
21
votes
3 answers
docker-compose: specify which interface will connect to each network (when having multiple networks)
Inside the docker-compose.yaml I define 4 different networks:
networks:
vpp-nw:
vpp-client:
vpp-server:
vpp-db:
which use the following network addresses respectively:
172.20.0.x
172.21.0.x
172.22.0.x
172.23.0.x
One of the containers I…

tgogos
- 23,218
- 20
- 96
- 128
21
votes
1 answer
descriptor concept in NIC
I am trying to understand the concept of Rx and Tx descriptors used in Network driver code.
Are Descriptors in software(RAM) or hardware (NIC card).
How do they get filled.
EDIT: So in a Realtek card driver code. I have a following struct…

Haswell
- 1,573
- 1
- 18
- 45
20
votes
1 answer
Docker - how to set iface name when creating a new network
After creating a new network with:
docker network create test-net
and running ifconfig on the host, a new interface name is being listed:
br-f2b630e4e141 Link encap:Ethernet HWaddr 02:42:48:fe:cb:86
inet addr:172.18.0.1 Bcast:0.0.0.0 …

tgogos
- 23,218
- 20
- 96
- 128
18
votes
7 answers
Programmatically disable/enable network interface
I'm trying to come up with a solution to programmatically enable/disable the network card - I've done a ton of research and nothing seems to be a workable solution in both XP and Vista environments. What I'm talking about is if you went into the…

Mark
- 582
- 3
- 5
- 20
18
votes
1 answer
What does the meaning of "[fixed]" string in output of ethtool command
I run ethtool to query the offload features of a NIC using "ethtool -k" command, and the output is something as follows:
ethtool -k eth0
scatter-gather: on
tx-scatter-gather: on
tx-scatter-gather-fraglist: off **[fixed]**
I am wondering what the…

leivli
- 195
- 1
- 1
- 6
15
votes
3 answers
Differentiate VMware network adapter from physical network adapters -or- Detect Virtual Network Adaptor
I have to differentiate between the real addresses and the VM addresses using any Windows API.
I'm using GetAdaptersAddresses API to populate a list of IP addresses for the local machine. I need to extract only the "real" addresses apart from the…

Venkat
- 227
- 6
- 13
13
votes
2 answers
PyVmomi add NIC with unconnected dvs ('config.distributedVirtualSwitch' is Unset)
I am using the code below in order to add a NIC configured with DistributedVirtualSwitch to an existing VM (via pyVmomi):
def __AddNIC(si, vmconf_dict, network_name):
vm = __get_vm(si, vmconf_dict)
print " Network label : " + network_name
…

Vano
- 1,416
- 1
- 13
- 26
13
votes
6 answers
Programmatically check whether my machine has internet access or not
How can I programmatically check whether my machine has internet access or not using C/C++, is it just a matter of pinging an IP? How does NIC do it ? I mean something like:
I am using Windows 7.

Aan
- 12,247
- 36
- 89
- 150
12
votes
3 answers
What is the relationship of DMA ring buffer and TX/RX ring for a network card?
I know that for a network card, OS must allocate tx/rx rings for it so that when OS wants to receive/transmit packets, the network card will know where the packets are and which packets are to be transmit.
And when I read about DMA, I see something…

4va1anch3
- 427
- 1
- 4
- 13
10
votes
5 answers
Failed to start bean 'webServerStartStop'; Unable to start embedded Tomcat server - spring-boot-starter-web
Spring application using Maven including only Spring Web dependency gives "Unable to start embedded Tomcat serve" error.
The same project runs on other computers like expected.
Spring Boot Version: 2.4.3
Package Type: JAR
Java Version: 11
No…

Callanbr
- 650
- 1
- 4
- 20
9
votes
4 answers
JAVA set / choose specific NIC from multiple (UDP)
I am trying to send UDP with datagram in JAVA and my machine have several NIC with different IP's.
How can I set which NIC I want my packet to be sent from ?? (assuming I have more than one on the machine ??)
EDIT I
I am not using Socket, I am using…

user1722362
- 91
- 1
- 1
- 3
7
votes
1 answer
How to view vendor information of my NIC?
How to get the vendor information of my NIC on top of Ubuntu? I wanna get its vendor, type and things like that? Any shell commands available? Thanks in advance.

user1072898
- 475
- 2
- 7
- 9
7
votes
2 answers
ixgbe: setting the number of RX/TX queues
I want to set the number of RX/TX queues used by an Intel 10G NIC. Let me explain why:
I am using an Intel 10G NIC of type X520, on a Dell R720 system. I am using ixgbe version 3.6.7-k. The kernel in Ubuntu 3.2.0-59.
I am running my network…

Ofir Hermesh
- 125
- 1
- 1
- 7
6
votes
1 answer
Getting Linux interface traffic 64bit statistics in userspace
I would like to get the NIC driver 64bit statistics in userspace, in the simplest way possible.
The man page of API function getifaddrs(), suggests a simple example program that does it using 32bit "struct rtnl_link_stats" (possible to see it here…

user9250533
- 83
- 6