Network NClients

Package: inet.examples.inet.nclients
File: examples/inet/nclients/NClients.ned

(no description)

IPv4NetworkConfigurator Router Router Router StandardHost StandardHost

Usage diagram:

The following diagram shows usage relationships between types. Unresolved types are missing from the diagram.

Inheritance diagram:

The following diagram shows inheritance relationships for this type. Unresolved types are missing from the diagram.

Parameters:

Name Type Default value Description
n int

Properties:

Name Value Description
isNetwork

Unassigned submodule parameters:

Name Type Default value Description
configurator.minLinkWeight double 1E-3
configurator.config xml xml("")

XML configuration parameters for IP address assignment and adding manual routes

configurator.assignAddresses bool true

assign IP addresses to all interfaces in the network

configurator.assignDisjunctSubnetAddresses bool true

avoid using the same address prefix and netmask on different links when assigning IP addresses to interfaces

configurator.addStaticRoutes bool true

add static routes to the routing tables of all nodes to route to all destination interfaces (only where applicable; turn off when config file contains manual routes)

configurator.addDefaultRoutes bool true

add default routes if all routes from a source node go through the same gateway (used only if addStaticRoutes is true)

configurator.addSubnetRoutes bool true

add subnet routes instead of destination interface routes (only where applicable; used only if addStaticRoutes is true)

configurator.optimizeRoutes bool true

optimize routing tables by merging routes, the resulting routing table might route more packets than the original (used only if addStaticRoutes is true)

configurator.dumpTopology bool false

print extracted network topology to the module output

configurator.dumpLinks bool false

print recognized network links to the module output

configurator.dumpAddresses bool false

print assigned IP addresses for all interfaces to the module output

configurator.dumpRoutes bool false

print configured and optimized routing tables for all nodes to the module output

configurator.dumpConfig string ""

write configuration into the given config file that can be fed back to speed up subsequent runs (network configurations)

r1.status.initialStatus string "UP"

TODO @signal, @statistic

r1.routingTable.forwarding bool
r1.routingTable.multicastForwarding bool
r1.interfaceTable.displayAddresses bool false

whether to display IP addresses on links

r1.pcapRecorder.verbose bool false

whether to log packets on the module output

r1.pcapRecorder.pcapFile string ""

the PCAP file to be written

r1.pcapRecorder.snaplen int 65535

maximum number of bytes to record per packet

r1.pcapRecorder.dumpBadFrames bool true

enable dump of frames with hasBitError

r1.pcapRecorder.moduleNamePatterns string "wlan[*] eth[*] ppp[*] ext[*]"

space-separated list of sibling module names to listen on

r1.pcapRecorder.sendingSignalNames string "packetSentToLower"

space-separated list of outbound packet signals to subscribe to

r1.pcapRecorder.receivingSignalNames string "packetReceivedFromLower"

space-separated list of inbound packet signals to subscribe to

r1.pcapRecorder.alwaysFlush bool false

flush the pcapFile after each write to ensure that all packets are captured in case of a crash

r1.lo0.lo.interfaceTableModule string

The path to the InterfaceTable module

r1.lo0.lo.mtu int 4470B
r1.bgp.interfaceTableModule string

The path to the InterfaceTable module

r1.bgp.routingTableModule string
r1.bgp.ospfRoutingModule string hasOSPF ? "^.ospf" : ""
r1.bgp.dataTransferMode string
r2.status.initialStatus string "UP"

TODO @signal, @statistic

r2.routingTable.forwarding bool
r2.routingTable.multicastForwarding bool
r2.interfaceTable.displayAddresses bool false

whether to display IP addresses on links

r2.pcapRecorder.verbose bool false

whether to log packets on the module output

r2.pcapRecorder.pcapFile string ""

the PCAP file to be written

r2.pcapRecorder.snaplen int 65535

maximum number of bytes to record per packet

r2.pcapRecorder.dumpBadFrames bool true

enable dump of frames with hasBitError

r2.pcapRecorder.moduleNamePatterns string "wlan[*] eth[*] ppp[*] ext[*]"

space-separated list of sibling module names to listen on

r2.pcapRecorder.sendingSignalNames string "packetSentToLower"

space-separated list of outbound packet signals to subscribe to

r2.pcapRecorder.receivingSignalNames string "packetReceivedFromLower"

space-separated list of inbound packet signals to subscribe to

r2.pcapRecorder.alwaysFlush bool false

flush the pcapFile after each write to ensure that all packets are captured in case of a crash

r2.lo0.lo.interfaceTableModule string

The path to the InterfaceTable module

r2.lo0.lo.mtu int 4470B
r2.bgp.interfaceTableModule string

The path to the InterfaceTable module

r2.bgp.routingTableModule string
r2.bgp.ospfRoutingModule string hasOSPF ? "^.ospf" : ""
r2.bgp.dataTransferMode string
r3.status.initialStatus string "UP"

TODO @signal, @statistic

r3.routingTable.forwarding bool
r3.routingTable.multicastForwarding bool
r3.interfaceTable.displayAddresses bool false

whether to display IP addresses on links

r3.pcapRecorder.verbose bool false

whether to log packets on the module output

r3.pcapRecorder.pcapFile string ""

the PCAP file to be written

r3.pcapRecorder.snaplen int 65535

maximum number of bytes to record per packet

r3.pcapRecorder.dumpBadFrames bool true

enable dump of frames with hasBitError

r3.pcapRecorder.moduleNamePatterns string "wlan[*] eth[*] ppp[*] ext[*]"

space-separated list of sibling module names to listen on

r3.pcapRecorder.sendingSignalNames string "packetSentToLower"

space-separated list of outbound packet signals to subscribe to

r3.pcapRecorder.receivingSignalNames string "packetReceivedFromLower"

space-separated list of inbound packet signals to subscribe to

r3.pcapRecorder.alwaysFlush bool false

flush the pcapFile after each write to ensure that all packets are captured in case of a crash

r3.lo0.lo.interfaceTableModule string

The path to the InterfaceTable module

r3.lo0.lo.mtu int 4470B
r3.bgp.interfaceTableModule string

The path to the InterfaceTable module

r3.bgp.routingTableModule string
r3.bgp.ospfRoutingModule string hasOSPF ? "^.ospf" : ""
r3.bgp.dataTransferMode string
cli.status.initialStatus string "UP"

TODO @signal, @statistic

cli.routingTable.forwarding bool
cli.routingTable.multicastForwarding bool
cli.interfaceTable.displayAddresses bool false

whether to display IP addresses on links

cli.pcapRecorder.verbose bool false

whether to log packets on the module output

cli.pcapRecorder.pcapFile string ""

the PCAP file to be written

cli.pcapRecorder.snaplen int 65535

maximum number of bytes to record per packet

cli.pcapRecorder.dumpBadFrames bool true

enable dump of frames with hasBitError

cli.pcapRecorder.moduleNamePatterns string "wlan[*] eth[*] ppp[*] ext[*]"

space-separated list of sibling module names to listen on

cli.pcapRecorder.sendingSignalNames string "packetSentToLower"

space-separated list of outbound packet signals to subscribe to

cli.pcapRecorder.receivingSignalNames string "packetReceivedFromLower"

space-separated list of inbound packet signals to subscribe to

cli.pcapRecorder.alwaysFlush bool false

flush the pcapFile after each write to ensure that all packets are captured in case of a crash

cli.lo0.lo.interfaceTableModule string

The path to the InterfaceTable module

cli.lo0.lo.mtu int 4470B
srv.status.initialStatus string "UP"

TODO @signal, @statistic

srv.routingTable.forwarding bool
srv.routingTable.multicastForwarding bool
srv.interfaceTable.displayAddresses bool false

whether to display IP addresses on links

srv.pcapRecorder.verbose bool false

whether to log packets on the module output

srv.pcapRecorder.pcapFile string ""

the PCAP file to be written

srv.pcapRecorder.snaplen int 65535

maximum number of bytes to record per packet

srv.pcapRecorder.dumpBadFrames bool true

enable dump of frames with hasBitError

srv.pcapRecorder.moduleNamePatterns string "wlan[*] eth[*] ppp[*] ext[*]"

space-separated list of sibling module names to listen on

srv.pcapRecorder.sendingSignalNames string "packetSentToLower"

space-separated list of outbound packet signals to subscribe to

srv.pcapRecorder.receivingSignalNames string "packetReceivedFromLower"

space-separated list of inbound packet signals to subscribe to

srv.pcapRecorder.alwaysFlush bool false

flush the pcapFile after each write to ensure that all packets are captured in case of a crash

srv.lo0.lo.interfaceTableModule string

The path to the InterfaceTable module

srv.lo0.lo.mtu int 4470B

Source code:

network NClients
{
    parameters:
        int n;
    types:
        channel fiberline extends ThruputMeteringChannel
        {
            delay = 1us;
            datarate = 512Mbps;
            thruputDisplayFormat = "u";
        }
        channel ethernetline extends ThruputMeteringChannel
        {
            delay = 0.1us;
            datarate = 10Mbps;
            thruputDisplayFormat = "u";
        }
    submodules:
        configurator: IPv4NetworkConfigurator {
            parameters:
                @display("p=185,50");
        }
        r1: Router {
            parameters:
                @display("p=186,250");
        }
        r2: Router {
            parameters:
                @display("p=304,220");
        }
        r3: Router {
            parameters:
                @display("p=433,250");
        }
        cli[n]: StandardHost {
            parameters:
                @display("i=device/laptop");
        }
        srv: StandardHost {
            parameters:
                @display("p=544,194;i=device/server_l");
        }
    connections:
        for i=0..n-1 {
            cli[i].pppg++ <--> ethernetline <--> r1.pppg++;
        }
        r1.pppg++ <--> ethernetline <--> r2.pppg++;
        r2.pppg++ <--> ethernetline <--> r3.pppg++;
        r3.pppg++ <--> ethernetline <--> srv.pppg++;
}