• If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.
Xin chào ! Nếu đây là lần đầu tiên bạn đến với diễn đàn, xin vui lòng danh ra một phút bấm vào đây để đăng kí và tham gia thảo luận cùng VnPro.

Announcement

Collapse
No announcement yet.

help lab nat

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • help lab nat

    mô hình R1-------R2
    thực hiện nat ở R1
    đấy là show run trên R1
    !
    interface Loopback0
    ip address 10.1.1.1 255.255.255.0 secondary
    ip address 10.1.1.2 255.255.255.0 secondary
    ip address 10.1.1.3 255.255.255.0 secondary
    ip address 10.1.1.4 255.255.255.0
    ip nat inside
    ip virtual-reassembly
    !
    interface Serial0/0
    ip address 192.168.1.1 255.255.255.0
    ip nat outside
    ip virtual-reassembly
    serial restart-delay 0
    no dce-terminal-timing-enable
    !
    interface Serial0/1
    no ip address
    shutdown
    serial restart-delay 0
    no dce-terminal-timing-enable
    !
    interface Serial0/2
    no ip address
    shutdown
    serial restart-delay 0
    no dce-terminal-timing-enable
    !
    interface Serial0/3
    no ip address
    shutdown
    serial restart-delay 0
    no dce-terminal-timing-enable
    !
    ip http server
    no ip http secure-server
    ip classless
    ip route 0.0.0.0 0.0.0.0 192.168.1.2
    !
    !
    ip nat pool vinh 195.1.1.1 195.1.1.2 netmask 255.255.255.0
    ip nat inside source list 1 pool vinh overload
    !
    access-list 1 permit 10.1.1.0 0.0.0.255
    !
    !


    đây là show run trên R2

    !
    !
    interface Serial0/0
    ip address 192.168.1.2 255.255.255.0
    serial restart-delay 0
    clockrate 64000
    no dce-terminal-timing-enable
    !
    interface Serial0/1
    no ip address
    shutdown
    serial restart-delay 0
    no dce-terminal-timing-enable
    !
    interface Serial0/2
    no ip address
    shutdown
    serial restart-delay 0
    no dce-terminal-timing-enable
    !
    interface Serial0/3
    no ip address
    shutdown
    serial restart-delay 0
    no dce-terminal-timing-enable
    !
    ip http server
    no ip http secure-server
    ip classless
    ip route 10.1.1.0 255.255.255.0 192.168.1.1
    !
    !

    đây là ping extened trên R1 đến cổng 192.168.1.2 trên R2

    R1#ping
    Protocol [ip]:
    Target IP address: 192.168.1.2
    Repeat count [5]:
    Datagram size [100]:
    Timeout in seconds [2]:
    Extended commands [n]: y
    Source address or interface: 10.1.1.1
    Type of service [0]:
    Set DF bit in IP header? [no]:
    Validate reply data? [no]:
    Data pattern [0xABCD]:
    Loose, Strict, Record, Timestamp, Verbose[none]:
    Sweep range of sizes [n]:
    Type escape sequence to abort.
    Sending 5, 100-byte ICMP Echos to 192.168.1.2, timeout is 2 seconds:
    Packet sent with a source address of 10.1.1.1

    *Mar 1 00:18:17.099: NAT: s=10.1.1.1->195.1.1.2, d=192.168.1.2 [35].
    *Mar 1 00:18:19.099: NAT: s=10.1.1.1->195.1.1.2, d=192.168.1.2 [36].
    *Mar 1 00:18:21.099: NAT: s=10.1.1.1->195.1.1.2, d=192.168.1.2 [37].
    *Mar 1 00:18:23.099: NAT: s=10.1.1.1->195.1.1.2, d=192.168.1.2 [38].
    *Mar 1 00:18:25.099: NAT: s=10.1.1.1->195.1.1.2, d=192.168.1.2 [39].
    Success rate is 0 percent (0/5)

    Nhưng nếu em đổi dải nat 195.1.1.1 195.1.1.2 thành địa chỉ cùng dải với thằng serial là 192.168.1.10 192.168.1.11 thì ping extended lại ngon thế là như thế nào ạ

    vậy bài nat trên em làm có đúng ko ạ vì bài này tương tự bài trong đề thi ccna

  • #2
    cấu hình thấy ổn rồi,bạn hỏi rỏ hơn xem,Nat ngoài cơ chế chuyển đổi ip private thành ip public,nó còn giúp thay đổi ip source đi đến đích,
    Hugo

    Comment


    • #3
      nếu em cấu hình đúng rùi sao lại ko ping extended từ nguồn là 10.1.1.1 tới đích là 192.168.1.2 ạ

      Comment


      • #4
        bạn có thể up hình lên ko, vậy sẽ dễ nhìn hơn
        -------------------------------------------------------------------------------------
        Một nụ cười ko làm nghèo người phát nó nhưng làm giàu người nhận nó.

        Comment


        • #5
          Click image for larger version

Name:	untitled43.JPG
Views:	1
Size:	4.5 KB
ID:	205415
          hình chỉ có 2 router nè thui ... 2 cổng của 2 router đều là s0/0

          Comment


          • #6
            hi chào bạn. bạn ping ko được là đúng rồi. bạn ping từ source 10.1.1.1 đến 192.168.1.2, chiều đi thì được nhưng lúc router 2 trả về thì lại ko biết mạng 195.1.1.0. ở router 1 bạn có thể add thêm đường mạng 195.1.1.0 vào bảng định tuyến hoặc từ router 2 bạn thêm 1 định tuyến tĩnh đến mạng đó thử.
            -------------------------------------------------------------------------------------
            Một nụ cười ko làm nghèo người phát nó nhưng làm giàu người nhận nó.

            Comment


            • #7
              uk nhỉ ping được rùi thanks bạn nhé...hihi

              Comment

              Working...
              X