路由route add命令详解

route add  时间:2021-01-31  阅读:()

route add命令详解

添加命令详解路线

1。具体功能

该命令用于在本地IP路由表中显示和修改条目可以显示帮助使用不带参数的路线。

2。语法详解

路径[ ] [ ] [目的] [ P命令[面具] [子网掩码网关] [度量] [如果交口]

3。参数说明

F

清除所有不是主路由子网掩码为255.255.255.255的路由、环回网络路由目标为127.0.0.0子网掩码为255. 255.255.0的路由或多播路由目标为224.0.0.0子网掩码为240.0.0.0的路由的条目的路由表。如果它与命令之一例如添加、改变或删除结合使用表会在运行命令之前清除。

P

与添加命令共同使用时指定路由被添加到注册表并在启动TCP/IP协议的时候初始化IP路由表。默认情况下启动TCP/IP协议时不会保存添加的路由与打印命令一起使用时则显示永久路由列表。所有其他的命令都忽略此参数永久路由存储在注册表中的位置是hkey_local_machsystemcurrentcontrolsetservicestcpipparameterspersistentroutes。

指定要运行的命令下表列出了有效的命令命令。

目的地

指定路由的网络目标地址。 目标地址可以是一个IP网络地址其中网络地址的主机地址位设置为0对于主机路由是IP地址对于默认路由是0.0.0.0。

面具

子网掩码

指定与网络目标地址相关联的网掩码又称子网掩码。子网掩码对于IP网络地址可以是一适当的子网掩码对于主机路由是

255.255.255.255对于默认路由是0.0.0.0。如果忽略则使用子网掩码255.255.255.255。定义路由时由于目标地址和子网掩码之间的关系 目标地址不能比它对应的子网掩码更为详细。换句话说如果子网掩码的一位是0则目标地址中的对应位就不能设置为1。网关

指定超过由网络目标和子网掩码定义的可达到的地址集的前一个或下一个跃点IP地址。对于本地连接的子网路由 网关地址是分配给连子网接口的IP地址。对于要经过一个或多个路由器才可用到的远程路由 网关地址是一个分配给相邻路由器的、可直接达到的IP地址。

米制的

为路由指定所需跃点数的整数值范围是19999它用来在路由

表里的多个路由中选择与转发包中的目标地址最为匹配的路由。所选的路由具有最少的跃点数。跃点数能够反映跃点的数量、路径的速度、路径可靠性、路径吞吐量以及管理属性。

如果交口指定目标可以到达的接口的接口索引使用打印命令可以显示接口及其对应接口索引的列表路线。

For interface indexes, you can use decimal or sixteen decimalvalues. For the sixteen decimal value, add the 0x in front ofthe sixteen hexadecimal number. When the if parameter isignored, the interface is determined by the gateway address.Note: the value of a jump column in the routing table is largerbecause it allows TCP/IP to automatically determine the numberof hops in the routing table based on the IP address, subnetmask, and the configuration of the default gateway for each LANinterface. The default start automatically determines theinterface hops, determines the speed of each interface, andadjusts the number of routing hops per interface, so the routecreated by the fastest interface has the lowest hop count. Toremove the maximum number of hops, please connect the advancedproperties in each of the LAN TCP/IP protocol to disable theautomatic determination of the interface metric. If you havethe appropriate entry in the local network file in thesystemrootSystem32DriversEtc folder, the name can be used forDestination. As long as the name through the "domain namesystem" (DNS) query standard host name resolution techniquessuch as decomposition of the IP address, it can be used forGateway, DNS and NetBIOS for local host file name stored in thesystemrootSystem32DriversEtc folder under the use of. If it isa Print or Delete command, you can ignore the Gateway parameter

anduse wildcards to represent the target and gateway. The valueof Destination can be awildcard specified by an asterisk (*) .If the specified target contains an asterisk (*) or a questionmark, it is treated as a wildcard and prints or deletes thematched target route only. An asterisk stands for any charactersequence, and a question mark stands for any character. Forexample, 10.*. 1, 192. 168.*, 127.*, and*224*are all valid useof asterisk wildcards. Using a combination of invalid targetand subnet mask (mesh mask) values, the Route bad gatewayaddress netmask error message is displayed. This error occurswhen one or more of the targets are set to 0, and when thecorresponding bit in the subnet mask is set to 1. This can bechecked by binary representation of the target and subnet mask.A subnet mask represented in binary, including a series of 0and two parts representing the target network address section,a series of 1, and a part of the address of the target host.Check the target host address portion to determine target(defined subnet mask) whether some bits are set to 1.The Route command of Windows 98 does not support the -pparameter.

This command is available only when the TCP/IP protocol isinstalled as a component of the network adapter property in thenetwork connection.

4. illustrate

Example 1: to display the full content of the IP routing table,execute the following command:

Route print

Example 2: to show the route started at 10. in the IP routingtable, execute the following command:

Route print 10.*

Example 3: to add the default routing of the default gatewayaddress to 192. 168. 12. 1, execute the following command:Route, add, 0.0.0.0, mask, 0.0.0.0, 192. 168. 12. 1

Example 4: to add the target 10.41.0.0, the subnet mask is

255.255.0.0, andthe next hopaddress is 10. 27.0. 1, execute thefollowing command:

Route, add, 10.41.0.0, mask, 255.255.0.0, 10. 27.0. 1

Example 5: to add the target to 10.41.0.0, the subnet mask to

255.255.0.0, the next hop address to 10.27.0. 1 is the permanentroute, and execute the following command:

Route, -p, add, 10.41.0.0, mask, 255.255.0.0, 10.27.0. 1Example 6: add the target 10.41.0.0, the subnet mask is

255.255.0.0, the next hop address is 10.27.0. 1, and the hopcount is 7. Execute the following command:

Route, add, 10.41.0.0, mask, 255.255.0.0, 10.27.0. 1, metric,

7

Example 7: add the target to 10.41.0.0, the subnet mask to

255.255.0.0, the next hop address to 10.27.0. 1, the routing ofthe interface index to 0x3, and execute the following command:Route, add, 10.41.0.0, mask, 255.255.0.0, 10.27.0. 1, if, 0x3Example 8: to delete the target 10.41.0.0 and subnet mask

255.255.0.0 routing, execute the following command:

Route, delete, 10.41.0.0, mask, 255. 255.0.0

Example 9: to delete all routes starting with 10. in the IProuting table, execute the following command:

Route delete 10.*

Example 10: to target 10.41.0.0, the next hop of the routingfor subnet mask 255.255.0.0 is changed from 10.27.0. 1 to

10.27.0.25, and the following command is executed:

Route, change, 10.41.0.0, mask, 255. 255.0.0, 10. 27.0.25Example 11: to add a static route to the target, the 172.0.0.0segment is forwarded to the network as a route for 172.25.25. 1Route, add, 172.0.0.0, mask, 255.0.0.0, 172.25.25. 1, metric,2, -p

蓝竹云挂机宝25元/年,美国西雅图 1核1G 100M 20元

蓝竹云怎么样 蓝竹云好不好蓝竹云是新商家这次给我们带来的 挂机宝25元/年 美国西雅图云服务器 下面是套餐和评测,废话不说直接开干~~蓝竹云官网链接点击打开官网江西上饶挂机宝宿主机配置 2*E5 2696V2 384G 8*1500G SAS RAID10阵列支持Windows sever 2008,Windows sever 2012,Centos 7.6,Debian 10.3,Ubuntu1...

妮妮云(30元),美国300G防御 2核4G 107.6元,美国高速建站 2核2G

妮妮云的来历妮妮云是 789 陈总 张总 三方共同投资建立的网站 本着“良心 便宜 稳定”的初衷 为小白用户避免被坑妮妮云的市场定位妮妮云主要代理市场稳定速度的云服务器产品,避免新手购买云服务器的时候众多商家不知道如何选择,妮妮云就帮你选择好了产品,无需承担购买风险,不用担心出现被跑路 被诈骗的情况。妮妮云的售后保证妮妮云退款 通过于合作商的友好协商,云服务器提供2天内全额退款,超过2天不退款 物...

阿里云服务器绑定域名的几个流程整理

今天遇到一个网友,他之前一直在用阿里云虚拟主机,我们知道虚拟主机绑定域名是直接在面板上绑定的。这里由于他的网站项目流量比较大,虚拟主机是不够的,而且我看他虚拟主机已经有升级过。这里要说的是,用过阿里云虚拟主机的朋友可能会比较一下价格,实际上虚拟主机价格比云服务器还贵。所以,基于成本和性能的考虑,建议他选择云服务器。毕竟他的备案都接入在阿里云。这里在选择阿里云服务器后,他就蒙圈不知道如何绑定域名。这...

route add为你推荐
盗版win8.1升级win10盗版win10怎么升级到win10手机浏览器哪个好目前手机浏览器哪个最好电热水器和燃气热水器哪个好电热水器和燃气热水器哪个好?二手车网站哪个好卖二手车网站哪个好苹果手机助手哪个好最新版iphone助手 PP助手好用吗?网页传奇哪个好玩近有什么好玩的网页传奇介绍么网页传奇哪个好玩有什么好玩的传奇类网页游戏?电陶炉和电磁炉哪个好电陶炉和电磁炉哪个好?主要是炒菜,爆炒。电陶炉和电磁炉哪个好电磁炉和电陶炉哪个好? 电磁炉和电陶炉的具体区别雅思和托福哪个好考托福好考还是雅思好考?
下载虚拟主机 天津服务器租赁 vps虚拟服务器 花生壳免费域名 互联网域名管理办法 80vps bbr 绍兴高防 合肥鹏博士 全站静态化 谁的qq空间最好看 中国网通测速 gtt 国外在线代理服务器 国外的代理服务器 lamp是什么意思 美国迈阿密 97rb 阿里云邮箱个人版 广州服务器托管 更多