1. root@kali:~# service networking restart
  2. [....] Running /etc/init.d/networking restart is deprecated because it may not r[warnble some interfaces ... (warning).
  3. [....] Reconfiguring network interfaces...Internet Systems Consortium DHCP Client 4.2.2
  4. Copyright 2004-2011 Internet Systems Consortium.
  5. All rights reserved.
  6. For info, please visit https://www.isc.org/software/dhcp/
  7.  
  8. Listening on LPF/eth0/00:0c:29:e2:03:ff
  9. Sending on LPF/eth0/00:0c:29:e2:03:ff
  10. Sending on Socket/fallback
  11. DHCPRELEASE on eth0 to 192.168.1.1 port 67
  12. Reloading /etc/samba/smb.conf: smbd only.
  13. Internet Systems Consortium DHCP Client 4.2.2
  14. Copyright 2004-2011 Internet Systems Consortium.
  15. All rights reserved.
  16. For info, please visit https://www.isc.org/software/dhcp/
  17.  
  18. Listening on LPF/eth0/00:0c:29:e2:03:ff
  19. Sending on LPF/eth0/00:0c:29:e2:03:ff
  20. Sending on Socket/fallback
  21. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 4
  22. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
  23. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 9
  24. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 9
  25. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 14
  26. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 19
  27. No DHCPOFFERS received.
  28. No working leases in persistent database - sleeping.
  29. done.

  结果如上图, 笔者用的是VMWare, 运行的是Kali Linux, 希望用桥接模式通过路由器获取动态IP, 但是无论如何也不能正确获取IP地址.

一点点排查

1. 排查DNS

  1. root@kali:~# cat /etc/resolv.conf
  2. nameserver 192.168.1.1
  3. nameserver 114.114.114.114

192.168.1.1在里面, DNS设置没有问题

2. 排查网卡

  1. root@kali:~# cat /etc/network/interfaces
  2. # This file describes the network interfaces available on your system
  3. # and how to activate them. For more information, see interfaces(5).
  4.  
  5. # The loopback network interface
  6. auto lo
  7. iface lo inet loopback
  8.  
  9. # The primary network interface
  10. #allow-hotplug eth0
  11. auto eth0
  12. iface eth0 inet dhcp

  网卡自动激活, 并配置dhcp获取IP方式

3.排查VMWare 桥接设置

由于笔者装有Virual Box & VMWare Workstation, 所以有多个虚拟网卡, 桥接为自动模式, 心想是不是自动桥接到不能连外网的Virtual Box的虚拟网卡了?

果断选成实际外网网卡, 重启Kali Linux networking服务, 问题解决.

  1. root@kali:~# service networking restart
  2. [....] Running /etc/init.d/networking restart is deprecated because it may not r[warnble some interfaces ... (warning).
  3. [....] Reconfiguring network interfaces...Internet Systems Consortium DHCP Client 4.2.2
  4. Copyright 2004-2011 Internet Systems Consortium.
  5. All rights reserved.
  6. For info, please visit https://www.isc.org/software/dhcp/
  7.  
  8. Listening on LPF/eth0/00:0c:29:e2:03:ff
  9. Sending on LPF/eth0/00:0c:29:e2:03:ff
  10. Sending on Socket/fallback
  11. DHCPRELEASE on eth0 to 192.168.1.1 port 67
  12. send_packet: Network is unreachable
  13. send_packet: please consult README file regarding broadcast address.
  14. Reloading /etc/samba/smb.conf: smbd only.
  15. Internet Systems Consortium DHCP Client 4.2.2
  16. Copyright 2004-2011 Internet Systems Consortium.
  17. All rights reserved.
  18. For info, please visit https://www.isc.org/software/dhcp/
  19.  
  20. Listening on LPF/eth0/00:0c:29:e2:03:ff
  21. Sending on LPF/eth0/00:0c:29:e2:03:ff
  22. Sending on Socket/fallback
  23. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 7
  24. DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 15
  25. DHCPREQUEST on eth0 to 255.255.255.255 port 67
  26. DHCPOFFER from 192.168.1.1
  27. DHCPACK from 192.168.1.1
  28. Reloading /etc/samba/smb.conf: smbd only.
  29. bound to 192.168.1.101 -- renewal in 3353 seconds.
  30. done.

[解决]Kali Linux DHCP自动获取IP失败 坑爹的VMWare桥接的更多相关文章

  1. Kali桥接模式DHCP自动获取IP失败(VMware)

    Kali桥接模式DHCP自动获取IP失败笔者用的是VMware运行Kali Linux,突然发现桥接模式无法上网,只能使用NAT模式.身为有一点点强迫症的人来说,这就很不爽了.于是马上切换为桥接模式, ...

  2. Centos 7开启网卡打开DHCP自动获取IP

    在Windows10上安装了CentOS7的Hyper-V虚拟机. 虽然配置了可访问外网的网卡(Win8.1 Hyper-V 共享本机IP上网),但是默认安装的CentOS是没有开启配置网卡信息的,也 ...

  3. ARM-Linux配置DHCP自动获取IP地址

    备注:内核版本:2.6.30.9busybox版本:1.15.2 PC Linux和开发板Linux的工作用户:root 1. 配置内核:[*] Networking support --->N ...

  4. linux如何自动获取ip地址

    第一步:激活网卡 系统装好后默认的网卡是eth0,用下面的命令将这块网卡激活. # ifconfig eth0 up 第二步:设置网卡进入系统时启动 想要每次开机就可以自动获取IP地址上网,就要设置网 ...

  5. CentOS 7如何设置Linux开机自动获取IP地址

    centos7 minimal版默认安装好后没有获取ip地址,需要手动配置.方法如下: 1.输入“ip addr”并按回车键确定,发现无法获取IP(CentOS 7默认没有ifconfig命令),记录 ...

  6. CentOS7 DHCP自动获取IP地址

    # 设置auto自动获取IP[root@localhost ~]# nmcli c modify eth0 ipv4.method auto //etho0 网卡名称     # 重新启动网卡并重新加 ...

  7. linux设置自动获取IP地址

    右键单击,选择设置 勾选桥接模式

  8. Centos7(Linux)网络配置,自动获取ip地址

    Centos7.0 Vmware 网络桥接配置,利用DHCP自动获取ip地址 首先要将Vmware10.0.3设置为桥接模式. CentOS 7.0默认安装好之后是没有自动开启网络连接的! cd  / ...

  9. 详解如何设置CentOS 7开机自动获取IP地址

    本例中以CentOS 7举例说明如何设置Linux开机自动获取IP地址和设置固定IP地址. 自动获取动态IP地址 1.输入“ip addr”并按回车键确定,发现无法获取IP(CentOS 7默认没有i ...

随机推荐

  1. uva 1377

    比较不错的一个题,关键是理解状态转移 #include<algorithm> #include<cstdio> #include<cstring> #include ...

  2. hdu 4665

    转载一下  用的搜索   竟然过了 ............代码 ....... #include<stdio.h> #include<string.h> #include&l ...

  3. Android 如何切换到 Transform API?

    摘要: 如果你的 Android 构建中涉及到字节码插装(bytecode instrumentation),或者应用中提供了进行插装的插件,并希望它能支持 Instant Run,那么你必须切换到 ...

  4. web页面浮动回到顶部功能和浮动广告

    实现测试浮动回到顶部 法一:用js实现<%@ Page Language="C#" AutoEventWireup="true" CodeBehind=& ...

  5. 修改tomcat的默认编码

    在tomcat的安装路径下查找conf文件下的server.xml文件,修改此文件即可,修改内容如下: <Connector port="8080" protocol=&qu ...

  6. highcharts 多数据+切换

    var highchartsOptions = { chart:{ renderTo:'container' }, title:{ text:'指标数据' }, tooltip:{ pointForm ...

  7. C++中的指针与const

    刚开始接触C++时,指针和const之间的关系有点混乱,现在总结如下: 一.指向const变量的指针 #include<iostream.h> void main() { const in ...

  8. C语言字节对齐

    转自:http://blog.csdn.net/21aspnet/article/details/6729724 文章最后本人做了一幅图,一看就明白了,这个问题网上讲的不少,但是都没有把问题说透. 一 ...

  9. NFC(12)使用Android Beam技术传输文本数据及它是什么

    Android Beam技术是什么 Android Beam的基本理念就是两部(只能是1对1,不可像蓝牙那样1对多)NFC设备靠近时(一般是背靠背),通过触摸一部NFC设备的屏幕,将数据推向另外一部N ...

  10. NFC(6)NFC编程的几个重要类,NFC硬件启动android应用原理

    用于NFC编程的几个重要类 Tag NFC 标签 NfcAdapter Nfc 的适配类 NdefMessage 描述NDEF格式的信息 NdefRecord 描述NDEF信息的一个信息段,类似tab ...