Linux下bash: scp: command not found问题 或者装ssh包时报错 Requires: libedit.so.0()(64bit)

   

一、用scp命令从物理主机向CentOS 6.1虚拟机传送文件,提示以下错误:
bash: scp: command not found
到CentOS 6.1虚拟机查看也缺少scp命令。
该虚拟机是同事安装的,还有其他命令也不完整,可能不是完整安装,缺了些包。

二、用以下方法解决:

1、在一台完整的CentOS 5.8查找scp所在的包:
# which scp
/usr/bin/scp
# rpm -qf /usr/bin/scp
openssh-clients-4.3p2-82.el5

2、查出是属于openssh-clients包后,插入CentOS 6.1系统光盘,挂载后找到openssh-clients,安装时提示:
libedit.so.0()(64bit) is needed by openssh-clients-5.3p1-52.el6.x86_64

需要先安装libedit,再安装openssh-clients
# rpm -ivh cdrom/Packages/libedit-2.11-4.20080712cvs.1.el6.x86_64.rpm
warning: cdrom/Packages/libedit-2.11-4.20080712cvs.1.el6.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID c105b9de: NOKEY
Preparing...                ########################################### [100%]
   1:libedit                ########################################### [100%]
# rpm -ivh cdrom/Packages/openssh-clients-5.3p1-52.el6.x86_64.rpm
warning: cdrom/Packages/openssh-clients-5.3p1-52.el6.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: NOKEY
Preparing...                ########################################### [100%]
   1:openssh-clients        ########################################### [100%]

3、也可以通过以下命令直接安装:
# yum install openssh-clients

时间: 2024-08-10 21:18:41

Linux下bash: scp: command not found问题 或者装ssh包时报错 Requires: libedit.so.0()(64bit)的相关文章

Linux 下 -bash: mysql: command not found解决办法

-bash: mysql: command not found 1.vim ~/.bash_profile 最下面写 export PATH=$PATH:/usr/local/mysql/bin(你的安装bin目录) :wq 保存退出 2.source ~/.bash_profile 然后就直接可以实现了 给分吧 亲自试验过 3. >>mysql  -uroot -p >>输入密码

Linux bash: scp: command not found的问题记录

1,scp报错 [[email protected] soft]# scpjdk-7u55-linux-x64.tar.gz 192.168.121.246:/soft/ [email protected]'s password: bash: scp: command not found lost connection [[email protected] soft]# 2,调试-v [[email protected] soft]# scp -vjdk-7u55-linux-x64.tar.g

bash: scp: command not found

现在需要远程复制源码包使用scp命令:[[email protected] Downloads]# scp nginx-1.6.2.tar.gz 172.25.16.2:[email protected]'s password:      bash: scp: command not found       //提示错误lost connection//解决方法:[[email protected] Downloads]# which scp/bin/scp[[email protected]

linux下用scp命令在两个服务器之间传输文件,利用php_scp函数进行文件传输

在linux下利用scp进行文件传输, 从服务器下载文件 scp [email protected]:/path/filename /path/filename 上传本地文件到服务器 scp /path/filename [email protected]:/path/filename 从服务器下载整个目录 scp -r [email protected]:remote_dir/ /path/ 上传目录到服务器       scp -r /dir [email protected]:remote

linux下Bash编程组合测试及编写脚本(五)

linux下Bash编程组合测试及编写综合脚本(五) 1.Bash编程组合测试条件 -a: 与关系 -o: 或关系 !: 非关系 表示方法1:[ $# -gt 100 -a $# -le 500 ] 表示方法2:[ $# -gt 100 ] && [ $# -le 500 ] 2.编写一个任意添加与删除用户的脚本,要求如下: 2.1:如果脚本选项是--add:,将添加用户; 如果选项是--del,将删除用户,如果是--help显示帮助信息 2.2:脚本选项后面的参数可任意指定多个用户并且用

linux下Bash编程循环语句特殊用法之编写脚本(十)

linux下Bash编程while语句特殊用法之编写脚本(十) 1.循环控制: break:中断整个循环语句,即退出循环后执行脚本后面的语句 continue:中断当前本次循环,提前进入下一轮循环 exit:结束脚本运行 2.while死循环,即当不知道循环多少次时 格式 : while :; do 循环语句 done 3.while从输入重定向文件中每行读取并赋值给read变量 格式:  while read LINE;do 循环语句 done < 路径文件 4.实例脚本 4.1.找出/etc

linux下bash配置文件詳解

linux下bash配置文件 1.bash的配置文件: 全局配置:/etc/profile, /etc/profile.d/*.sh, /etc/bashrc 个人配置:~/.bash_profile, ~/.bashrc profile类的文件: 设定环境变量 运行命令或脚本 bashrc类的文件: 设定本地变量 定义命令别名 2. 登录式shell读取配置文件順序如下: /etc/profile --> /etc/profile.d/*.sh --> ~/.bash_profile --&

bash: scp: command not found lost connection问题解决

在内网,从一台服务器传mysql的源码安装包到另外一台服务器时,发生如下的错误: [root @localhost ~]# scp mysql-5.1.55.tar.gz [email protected]:. [email protected]'s password: bash: scp: command not found lost connection 提示scp的命令找不到,但是查找发现命令是存在的 [root @localhost ~]# whereis scp scp: /usr/b

解决scp时报bash: scp: command not found的错误

在进行scp时报bash: scp: command not found [[email protected] add_admin]# scp ocp_admin_privileges.mysql [email protected]:/root[email protected]'s password: bash: scp: command not foundlost connection 查看本机是否安装openssh-clients软件包 [[email protected] add_admi