SELinux和maxent

maxent是我们的系统用最大熵做关键字提取时用到的一个库。今天上午查看系统日志的时候,发现有一个SELinux的报警:
Apr  3 04:57:49 nserver setroubleshoot:      SELinux is preventing /usr/local/bin/python from loading /usr/local/lib/python2.5/site-packages/maxent/_cmaxent.so which requires text relocation.      For complete SELinux messages. run sealert -l 6c940625-07c7-4f49-87a5-8f06b9361590

执行sealert -l 6c940625-07c7-4f49-87a5-8f06b9361590看到的详细信息如下:
Summary
    SELinux is preventing /usr/local/bin/python from loading
    /usr/local/lib/python2.5/site-packages/maxent/_cmaxent.so which requires
    text relocation.

Detailed Description
    The /usr/local/bin/python application attempted to load
    /usr/local/lib/python2.5/site-packages/maxent/_cmaxent.so which requires
    text relocation.  This is a potential security problem. Most libraries do
    not need this permission. Libraries are sometimes coded incorrectly and
    request this permission.  The http://people.redhat.com/drepper/selinux-
    mem.html web page explains how to remove this requirement.  You can
    configure SELinux temporarily to allow /usr/local/lib/python2.5/site-
    packages/maxent/_cmaxent.so to use relocation as a workaround, until the
    library is fixed. Please file a
    http://bugzilla.redhat.com/bugzilla/enter_bug.cgi against this package.

Allowing Access
    If you trust /usr/local/lib/python2.5/site-packages/maxent/_cmaxent.so to
    run correctly, you can change the file context to textrel_shlib_t. "chcon -t
    textrel_shlib_t /usr/local/lib/python2.5/site-packages/maxent/_cmaxent.so"

    The following command will allow this access:
    chcon -t textrel_shlib_t /usr/local/lib/python2.5/site-packages/maxent/_cmaxent.so

可能是maxent的Python Wrapper的问题吧。按提示执行了chcon -t textrel_shlib_t /usr/local/lib/python2.5/site-packages/maxent/_cmaxent.so,回头再看看

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值