/*************************************************************************
* 响应: 500 OOPS: priv_sock_get_int 错误: 读取目录列表失败
* 说明:
* 使用了Android的Kernel来做Linux系统开发,自己搭的文件系统运行vsftp出现
* 500 OOPS: priv_sock_get_int报错,原因是Android内核检查机制导致的。
*
* 2017-10-11 深圳 南山平山村 曾剑锋
************************************************************************/ 一、参考文档:
. vsftpd 服务移植出现 oops : socket 解决
http://www.cnblogs.com/chenfulin5/p/6912706.html 二、解决办法:
. cat net/ipv4/af_inet.c
...
#ifdef CONFIG_ANDROID_PARANOID_NETWORK
#include <linux/android_aid.h> static inline int current_has_network(void)
{
return in_egroup_p(AID_INET) || capable(CAP_NET_RAW);
}
#else
static inline int current_has_network(void)
{
return ;
}
#endif
...
. make menuconfig
.config - Linux/arm 3.0. Kernel Configuration
──────────────────────────────────────────────────────────────────────────────
┌────────────────────────── Networking options ───────────────────────────┐
│ Arrow keys navigate the menu. <Enter> selects submenus --->. │
│ Highlighted letters are hotkeys. Pressing <Y> includes, <N> excludes, │
│ <M> modularizes features. Press <Esc><Esc> to exit, <?> for Help, </> │
│ for Search. Legend: [*] built-in [ ] excluded <M> module < > │
│ ┌────^(-)─────────────────────────────────────────────────────────────┐ │
│ │ [ ] TCP: advanced congestion control ---> │ │
│ │ [ ] TCP: MD5 Signature Option support (RFC2385) (EXPERIMENTAL) │ │
│ │ < > The IPv6 protocol ---> │ │
│ │ [ ] Only allow certain groups to create sockets <---- 修改这里 | │
│ │ [*] Network activity statistics tracking │ │
│ │ [ ] Security Marking │ │
│ │ [ ] Timestamping in PHY devices │ │
│ │ [ ] Network packet filtering framework (Netfilter) ---> │ │
│ │ < > The DCCP Protocol (EXPERIMENTAL) ---> │ │
│ └────v(+)─────────────────────────────────────────────────────────────┘ │
├─────────────────────────────────────────────────────────────────────────┤
│ <Select> < Exit > < Help > │
└─────────────────────────────────────────────────────────────────────────┘
. 编译报错:
...
security/commoncap.c: In function 'cap_capable':
security/commoncap.c::: error: 'AID_NET_RAW' undeclared (first use in this function)
security/commoncap.c::: note: each undeclared identifier is reported only once for each function it appears in
security/commoncap.c::: error: 'AID_NET_ADMIN' undeclared (first use in this function)
make[]: *** [security/commoncap.o] Error
make: *** [security] Error
...
. 解决编译报错:
cat security/commoncap.c
...
int cap_capable(struct task_struct *tsk, const struct cred *cred,
struct user_namespace *targ_ns, int cap, int audit)
{
/*
if (cap == CAP_NET_RAW && in_egroup_p(AID_NET_RAW))
return 0;
if (cap == CAP_NET_ADMIN && in_egroup_p(AID_NET_ADMIN))
return 0;
*/
...
}
...

响应: 500 OOPS: priv_sock_get_int 错误: 读取目录列表失败的更多相关文章

  1. [linux]解决vsftpd 读取目录列表失败的问题

    使用第三方FTP软件filezilla进行登陆,出现如下错误:状态:    正在连接 192.168.1.6:21...状态:    连接建立,等待欢迎消息...响应:    220 (vsFTPd ...

  2. FileZilla 错误425 Can't open data connection 读取目录列表失败

    新装FileZilla FTP Server,设置好后,客户端能连接,但是出Error:[读取目录列表失败]:同时,服务端出Error:[425 Can't open data connection] ...

  3. FTP软件Filezilla出现“读取目录列表失败”的解决办法

    FTP软件Filezilla出现“读取目录列表失败”情况一般出现在vista/win7系统上,之前在xp上没发现这种情况. 总的来说,不论是打开FTP出现乱码或者显示“读取目录列表失败”均是由字符集引 ...

  4. 解决vsftpd 2.2.2读取目录列表失败的问题

    该错误是由iptables的配置引起的,临时的解决方法是执行如下命令: [root@localhost soft]# modprobe ip_nat_ftp 再次登陆列表正常啦! 但当你重新启动服务器 ...

  5. ftp 读取目录列表失败

    在防火墙设置的“例外”选项卡中添加程序: C:\WINDOWS\system32\inetsrv\inetinfo.exe,确定即可!

  6. FTP 150 Opening BINARY mode data connection for MLSD 读取目录列表失败

    这完全是因为防火墙的问题,把服务器的防火墙关闭之后,在连接,一切ok

  7. filezilla pureftpd 读取目录列表失败

    放行   21, 39000 - 40000端口

  8. 响应: 500 OOPS: vsftpd: refusing to run with writable root inside chroot()

    原vsftpd服务器的系统从centos6.8升级到centos7.2.vsftpd使用yum方式安装,用户采用系统用户登录.由于系统升级到centos7,yum安装的vsftpd版本改变.因此按ce ...

  9. TP6 服务器响应500时没有错误信息的解决方案

    重点!!!! 首先,确认你的电脑管理员账户是否含有中文!!!!!!就像下面这种:所以出现了没有错误提示    查看nginx日志显示\vendor\topthink\framework\src\thi ...

随机推荐

  1. PAT 1128 N Queens Puzzle[对角线判断]

    1128 N Queens Puzzle(20 分) The "eight queens puzzle" is the problem of placing eight chess ...

  2. with语句与__enter__,__exit__

    class Foo(object): def func(self): print("func") pass def __enter__(self): print("ent ...

  3. 5.8 Components — Composing Components(组合组件)

    一.概述 当你通过和另外一个组件组合的时候,组件就会真正发挥它们的所有潜能.比如<ul>元素,只有<li>元素是适合作为它的子元素的.如果我们希望同样类型的行为,那么我们就必须 ...

  4. xgboost 自定义评价函数(metric)与目标函数

    比赛得分公式如下: 其中,P为Precision , R为 Recall. GBDT训练基于验证集评价,此时会调用评价函数,XGBoost的best_iteration和best_score均是基于评 ...

  5. Ubuntu 添加用户到 sudoer

    一.概述 新建用户后,我们可能需要该用户能够使用一些越权的东西.sudo命令能够暂时提升该用户的权限到root,但是前提是要求该用户存在与 sudoer list 中. sudoers 存储在 /et ...

  6. Jedis连接池

    jedis是官方首选的java客户端开发包 Redis不仅是使用命令来操作,现在基本上主流的语言都有客户端支持,比如java.C.C#.C++.php.Node.js.Go等. 在官方网站里列一些Ja ...

  7. bzoj1603 / P2913 [USACO08OCT]车轮旋转Wheel Rotation

    P2913 [USACO08OCT]车轮旋转Wheel Rotation 稳妥起见(防止数据出锅),用了bfs 每次的转移可以直接用异或和解决. #include<iostream> #i ...

  8. vSphere Client开启虚拟机提示:出现了常规系统错误: 由于目标计算机积极拒绝,无法连接。

    进入VCenter Server服务器上 进入服务管理器,查看 VMware vCenter workflow manager 是否启动,如未启动,则改为启动,问题得以解决 再次启动虚拟机,已启动!

  9. poj 2828 Buy Tickets 树状数组

    Buy Tickets Description Railway tickets were difficult to buy around the Lunar New Year in China, so ...

  10. 为什么要使用MQ消息中间件?它解决了什么问题?

    1.应用场景 1.1 异步处理 场景说明:用户注册后,需要发注册邮件和注册短信,传统的做法有两种1.串行的方式;2.并行的方式 (1)串行方式:将注册信息写入数据库后,发送注册邮件,再发送注册短信,以 ...