Score:0

How can I tell my Ubuntu 20.04 is running dhcp client?

fr flag

I have a system that runs Ubuntu 20.04. However, it doesn't seem to be set as a DHCP client.

song@docker:~$ ps -ef | grep dhcp
song        7861    3124  0 08:50 pts/0    00:00:00 grep --color=auto dhcp
song@docker:~$ 

However, this machine got an IP address when it boots up. Because every time it restarts, it gets a different IP.

song@docker:~$ cat /etc/netplan/00-installer-config.yaml 
# This is the network config written by 'subiquity'
network:
  ethernets:
    ens160:
      dhcp4: true
  version: 2
song@docker:~$ ifconfig ens160
ens160: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.100.95  netmask 255.255.255.0  broadcast 192.168.100.255
        inet6 fe80::250:56ff:fe95:d581  prefixlen 64  scopeid 0x20<link>
        ether 00:50:56:95:d5:81  txqueuelen 1000  (Ethernet)
        RX packets 263821  bytes 73294629 (73.2 MB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 229178  bytes 79367259 (79.3 MB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

Thank you in advance.

Score:0
cn flag

Not every DHCP client runs a command name containing "dhcp". Ubuntu is probably using systemd-networkd which has its own DHCP implementation.

deokyong song avatar
fr flag
Thank you @John. I really appreciate your answer.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.