Warning: Identity file /root/.ssh/identity.pub does not exist.
I have copy the id_ras.pub as authorized_hosts2 in the other server.
my /etc/ssh/sshd_config ( source server)
# $OpenBSD: sshd_config,v 1.34 2001/02/24 10:37:26 deraadt Exp $
# This sshd was compiled with PATH=/usr/bin:/bin:/usr/sbin:/sbin
# This is the sshd server system-wide configuration file. See sshd(8)
# for more information.
Port 22
Protocol 2,1
#ListenAddress 0.0.0.0
#ListenAddress ::
HostKey /etc/ssh/ssh_host_key
HostKey /etc/ssh/ssh_host_rsa_key
HostKey /etc/ssh/ssh_host_dsa_key
ServerKeyBits 768
LoginGraceTime 600
KeyRegenerationInterval 3600
PermitRootLogin yes
#
# Don't read ~/.rhosts and ~/.shosts files
IgnoreRhosts yes
# Uncomment if you don't trust ~/.ssh/known_hosts for RhostsRSAAuthentication
#IgnoreUserKnownHosts yes
StrictModes yes
X11Forwarding yes
X11DisplayOffset 10
PrintMotd yes
KeepAlive yes
# Logging
( I read the old text from library, and began to realize about the hosts.allow, I thought I can solved the whole problem, in fact I am searching glue or hints to do scp across the internet.
I tried /etc/hosts.allow in the opposite server ie to test scp across the internet with
ALL: ALL : ALLOW, no luck too.
my scp -script:
#! /bin/sh
rm -f /root/.ssh/scp.log
clear
s_date=`date`
echo "Start at ${s_date}" > scp.log
echo "I am in 192.168.1.80 doing Secure copy (SCP): your source files is from (web-server)"
echo "Check from /root/.ssh/scp.log, please wait until I completed the scp ..."
rm -R -f /home/save/redhat7.1
email="a_user@mydomain.com"
date1=`date`
#Copy everything from the sites directory on the server
/usr/bin/scp -c 3des -4 -v -r -P 22 -i /root/.ssh/identity.pub
root@w.xy.z:/var/www/html/redhat7.1/webhotels /home/save/ >> /root/.ssh/scp.log 2>&1
#/usr/bin/scp -c 3des -4 -v -r -P 22 -i /root/.ssh/identity.pub
root@mydomain.com:/home/a_user/scp-test /home/save >> /root/.ssh/scp2.log 2>&1
date2=`date`
echo "completed at ${date2}" >> scp.log
echo -e "SCP backup start: ${date1}\nbackup ended: ${date2}" | mail -s "SCP completed" ${email}
exit 0
my setting for internal scp sometimes is ok and sometimes connection on mac is discrupted. ( ie some error there-
Disconnecting: Corrupted MAC on input.
lost connection ).
is the protocol 2 in /etc/ssh/sshd_config mean ssh2?