command-line: line 0: Bad configuration option: PermitLocalCommand

2011-12-08 14:04:54

废话少说,问题描述与解决

今天在一server上传输文件时,遇到scp error

[root@server01 ~]# scp aa.txt  root@192.168.0.1:/home/software/

command-line: line 0: Bad configuration option: PermitLocalCommand

lost connection

刚发现此问题时,还以为是sshd服务问题,将sshd重启后,问题依旧,查了些资料,说是sshd的配置文件问题,从其它server上拷贝文件,重启sshd服务,问题依旧,纠结。。。

之后将openssh的clients包重安装下,报如下错误:

[root@server228 software]# rpm -ivh openssh-clients-4.3p2-29.el5.x86_64.rpm

Preparing...                ########################################### [100%]

1:openssh-clients        ########################################### [100%]

error: unpacking of archive failed on file /usr/bin/ssh: cpio: rename failed - 不允许的操作

由此可见是/usr/bin/ssh出现异常

此时,查看/usr/bin/ssh的详细信息,当看到权限和属性时,发现

[root@server01 bin]# lsattr ssh

-u--ia------- ssh

此时看到这个属性,心中就有疑问了,于是找了其他server上的ssh程序权限和属性看了一下,。

[root@server46 ~]# lsattr /usr/bin/ssh

------------- /usr/bin/ssh

于是将01server上的ssh属性将uia去掉,命令:

chattr -uia /usr/bin/ssh

再重启sshd服务,问题即可解决!

Bad configuration option localCommand的更多相关文章

  1. PECL: configuration option "php_ini" is not set to php.ini location

    message similar to: configuration option "php_ini" is not set to php.ini locationYou shoul ...

  2. ssh: Bad configuration option: usedns

    某天突然听到同事说服务器上git用不了了,上去一看,确实用不了了,git pull报出了如下错误: $ git pull /etc/: Bad configuration option: usedns ...

  3. clr enabled Server Configuration Option

    在SQL Server中启用CLR,可以执行下面SQL语句: EXEC sp_configure 'clr enabled'; '; RECONFIGURE; Source Code

  4. Elasticsearch Configuration 中文版

    ##################### Elasticsearch Configuration Example ##################### # This file contains ...

  5. P6 EPPM Installation and Configuration Guide 16 R1 April 2016

    P6 EPPM Installation and Configuration Guide 16 R1         April 2016 Contents About Installing and ...

  6. P6 Professional Installation and Configuration Guide (Microsoft SQL Server Database) 16 R1

    P6 Professional Installation and Configuration Guide (Microsoft SQL Server Database) 16 R1       May ...

  7. Laravel Configuration

    Introduction All of the configuration files for the Laravel framework are stored in the app/config d ...

  8. [转] Spring - Java Based Configuration

    PS: Spring boot注解,Configuration是生成一个config对象,@Bean指定对应的函数返回的是Bean对象,相当于XML定义,ConfigurationProperties ...

  9. odoo view field option, action flage 参数

    options JSON object specifying configuration option for the field's widget (including default widget ...

随机推荐

  1. 《JavaScript高级程序设计》心得笔记-----第一篇章

    第一章 JavaScript由ECMAScript.DOM.BOM组成.其中BOM功能在HTML5中有了正式的规范,使BOM的兼容性越来越高. 第二章 1.<script>属性中的asyn ...

  2. ASP.NET MVC强制返回XML

    GlobalConfiguration.Configuration.Formatters.Remove(config.Formatters.JsonFormatter);

  3. 死亡之ping(Ping of Death)

    最简单的基于IP的攻击可能要数著名的死亡之ping,这种攻击主要是由于单个包的长度超过了IP协议规范所规定的包长度.产生这样的包很容易,事实上,许多操作系统都提供了称为ping的网络工具.在为Wind ...

  4. JVM基础知识总结

    因为没深入搞底层研究,所以也就没做很细致的笔记.相关笔记内容是直接从度娘那儿来的,重新删减.整理和加了点自己的东西. 1.JVM(Java Virtual Machine)是什么:JVM是一种用于计算 ...

  5. 第一章 C++简介

    第一章  C++简介 1.1  C++特点 C++融合了3种不同的编程方式:C语言代表的过程性语言,C++在C语言基础上添加的类代表的面向对象语言,C++模板支持的泛型编程. 1.2  C语言及其编程 ...

  6. 初测WIN10

    WIN10已经发布,通过百度直通车把WIN7升级成了WIN10,改变较大,不太习惯,用着不是很顺手. 吐槽几个问题 1.微软的Visual Studio 2015 Community版本,宣布是免费的 ...

  7. JVM学习---JAVA内存

    一.JAVA运行时数据区域:JAVA中的运行时内存区域有的随着虚拟机进程的启动而存在,有的区域则是依赖用户线程的启动和结束而建立和销毁的.包括以下的几个区域. 图. JAVA虚拟机运行时数据区 1.程 ...

  8. 我的第一个MVC4程序

    InputExtensions 方法解释 http://blog.csdn.net/cnceohjm/article/details/8936669 https://msdn.microsoft.co ...

  9. Oracle bbed使用说明1

    一.centos上编译安装BBED工具 [orasrv@localhost ~]$ cd $ORACLE_HOME/rdbms/lib [orasrv@localhost ~]$ make -f in ...

  10. Oracle 表的连接方式(1)-----Nested loop join和 Sort merge join

    关系数据库技术的精髓就是通过关系表进行规范化的数据存储,并通过各种表连接技术和各种类型的索引技术来进行信息的检索和处理. 表的三种关联方式: nested loop:从A表抽一条记录,遍历B表查找匹配 ...