LoginSignup
0
0

ccna取得に向けてCiscoPacketTracerで構築練習 ~ルータ設定~

Posted at

はじめに

CCNAを受験するにあたって、実際にコマンドを打って構築をすることが大切らしい。
Cisco Packet Tracerを使用して構築の練習とその流れ、結果を示して、気づいたことなどをまとめていこうと思う。

1. 基本的な使い方

機器の設置

  • 画面下部の機器アイコンから選ぶ。
    無題.png

  • とりあえずルータ(1841)とPC(Laptop)を1台ずつ設置し、ケーブルをつなぐ。
    Cisco Packet Tracer 2024_05_16 0_16_01.png

  • ルータのアイコンをクリックし、CLIタブを選んでコマンドを入力していく。
    Router0 2024_05_15 23_58_24.png

コマンドを打ち込む

設定内容は以下のようにする。

  • ルータ名 : Cisco1841
  • enableパスワード : enable01
  • コンソールパスワード : console01
  • ユーザを3つ作成
    ユーザ名 : パスワード : 特権レベル
    user1 : pass1 : 0
    user2 : pass2 : 1
    user3 : pass3 : 15
  • ssh telnet で接続(接続数最大5台)するときに、上のユーザでログインできるようにする。
  • ドメイン名はcisco.jp
  • パスワードの暗号化はしない
  • ipアドレスはfa/01に192.168.1.1/24

結果

コマンドを入力した部分のスクショを取り忘れたので、configだけ載せる。

Cisco1841
Cisco1841#show run
Building configuration...

Current configuration : 792 bytes
!
version 12.4
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Cisco1841 //ホスト名
!
!
!
enable password enable01 //enableパスワード
!
!
!
!
!
!
ip cef
no ipv6 cef
!
!
! //ユーザ3つ
username user1 privilege 0 password 0 pass1
username user2 password 0 pass2
username user3 privilege 15 password 0 pass3
!
!
!
!
!
!
!
!
ip ssh version 1
ip domain-name cisco.jp //ドメイン名
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface FastEthernet0/0
 no ip address
 duplex auto
 speed auto
 shutdown
!
interface FastEthernet0/1
 ip address 192.168.1.1 255.255.255.0 //IPアドレス設定
 duplex auto
 speed auto
!
interface Vlan1
 no ip address
 shutdown
!
ip classless
!
ip flow-export version 9
!
!
!
!
!
!
!
!
line con 0
 password console01
 login //パスワードログイン
!
line aux 0
!
line vty 0 4
 login local //ユーザログイン
!
!
!
end

PCから接続してみる

PCのアイコンをダブルクリックし、デスクトップタブを選択。
IP ConfiguretionからIPアドレスを設定して、console接続はTerminalから、telnet sshはTelnat/SSH Clientから接続する。

Console接続

Laptop0 2024_05_16 0_50_40.png

SSH

  • User1
    sshUser1.png
    sshUser1-prompt.png

  • user2
    sshUser2-prompt.png

  • user3
    sshUser3-prompt.png

気になったとこと,覚えておきたいこと

  • ssh version2を設定するにはRSAキーの長さが一定(768byte)以上のものを生成しないといけないらしい。
Cisco1841
Cisco1841(config)#ip ssh version 2
Please create RSA keys (of at least 768 bits size) to enable SSH v2.

参考サイト

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0