Windows Client TechCenter > Windows 7 Forums > Windows 7 Networking > windows 7 DisableDHCPMediaSense and routing table
Ask a questionAsk a question
 

Answerwindows 7 DisableDHCPMediaSense and routing table

  • Tuesday, November 03, 2009 10:55 PMrtserv Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    On xp, if DisableDHCPMediaSense is set to 1 (true),  I unplug the NIC cable, the routing table would remain the same before and after.
    On windows 7 (and server 2008, and vista), I do the same thing but the entries for this networking adapter interface would disappear from the routing table.
    It seems to me that windows still could detect the disconnection and update the routing table.

    What else could I do to keep the routing table the same even the cable is unplugged on windows 7 (server 2008, vista)?

    BTW 10.4.0.6 is the static IP of  the NIC interface.


    C:\Users\xxx>netsh interface ipv4 show
    Querying active state...

    General Global Parameters
    ---------------------------------------------
    Default Hop Limit                   : 128 hops
    Neighbor Cache Limit                : 256 entr
    Route Cache Limit                   : 128 entr
    Reassembly Limit                    : 16489536
    ICMP Redirects                      : enabled
    Source Routing Behavior             : forward
    Task Offload                        : enabled
    Dhcp Media Sense                    : disabled  <-------------------
    Media Sense Logging                 : enabled
    MLD Level                           : all
    MLD Version                         : version3
    Multicast Forwarding                : disabled
    Group Forwarded Fragments           : disabled
    Randomize Identifiers               : enabled
    Address Mask Reply                  : disabled

    Current Global Statistics
    ---------------------------------------------
    Number of Compartments              : 1
    Number of NL clients                : 5
    Number of FL providers              : 4

    before:

    C:\Users\xxx>route print
    ===========================================================================
    Interface List
     11 ...00 10 18 3a 8b ec ...... Broadcom NetXtreme Gigabit Ethernet
     10 ...00 23 ae 6a 03 90 ...... Intel(R) 82566DM-2 Gigabit Network Connectio
      1 ........................... Software Loopback Interface 1
    ===========================================================================

    IPv4 Route Table
    ===========================================================================
    Active Routes:
    Network Destination        Netmask          Gateway       Interface  Metric
              0.0.0.0          0.0.0.0     155.177.16.1    155.177.16.85     20
             10.4.0.0      255.254.0.0         On-link          10.4.0.6    276        <---- will disappear
             10.4.0.6  255.255.255.255         On-link          10.4.0.6    276    <---- will disappear

         10.5.255.255  255.255.255.255         On-link          10.4.0.6    276
            127.0.0.0        255.0.0.0         On-link         127.0.0.1    306
            127.0.0.1  255.255.255.255         On-link         127.0.0.1    306
      127.255.255.255  255.255.255.255         On-link         127.0.0.1    306
         155.177.16.0    255.255.255.0         On-link     155.177.16.85    276
        155.177.16.85  255.255.255.255         On-link     155.177.16.85    276
       155.177.16.255  255.255.255.255         On-link     155.177.16.85    276
            224.0.0.0        240.0.0.0         On-link         127.0.0.1    306
            224.0.0.0        240.0.0.0         On-link          10.4.0.6    276
            224.0.0.0        240.0.0.0         On-link     155.177.16.85    276
      255.255.255.255  255.255.255.255         On-link         127.0.0.1    306
      255.255.255.255  255.255.255.255         On-link          10.4.0.6    276
      255.255.255.255  255.255.255.255         On-link     155.177.16.85    276
    ===========================================================================
    Persistent Routes:
      None

    IPv6 Route Table
    ===========================================================================
    Active Routes:
     If Metric Network Destination      Gateway
      1    306 ::1/128                  On-link
      1    306 ff00::/8                 On-link
    ===========================================================================
    Persistent Routes:
      None

    After:

    C:\Users\xxx>route print
    ===========================================================================
    Interface List
     11 ...00 10 18 3a 8b ec ...... Broadcom NetXtreme Gigabit Ethernet
     10 ...00 23 ae 6a 03 90 ...... Intel(R) 82566DM-2 Gigabit Network Connectio
      1 ........................... Software Loopback Interface 1
    ===========================================================================

    IPv4 Route Table
    ===========================================================================
    Active Routes:
    Network Destination        Netmask          Gateway       Interface  Metric
              0.0.0.0          0.0.0.0     155.177.16.1    155.177.16.85     20
            127.0.0.0        255.0.0.0         On-link         127.0.0.1    306
            127.0.0.1  255.255.255.255         On-link         127.0.0.1    306
      127.255.255.255  255.255.255.255         On-link         127.0.0.1    306
         155.177.16.0    255.255.255.0         On-link     155.177.16.85    276
        155.177.16.85  255.255.255.255         On-link     155.177.16.85    276
       155.177.16.255  255.255.255.255         On-link     155.177.16.85    276
            224.0.0.0        240.0.0.0         On-link         127.0.0.1    306
            224.0.0.0        240.0.0.0         On-link     155.177.16.85    276
      255.255.255.255  255.255.255.255         On-link         127.0.0.1    306
      255.255.255.255  255.255.255.255         On-link     155.177.16.85    276
    ===========================================================================
    Persistent Routes:
      None

    IPv6 Route Table
    ===========================================================================
    Active Routes:
     If Metric Network Destination      Gateway
      1    306 ::1/128                  On-link
      1    306 ff00::/8                 On-link
    ===========================================================================
    Persistent Routes:
      None


    Thanks.

Answers

All Replies

  • Wednesday, November 04, 2009 6:42 AMArthur XieMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Did you restart the computer after disconnect one connection? How does it work if you plug the cable again? How does it work if you disconnect the remained connection?

    If  DisableDHCPMediaSense works, the route table will not change if the computer does not restart.


    Arthur Xie - MSFT
  • Wednesday, November 04, 2009 2:20 PMrtserv Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I did not restart the computer after disconnect one connection. If I plug the cable again, the missing entries come back to the routing table.
    I could not disconnect the remained connection since the machine is in the corporate domain and will be stuck there without connection.

    You could see from the cli "netsh interface ipv4 show" that DisableDHCPMediaSense is disabled. The behavior on xp is as you described, the route table will not change if the computer does not restart. However, vista or 7 changes the behavior and this flag no longer functions like it's on xp.

    Any other flag I could use on vista or 7?
    Thanks.
  • Thursday, November 12, 2009 9:09 AMArthur XieMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer
    I have see some other samples. We will report it to proper department.
    Arthur Xie - MSFT