AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / unix / 问题 / 742890
Accepted
j4nd3r53n
j4nd3r53n
Asked: 2023-04-14 18:07:42 +0800 CST2023-04-14 18:07:42 +0800 CST 2023-04-14 18:07:42 +0800 CST

如何在 slapd.d 中设置日志级别?

  • 772

我已经在 Debian 11 上设置了 openLDAP 2.4,我想更改一些参数,比如 loglevel 和 logfile,这看起来非常简单:

# man slapd.conf
SLAPD.CONF(5)                                                       File Formats Manual                                                      SLAPD.CONF(5)

NAME
       slapd.conf - configuration file for slapd, the stand-alone LDAP daemon

SYNOPSIS
       /etc/ldap/slapd.conf

DESCRIPTION
       The  file /etc/ldap/slapd.conf contains configuration information for the slapd(8) daemon.  This configuration file is also used by the SLAPD tools
       slapacl(8), slapadd(8), slapauth(8), slapcat(8), slapdn(8), slapindex(8), and slaptest(8).
...
       logfile <filename>
              Specify a file for recording debug log messages. By default these messages only go to stderr and are not recorded anywhere else.  Specifying
              a logfile copies messages to both stderr and the logfile.

       loglevel <integer> [...]
              Specify  the level at which debugging statements and operation statistics should be syslogged (currently logged to the syslogd(8) LOG_LOCAL4
              facility).  They must be considered subsystems rather than increasingly verbose log levels.  Some messages with higher priority  are  logged
...

除了没有名为slapd.conf;的文件 它已被替换为/etc/ldap/slapd.d,这更加整洁。slapd.conf但是,我没有找到参数如何适应的描述/etc/ldap/slapd.d;有一个调用的参数olcLogLevel可能/etc/ldap/slapd.d/cn=config.ldif是一个参数,但是来自 的其他所有参数呢slapd.conf?

无论如何,我的问题是:如何更改新方案中的日志级别和日志文件?

openldap
  • 1 1 个回答
  • 15 Views

1 个回答

  • Voted
  1. Best Answer
    user1686
    2023-04-14T23:07:25+08:002023-04-14T23:07:25+08:00

    请参阅slapd-config(5)手册页。几乎所有设置都在 LDAP 配置后端中保留相同的名称,只是带有olc名称空间前缀。(而且您真的应该通过 LDAP 或至少通过 编辑这些内容slapmodify,而不是手动编辑。)

           olcLogFile: <filename>
                  Specify a file for recording slapd debug messages. By default these  mes‐
                  sages  only  go  to stderr, are not recorded anywhere else, and are unre‐
                  lated to messages exposed by  the  olcLogLevel  configuration  parameter.
                  Specifying a logfile copies messages to both stderr and the logfile.
    
           olcLogFileFormat: debug | syslog-utc | syslog-localtime
                  Specify  the prefix format for messages written to the logfile. The debug
    
           [...]
    
           olcLogLevel: <integer> [...]
                  Specify the level at which debugging statements and operation  statistics
                  should be syslogged (currently logged to the syslogd(8) LOG_LOCAL4 facil‐
    
    
    • 1

相关问题

  • openLDAP bdb_equality_candidates: (memberOf) 未编入索引

  • OpenLDAP 与 Active Directory 身份验证机制

  • ldap userCertificate 属性的问题

  • 如何使用 ldapscripts 中的 ldapmodifyuser 更改值

  • OpenDG 一个开源的 ldap 数据库处理和问题

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    模块 i915 可能缺少固件 /lib/firmware/i915/*

    • 3 个回答
  • Marko Smith

    无法获取 jessie backports 存储库

    • 4 个回答
  • Marko Smith

    如何将 GPG 私钥和公钥导出到文件

    • 4 个回答
  • Marko Smith

    我们如何运行存储在变量中的命令?

    • 5 个回答
  • Marko Smith

    如何配置 systemd-resolved 和 systemd-networkd 以使用本地 DNS 服务器来解析本地域和远程 DNS 服务器来解析远程域?

    • 3 个回答
  • Marko Smith

    dist-upgrade 后 Kali Linux 中的 apt-get update 错误 [重复]

    • 2 个回答
  • Marko Smith

    如何从 systemctl 服务日志中查看最新的 x 行

    • 5 个回答
  • Marko Smith

    Nano - 跳转到文件末尾

    • 8 个回答
  • Marko Smith

    grub 错误:你需要先加载内核

    • 4 个回答
  • Marko Smith

    如何下载软件包而不是使用 apt-get 命令安装它?

    • 7 个回答
  • Martin Hope
    user12345 无法获取 jessie backports 存储库 2019-03-27 04:39:28 +0800 CST
  • Martin Hope
    Carl 为什么大多数 systemd 示例都包含 WantedBy=multi-user.target? 2019-03-15 11:49:25 +0800 CST
  • Martin Hope
    rocky 如何将 GPG 私钥和公钥导出到文件 2018-11-16 05:36:15 +0800 CST
  • Martin Hope
    Evan Carroll systemctl 状态显示:“状态:降级” 2018-06-03 18:48:17 +0800 CST
  • Martin Hope
    Tim 我们如何运行存储在变量中的命令? 2018-05-21 04:46:29 +0800 CST
  • Martin Hope
    Ankur S 为什么 /dev/null 是一个文件?为什么它的功能不作为一个简单的程序来实现? 2018-04-17 07:28:04 +0800 CST
  • Martin Hope
    user3191334 如何从 systemctl 服务日志中查看最新的 x 行 2018-02-07 00:14:16 +0800 CST
  • Martin Hope
    Marko Pacak Nano - 跳转到文件末尾 2018-02-01 01:53:03 +0800 CST
  • Martin Hope
    Kidburla 为什么真假这么大? 2018-01-26 12:14:47 +0800 CST
  • Martin Hope
    Christos Baziotis 在一个巨大的(70GB)、一行、文本文件中替换字符串 2017-12-30 06:58:33 +0800 CST

热门标签

linux bash debian shell-script text-processing ubuntu centos shell awk ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve