IPGlobalStatistics.ReceivedPacketsWithUnknownProtocol Egenskap

Definition

Hämtar antalet IP-paket (Internet Protocol) som tas emot på den lokala datorn med ett okänt protokoll i rubriken.

public:
 abstract property long ReceivedPacketsWithUnknownProtocol { long get(); };
public abstract long ReceivedPacketsWithUnknownProtocol { get; }
member this.ReceivedPacketsWithUnknownProtocol : int64
Public MustOverride ReadOnly Property ReceivedPacketsWithUnknownProtocol As Long

Egenskapsvärde

Ett Int64 värde som anger det totala antalet IP-paket som tagits emot med ett okänt protokoll.

Exempel

I följande kodexempel visas statistik för mottagna IP-paket med fel.


public static void ShowInboundIPErrors()
{
    IPGlobalProperties properties = IPGlobalProperties.GetIPGlobalProperties();
    IPGlobalStatistics ipstat = properties.GetIPv4GlobalStatistics();
    Console.WriteLine("  Inbound Packet Errors:");
    Console.WriteLine("      Header Errors ....................... : {0}",
        ipstat.ReceivedPacketsWithHeadersErrors);
    Console.WriteLine("      Address Errors ...................... : {0}",
        ipstat.ReceivedPacketsWithAddressErrors);
    Console.WriteLine("      Unknown Protocol Errors ............. : {0}",
        ipstat.ReceivedPacketsWithUnknownProtocol);
}
Public Shared Sub ShowInboundIPErrors() 
    Dim properties As IPGlobalProperties = IPGlobalProperties.GetIPGlobalProperties()
    Dim ipstat As IPGlobalStatistics = properties.GetIPv4GlobalStatistics()
    Console.WriteLine("  Inbound Packet Errors:")
    Console.WriteLine("      Header Errors ....................... : {0}", ipstat.ReceivedPacketsWithHeadersErrors)
    Console.WriteLine("      Address Errors ...................... : {0}", ipstat.ReceivedPacketsWithAddressErrors)
    Console.WriteLine("      Unknown Protocol Errors ............. : {0}", ipstat.ReceivedPacketsWithUnknownProtocol)

End Sub

Kommentarer

Protokollfältet i IP-huvudet anger det protokoll på nästa nivå som används i datadelen av IP-datagrammet. Om protokollet inte känns igen kan data inte skickas till rätt program.

Gäller för