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. js高程笔记1-3章

    第1章 js简介 1.js由三部分组成,ECMAScript, DOM, BOM. 第2章 在HTML中使用js 1.把<script>标签放在<body>里面的最后,可以在加 ...

  2. HTML文件中使用Java程序

    HTML文件中使用Java程序:简而言之,在HTML文件中引入java应用程序,并通过javascript调用其方法.   一. 运行环境 1.JAVA_HOME.CLASSPATH.PATH配置正确 ...

  3. cicm0804吊起

    CICS调用方法:cicslterm -r RGCIPS /////////////// CECI LINK P(CICM0804) COMM(F0000000000000000000006) --- ...

  4. js 求前n项的 fibnaci 数列和

    function f(n) { var num1 = 1, num2 = 1; if (n == 1) document.write(num1);//n=1,输出1 else if (n > 1 ...

  5. 为一个有数据没有主键id的数据表添加主键字段

    ALTER TABLE `photo_feedbacks` ADD COLUMN `id`  int(11) NOT NULL AUTO_INCREMENT FIRST ,ADD PRIMARY KE ...

  6. iOS界面布局设计

    参考资料: 1. 谈谈如何学习ios 8的界面和布局设计 2. iOS 8 Auto Layout界面布局系列 3. 为iPhone 6设计自适应布局 4. 几张图弄明白iOS布局中的尺寸问题

  7. Android BroadcasetReceiver

    ci@clinux:~/mp_mtk$ adb -s QGAEFYAAOFN7PNOB logcat PhoneReceiver:e *:S --------- beginning of system ...

  8. HTML5-Geolocation&地图.html

    <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" content ...

  9. 关于ionic的跨域问题

    例如你的api原地址请求是 http://10.100.100.100:8080/service/, 1.那么你应该在项目内api请求改成 /service/, 注意红色部分是ionic serve ...

  10. hadoop架构

    HADOOP中可以分为两个大的模块,存储模块和计算模块.HDFS作为存储模块,JobTracker,TaskTracker构成计算模块.   1.HADOOP的文件是以HDFS格式存储的   HDFS ...