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. BigInteger大数家法源代码及分析

    我们可以把一个很大很长的数分成多个短小的数,然后保存在一个数组中,大数之间的四则运算及其它运算都是通过数组完成.JDK就是这么实现的.JDK的BigInteger类里用一个int数组来保存数据: /* ...

  2. 十个最常见的Java字符串问题

    翻译自:Top 10 questions of Java Strings 1.怎样比较字符串?用”==”还是用equals()? 简单地说,”==”测试两个字符串的引用是否相同,equals()测试两 ...

  3. MVC5_学习笔记_1_CodeFirst

    MVC5_EF6_1/* GitHub stylesheet for MarkdownPad (http://markdownpad.com) *//* Author: Nicolas Hery - ...

  4. 启语外语培训网SEO历程

    网站开发完成已经好长时间了,但收录一直上不去,排名也上不去.我这篇文章主要是分析一下网站的SEO历程 网址:http://waiyupx.cheer-edu.net/School/School-5.h ...

  5. google查询技巧

    技巧一:使用正确的方法 无论你是使用一个简单或是高级的Google搜索,在此都存在你应该使用的某种可靠的方法.遵循适当的方法你就能获得非常准确的结果:要是忽略这条建议的话,你也许就会看到大量不相关的结 ...

  6. openerp学习笔记 计算字段支持搜索

    示例1: # -*- encoding: utf-8 -*-import poolerimport loggingimport netsvcimport toolslogger = netsvc.Lo ...

  7. WPF编译时提示“...不包含适合于入口点的静态‘Main’方法 ...”

    今天看了一下wpf的Application类方面的知识,一个windows应用程序由一个Application类的实例表示,该类跟踪在应用程序中打开的所有窗口,决定何时关闭应用程序(属性 Shutdo ...

  8. Microsoft Virtual Academy 介绍

    Microsoft Virtual Academy 是微软的虚拟学院,会推出微软各个方面的一些教程 介绍一点有用的链接 http://www.microsoftvirtualacademy.com/e ...

  9. HTTP报文格式

    请求报文 <method><SP><uri><SP><version><CRLF> <head-name><: ...

  10. springboot pom 引用集合

    <dependency><groupId>com.google.code.gson</groupId><artifactId>gson</arti ...