私は私のpiにsshすることができません。RPIはホストPCに直接接続されています。
ホストのIPアドレスを設定しました:----
sudo ifconfig eth0 192.168.0.204 netmask 255.255.255.0 up
sudo route add default gw 192.168.0.200
Piのネットワークインターフェースファイルには次のデフォルトIPがあります。
auto lo eth0
iface lo inet loopback
iface eth0 inet static
address 192.168.0.202
netmask 255.255.255.0
gateway 192.168.0.200
私のPCで構成コマンドの場合:-----
ignite@ignite-desktop:~$ ifconfig
eth0 Link encap:Ethernet HWaddr 6c:f0:49:f3:a6:1b
inet addr:192.168.0.204 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::6ef0:49ff:fef3:a61b/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:681 errors:0 dropped:0 overruns:0 frame:0
TX packets:208 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:43752 (43.7 KB) TX bytes:33407 (33.4 KB)
Interrupt:26 Base address:0x4000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:12 errors:0 dropped:0 overruns:0 frame:0
TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:1012 (1.0 KB) TX bytes:1012 (1.0 KB)
pingは同じホストで機能しています:----
ignite@ignite-desktop:~$ ping 192.168.0.204
PING 192.168.0.204 (192.168.0.204) 56(84) bytes of data.
64 bytes from 192.168.0.204: icmp_seq=1 ttl=64 time=0.026 ms
64 bytes from 192.168.0.204: icmp_seq=2 ttl=64 time=0.018 ms
64 bytes from 192.168.0.204: icmp_seq=3 ttl=64 time=0.017 ms
64 bytes from 192.168.0.204: icmp_seq=4 ttl=64 time=0.014 ms
Pingは私のホストPCからpiのために働いています:----
ignite@ignite-desktop:~$ ping 192.168.0.202
PING 192.168.0.202 (192.168.0.202) 56(84) bytes of data.
64 bytes from 192.168.0.202: icmp_seq=1 ttl=64 time=0.530 ms
64 bytes from 192.168.0.202: icmp_seq=2 ttl=64 time=0.508 ms
64 bytes from 192.168.0.202: icmp_seq=3 ttl=64 time=0.464 ms
64 bytes from 192.168.0.202: icmp_seq=4 ttl=64 time=0.445 ms
64 bytes from 192.168.0.202: icmp_seq=5 ttl=64 time=0.434 ms
SSHが機能しない
ignite@ignite-desktop:~$ ssh pi@raspberrypi
ssh: Could not resolve hostname raspberrypi: Name or service not known
ignite@ignite-desktop:~$ ssh pi@192.168.0.202
Read from socket failed: Connection reset by peer
ignite@ignite-desktop:~$ ssh 192.168.0.202 -l pi
Read from socket failed: Connection reset by peer
それを解決する方法を提案してください?
編集:---
ssh -vvv pi@192.168.0.202 --->出力は
ignite@ignite-desktop:~$ ssh -vvv pi@192.168.0.202
OpenSSH_5.1p1 Debian-6ubuntu2, OpenSSL 0.9.8g 19 Oct 2007
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to 192.168.0.202 [192.168.0.202] port 22.
debug1: Connection established.
debug1: identity file /home/ignite/.ssh/identity type -1
debug1: identity file /home/ignite/.ssh/id_rsa type -1
debug1: identity file /home/ignite/.ssh/id_dsa type -1
debug1: Remote protocol version 2.0, remote software version OpenSSH_6.0p1 Debian-2
debug1: match: OpenSSH_6.0p1 Debian-2 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_5.1p1 Debian-6ubuntu2
debug2: fd 3 setting O_NONBLOCK
debug1: SSH2_MSG_KEXINIT sent
Read from socket failed: Connection reset by peer