강좌
클라우드/리눅스에 관한 강좌입니다.
네트워크 분류

추가로 할당한 IP주소로 통신 테스트하기

작성자 정보

  • 관리자 작성
  • 작성일

컨텐츠 정보

본문

추가로 할당한 IP주소로 통신 테스트하기

 

 

 

 

설정된 각각의 이더넷들이 정상적으로 통신이 되는가를 확인해 보도록 하자.

 

 

 

당연히 각각의 IP주소들로 ping테스트를 수행해 보도록 할 것이다.

 

 

 

 

 

[root@sulinux ~]#ping 192.168.0.241

PING 192.168.0.241 (192.168.0.241) 56(84) bytes of data.

64 bytes from 192.168.0.241: icmp_seq=1 ttl=64 time=0.546 ms

64 bytes from 192.168.0.241: icmp_seq=2 ttl=64 time=0.079 ms

 

--- 192.168.0.241 ping statistics ---

2 packets transmitted, 2 received, 0% packet loss, time 1000ms

rtt min/avg/max/mdev = 0.079/0.312/0.546/0.234 ms

[root@sulinux ~]#

[root@sulinux ~]#ping 192.168.0.242

PING 192.168.0.242 (192.168.0.242) 56(84) bytes of data.

64 bytes from 192.168.0.242: icmp_seq=1 ttl=64 time=0.333 ms

64 bytes from 192.168.0.242: icmp_seq=2 ttl=64 time=0.069 ms

 

--- 192.168.0.242 ping statistics ---

2 packets transmitted, 2 received, 0% packet loss, time 1000ms

rtt min/avg/max/mdev = 0.069/0.201/0.333/0.132 ms

[root@sulinux ~]#

[root@sulinux ~]#ping 192.168.0.243

PING 192.168.0.243 (192.168.0.243) 56(84) bytes of data.

64 bytes from 192.168.0.243: icmp_seq=1 ttl=64 time=0.352 ms

64 bytes from 192.168.0.243: icmp_seq=2 ttl=64 time=0.068 ms

 

--- 192.168.0.243 ping statistics ---

2 packets transmitted, 2 received, 0% packet loss, time 1000ms

rtt min/avg/max/mdev = 0.068/0.210/0.352/0.142 ms

[root@sulinux ~]#

[root@sulinux ~]#ping 192.168.0.244

PING 192.168.0.244 (192.168.0.244) 56(84) bytes of data.

64 bytes from 192.168.0.244: icmp_seq=1 ttl=64 time=0.136 ms

64 bytes from 192.168.0.244: icmp_seq=2 ttl=64 time=0.213 ms

 

--- 192.168.0.244 ping statistics ---

2 packets transmitted, 2 received, 0% packet loss, time 1000ms

rtt min/avg/max/mdev = 0.136/0.174/0.213/0.040 ms

[root@sulinux ~]#

[root@sulinux ~]#ping 192.168.0.245

PING 192.168.0.245 (192.168.0.245) 56(84) bytes of data.

64 bytes from 192.168.0.245: icmp_seq=1 ttl=64 time=0.432 ms

64 bytes from 192.168.0.245: icmp_seq=2 ttl=64 time=0.373 ms

64 bytes from 192.168.0.245: icmp_seq=3 ttl=64 time=0.405 ms

 

--- 192.168.0.245 ping statistics ---

3 packets transmitted, 3 received, 0% packet loss, time 2001ms

rtt min/avg/max/mdev = 0.373/0.403/0.432/0.029 ms

[root@sulinux ~]#

 

 

 

 

이상과 같이 모두 정상적인 통신이 이루어진다는 것을 알 수 있다.

 

 

 

 그렇다면 이번에는 현재 192.168.0.250 IP주소에서 192.168.0.245 IP주소로 원격접속을 해보도록 하겠다.

 

 

 

 

 

[root@sulinux ~]#ssh -l sspark 192.168.0.245

The authenticity of host '192.168.0.245 (192.168.0.245)' can't be established.

RSA key fingerprint is af:84:1f:77:2b:fe:b5:36:dd:68:9b:32:d7:c4:80:1f.

Are you sure you want to continue connecting (yes/no)? yes

Warning: Permanently added '192.168.0.245' (RSA) to the list of known hosts.

sspark@192.168.0.245's password: ********

sspark@sulinux ~ $

sspark@sulinux ~ $

 

 

 

 

다른 IP주소로도 이와 같은 방법을 이용하여 원격접속이 가능할 것이다.

 

 

 

 

 

이제 우리는 물리적인 하나의 이더넷(혹은 하나의 시스템)에서 여러 개의 IP주소를 추가하여 개별적으로 사용할 수 있다는 것을 알 수 있었다.

 

 

 

 그렇다면 이론적으로 몇 개까지의 IP주소를 추가로 생성할 수 있을까? 그렇다.

 

 

 

 이번 예에서는 하나의 C클래스 네트워크에서는 모두 254개의 호스트를 설정할 수 있다.

 

 

 

 따라서 이것은 전적으로 네트워크의 구성에 따라서 달라질 수도 있고 생성한 이더넷을 다른 네트워크에 속하게 할 수도 있다.

 

 

 

  이상으로 리눅스 커널의 IP앨리아스 기능을 이용하여 하나의 이더넷에 여러 개의 IP주소를 생성하여 사용하는 방법에 대한 설명을 마치도록 한다.

 

 

 

 

관련자료

댓글 0
등록된 댓글이 없습니다.

공지사항


뉴스광장


  • 현재 회원수 :  60,034 명
  • 현재 강좌수 :  35,787 개
  • 현재 접속자 :  199 명