ifconfig -a
root@kali:~# ifup eth0
ifup: unknown interface eth0
1 vim /etc/network/interfaces 2 #自行添加网卡 3 auto eth0 4 iface eth0 inet dhcp
root@kali:~# ifup eth0 Internet Systems Consortium DHCP Client 4.3.5 Copyright 2004-2016 Internet Systems Consortium. All rights reserved. For info, please visit https://www.isc.org/software/dhcp/ Listening on LPF/eth0/00:0c:29:93:74:b5 Sending on LPF/eth0/00:0c:29:93:74:b5 Sending on Socket/fallback DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6 DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 11 DHCPREQUEST of 10.104.23.2 on eth0 to 255.255.255.255 port 67 DHCPOFFER of 10.104.23.2 from 10.104.20.1 DHCPACK of 10.104.23.2 from 10.104.20.1 smbd.service is not active, cannot reload. invoke-rc.d: initscript smbd, action "reload" failed. bound to 10.104.23.2 -- renewal in 40607 seconds.