Posted on 2006/10/16 19:48
Filed Under OS/YJJ Linux



To add a static IP route

  1. Open Command Prompt
  2. At the command prompt, type:

    route add destination mask subnetmask gateway metric costmetric if interface

    where:

    destination Specifies either an IP address or host name for the network or host.
    subnetmaskSpecifies a subnet mask to be associated with this route entry. If subnetmask is not specified, 255.255.255.255 is used.
    gatewaySpecifies either an IP address or host name for the gateway or router to use when forwarding.
    costmetricAssigns an integer cost metric (ranging from 1 through 9,999) to be used in calculating the fastest, most reliable, and/or least expensive routes. If costmetric is not specified, 1 is used.
    interfaceSpecifies the interface to be used for the route that uses the interface number. If an interface is not specified, the interface to be used for the route is determined from the gateway IP address.

    For example, to add a static route to the 10.0.0.0 network that uses a subnet mask of 255.0.0.0, a gateway of 192.168.0.1, and a cost metric of 2, you type the following at a command prompt:

    route add 10.0.0.0 mask 255.0.0.0 192.168.0.1 metric 2

Note

  • To open Command Prompt, click Start, point to Programs, point to Accessories, and then click Command Prompt.
  • To make a static route persistent, you can either enter route add commands in a batch file that is run during system startup or use the -p option when adding routes.
  • Routes added by using the -p option are stored in the Windows 2000 registry under the following key:

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip \Parameters\PersistentRoutes

  • All symbolic names used for destination or gateway are looked up in the network and computer name database files (Networks and Hosts), which are stored in the local systemroot\System32\Drivers\Etc folder.
  • If a route addition fails, you can use the tracert command to verify that the gateway specified is directly reachable from the same subnet as this computer.
출처 : http://blog.naver.com/koreabigman?Redirect=Log&logNo=20023067858

ps. 제작자의 요청이 있을경우 무조건 삭제 처리함...
크리에이티브 커먼즈 라이센스
Creative Commons License
이올린에 북마크하기
2006/10/16 19:48 2006/10/16 19:48

트랙백 주소 : http://blog.seabow.pe.kr/trackback/220



About

by 삐꾸강아쥐

Counter

· Total
: 137357
· Today
: 58
· Yesterday
: 0
블로그코리아에 블UP하기