linux - ssh Banana pi with mac -


so want control banana pi macbook pro using ssh. first using ssh. followed lot of different tutorials , still not work. if run :

pi@172.25.54.12 

or

bananapi@172.25.54.12 

or whatever name try answers me that

ssh: connect host 172.25.*.*2 port 22: operation timed out

and when try

bananapi@localhost 

or

pi@localhost 

it answers me:

ssh: connect host localhost port 22: connection refused

i found ip address doing ifconfig on bananapi. bananapi using bananian (debian banana pi), , mac 10.10.3.

when run sshd -t, have:

port 22 protocol 2 addressfamily listenaddress 0.0.0.0:22 listenaddress [::]:22 usepam 1 serverkeybits 768 logingracetime 120 keyregenerationinterval 3600 x11displayoffset 10 maxauthtries 6 maxsessions 10 clientaliveinterval 0 clientalivecountmax 3 permitrootlogin yes ignorerhosts yes ignoreuserknownhosts no rhostsrsaauthentication no hostbasedauthentication no hostbasedusesnamefrompacketonly no rsaauthentication yes pubkeyauthentication yes kerberosauthentication no kerberosorlocalpasswd yes kerberosticketcleanup yes gssapiauthentication no gssapikeyexchange no gssapicleanupcredentials yes gssapistrictacceptorcheck yes gssapistorecredentialsonrekey no passwordauthentication yes kbdinteractiveauthentication no challengeresponseauthentication no printmotd no printlastlog yes x11forwarding yes x11uselocalhost yes strictmodes yes tcpkeepalive yes permitblacklistedkeys no permitemptypasswords no permituserenvironment no uselogin no compression delayed gatewayports no usedns no allowtcpforwarding yes useprivilegeseparation yes pidfile /var/run/sshd.pid xauthlocation /usr/bin/xauth ciphers aes256-ctr,aes128-ctr macs hmac-sha2-512,hmac-sha2-256,hmac-ripemd160 loglevel info syslogfacility auth authorizedkeysfile .ssh/authorized_keys .ssh/authorized_keys2 hostkey /etc/ssh/ssh_host_rsa_key acceptenv lang acceptenv lc_* subsystem sftp /usr/lib/openssh/sftp-server maxstartups 10:30:100 permittunnel no ipqos lowdelay throughput permitopen 

any idea?

edit: suggested in comments, did :

$ ls -al ~/.ssh total 24  drwx------ 5 ***************** staff 170 12 mai 13:27 .  drwxr-xr-x 53 **************** staff 1802 12 mai 11:16 ..  -rw------- 1 ***************** staff 1766 12 mai 11:16 authorized_keys  -rw------- 1 ***************** staff 1679 12 mai 13:27 id_rsa  -rw-r--r-- 1 ***************** staff 429 12 mai 13:27 id_rsa.pub – 

this answer. have key in authorized_keys file. have send (the public key) banana pi?

edit#2: here adress less hidden 172.25.54.12 want connect mac banana pi , control server. mac client, , banana pi "host". when run

netstat -an | grep 22  tcp        0      0 0.0.0.0:22              0.0.0.0:*               listen       tcp6       0      0 :::22                   :::*           listen       udp        0      0 0.0.0.0:32622           0.0.0.0:*       unix  3      [ ]         stream     connected     4122       unix  3    [ ]         stream     connected     2922     @/tmp/.x11-unix/x0 

basically did is, followed tutorial on internet (like 1 https://www.youtube.com/watch?v=0wn44mbxtzw) not work.

edit#3: tried pc , putty, , have got error: network error: network unreachable.

maybe can help.

edit#4

ok understood part of problem: thought possible connect directly 2 devices without using local network. mean directly connect banana pi mac 1 ethernet cable. goal able connect banana pi when not connected network (is thath possible?), want use static ip address, idea?

ok, found way wanted do. means connect directly mac banana pi ethernet cable (cross on ethernet cable). edited network interface doing:

gedit /etc/network/interfaces 

and modified file way

#interfaces (5) file used ifup(8° , ifdown(8) auto lo iface lo inet loopback  #dhcp configuration allow-hotplug eth0 #iface eth0 inet dhcp #static ip configuration auto eth0 iface eth0 inet static adress 169.x.y.z netmask 255.255.255.0 gateway 169.x.y.* 

so address put ip similar mac ip adress (to mac ip address run ipconfig getifaddr en0) , gateway put mac ip address.

then connected 2 devices cross on ethernet cable. , in mac terminal ran:

bananapi@169.x.y.*

and worked!

thank you


Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -