Openldap : overlay accesslog not found - overlay

I am trying to configure accesslog. I have changed the slapd.conf file and trying to test using slaptest but i am getting error while executing slaptest -f /etc/openldap/slapd.conf.
slapd.conf configuration:
# See slapd.conf(5) for details on configuration options.
# This file should NOT be world readable.
include /etc/openldap/schema/core.schema
include /etc/openldap/schema/cosine.schema
include /etc/openldap/schema/inetorgperson.schema
include /etc/openldap/schema/nis.schema
.
.
modulepath /usr/lib/openldap/
moduleload accesslog.la
overlay accesslog
logdb "cn=accesslog"
logops writes
logsuccess TRUE
I am getting error at overlay accesslog
overlay "accesslog" not found
slaptest: bad configuration file!
Am I missing something..?

I found the issue on my own. I have not compiled the openldap with --enable overlay.
To solve this issue
i have downloaded the openldap src
./configure --enable-overlays (./configure [options] [variable=value ...])
Now modify the slapd.conf to load accesslog.la and execute slaptest -f /etc/openldap/slapd.conf. Now you wont find any error.
restart the slapd.

Related

Yocto: Data file clashes build error while enabling libvirt

While enabling libvirt in yocto, I am seeing below data file clash issue while building yocto image,
Below are the packages I am trying to append install to my yocto image
IMAGE_INSTALL_append = " \
packagegroup-core-boot \
qemu \
libvirt \
libvirt-libvirtd \
libvirt-virsh \
kernel-module-kvm \
kernel-module-kvm-intel \
"
But I see below issue, when I build image enabling above packages,
`Collected errors:
check_data_file_clashes: Package iptables wants to install file /-/-/-/rootfs/etc/ethertypes
But that file is already provided by package * ebtables`
FYI: I see that libvirt has both iptables and ebtables dependency.
can someone help on understanding this and how to resolve?
I tried to remove ebtables with PACKAGECONFIG_remove = "ebtables" and image is built but I when starting libvirtd service it is always in dead mode and I see some issue related to socket.
Actually, this is a problem that has no solution except:
Remove one of the packages (ebtables or iptables)
Remove the file ethertypes from one of the recipes
libvirt depends on iptables on compile time only, so I did not know why iptables is present in the image ?
Anyways, it has a config on ebtables and from your comment when you removed it from PACKAGECONFIG it failed to work. So:
I suggest check if iptables is required by other package at run time, if not remove it.
If both are required in your case, then go for the second solution which is removing the file from one of the recipes, using a bbappend file for one of them:
The block that you may need to add is:
do_install_append() {
rm ${D}/etc/ethertypes
}
either to:
meta-custom/recipes-filter/ebtables/ebtables_%.bbappend
or to:
meta-custom/recipes-extended/iptables/iptables_%.bbappend
NOTE
If you go for the second solution, you need to make sure that the file is not present in the FILES variable of the recipe that you will remove the file from, FILES_ebtables or FILES_iptables.

Include systemd-journal-remote with Bitbake

I am using an embedded Linux system based on Yocto/Open Embedded Linux and the systemd-journald-remote program is missing.
When I look at the systemd recipe the program is mentioned. It seems like it is not compiled or added by default to the image. I understand how to add normal recipes but unfortunately I don't understand how to add such a "subpackage".
The Bitbake documentation is unfortunately overwhelming for a beginner like me. Can someone help me?
Create bbappend for systemd in your meta-layer with following path recipes-core/systemd/systemd_%.bbappend and:
PACKAGECONFIG_append = " \
microhttpd \
"
You can add it into your image .bb or .bbappend file with following parameter:
IMAGE_INSTALL += "systemd-journal-remote"
This will add systemd-journal-remote into your image. Install the image on your target board, log in to your target and configure the file /etc/systemd/journal-remote.conf.
Then, enable the service with systemctl enable systemd-journal-remote, and then restart it with systemctl restart systemd-journal-remote.

Installing php extension for SQL Anywhere on server with CentOS, Plesk, php-fpm

we got a new WebServer with CentOS, Plesk and php-fpm.
Now we don't get the php extension running.
What we did:
installed latest SQL Anywhere 17 (ebf29577)
copied php-7.3.0_sqlanywhere_r.so to /opt/plesk/php/7.3/lib64/php/modules/
loading php-7.3.0_sqlanywhere_r.so via /opt/plesk/php/7.3/etc/php.d/sqlanywhere.ini
this leads to an error:
WARNING: [pool plesk-php73-fpm.plesk-service.localdomain] child 11616 said into stderr: "NOTICE: PHP message: PHP Warning: request_startup() for sqlanywhere module failed in Unknown on line 0"
(This leads to php 7.3 fpm is not loading at all)
next try was to switch from FPM to CGI: same error
module is loadable itself within shell if LD_LIBRARY_PATH was enhanced with path /opt/sqlanywhere17/lib64/
some tries getting the cause by strace did not help
Has anybody an idea or maybe even successfully installed php extension.
Thanks
Florian
after a lot of tests we found a solution:
in Plesk Domain php settings we had to add:
[php-fpm-pool-settings]
env[LD_LIBRARY_PATH]="/opt/sqlanywhere_v2/lib64:$LD_LIBRARY_PATH"
Now all libs are found and it works
For me solution was, creating custom handler:
plesk bin php_handler --add -displayname "PHP SQLAnywhere 7.4" -path /opt/php-custom-handlers/7.4/php-sqlanywhere.fcgi -clipath /opt/plesk/php/7.4/bin/php -phpini /opt/plesk/php/7.4/etc/php.ini -type fastcgi
php-sqlanywhere.fcgi contents:
#!/bin/bash
LD_LIBRARY_PATH=/opt/sqlanywhere17/lib64
export LD_LIBRARY_PATH
exec /opt/plesk/php/7.4/bin/php-cgi "$#"
And finally using this handler on domain php settings and adding on additional directives:
extension=sqlanywhere.so

Config file missing when running Confluent Platform

When I start confluent platform I get an error [ERROR] unable to load config: unable to parse config file: /home/user/.confluent/config.json: unexpected end of JSON input. There is no file in the path shown in the error.
Unexpected EOF would suggest the file is present. .confluent directory is hidden, so it's not clear how you've checked if the file exists.
Try ls -laR~/.confluentorfind $HOME -name config.json`...
In any case, kafka-server-start should work fine, and I suggest using it

Unable to set HomePath And config in grafana

I am new to grafana and I am getting this error while executing the grafana-server.exe
Grafana-server Init Failed: Could not find config defaults, make sure homepath command line parameter is set or working directory is homepath
Firstly, I am not clear about which path to specify as homepath and which to specify as config path.
Secondly, I have tried to set the homepath using this command:
grafana-cli admin reset-admin-password --homepath "c:\" mynewpassword
But getting this error :
"Incorrect Usage: flag provided but not defined: -homepath"
in grafana version 7.3.5 this is the help message.
NAME:
Grafana CLI - A new cli application
USAGE:
grafana-cli [global options] command [command options] [arguments...]
VERSION:
7.3.5
AUTHOR:
Grafana Project <hello#grafana.com>
COMMANDS:
plugins Manage plugins for grafana
admin Grafana admin commands
help, h Shows a list of commands or help for one command
GLOBAL OPTIONS:
--pluginsDir value Path to the Grafana plugin directory (default: "/var/lib/grafana/plugins") [$GF_PLUGIN_DIR]
--repo value URL to the plugin repository (default: "https://grafana.com/api/plugins") [$GF_PLUGIN_REPO]
--pluginUrl value Full url to the plugin zip file instead of downloading the plugin from grafana.com/api [$GF_PLUGIN_URL]
--insecure Skip TLS verification (insecure) (default: false)
--debug Enable debug logging (default: false)
--configOverrides value Configuration options to override defaults as a string. e.g. cfg:default.paths.log=/dev/null
--homepath value Path to Grafana install/home path, defaults to working directory
--config value Path to config file
--help, -h show help (default: false)
--version, -v print the version (default: false)
so you can set it by passing --homepath .
be careful, it seems its diffrent with grafana-server parametes. in that case you must set flag with only 1 hyphen (-homepath)
but come back to your problem there is 2 things to say.
first is to order your command correctly. i mean something like this
grafana-cli --homepath path ...
because homepath flag is for grafana-cli so it must come right after that or there will not be any guarantee of "what you want to do is what you write".
second is the homepath. consider this tree directory
.
|_LICENSE
|_NOTICE.md
|_README.md
|_VERSION
|_bin
|_conf
|_data
|_plugin-bundled
|_public
|_scripts
here is installation directory or homepath which you must set. more specifically exacly around bin(or conf or data or ...) directory.