MariaDB lacks a conf file? - mariadb

I have recently installed MariaDB on my server; however, it doesn't have the appropriate database settings for tweaking/tuning! Here is my "my.cnf":
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
#
# include all files from the config directory
#
!includedir /etc/my.cnf.d
Where are the other settings?? Such as thread, memory adjustment, etc.?

Add what you need. But generally you don't need any changes from the defaults until there is some kind of issue.

Related

I am using MariaDB 10 on Centos 7 and cannot find the [mysqld] section in my configuration file

Centos 7
MariaDB 10.6.11
Where can I find the [mysql] section in /etc/my.cnf file
This is all i found in /etc/my.cnf file
#
# This group is read both by the client and the server
# use it for options that affect everything
#
[client-server]
#
# include *.cnf from the config directory
#
!includedir /etc/my.cnf.d
I want to access database server remotely which is required to add bind-address = 0.0.0.0 in /etc/my.cnf file
bind-address is a server option and needs to be added in section [server],[mysqld] or [mariadbd]. Group [mysql] is a client section used e.g. by command line client.
See also: Server Option Groups
The line
!includedir /etc/my.cnf.d
states, that my.cnf reads all configuration files from the /etc/my.cnf.d directory.
So check the configuration files in this directory. If there aren't any configuration files or none of them contains a group which will be read by server, add a new file server.cnf in /etc/my.cnf.d and add the group with bind address.

Wsrep MariaDB Crash Thread pointer: 0x0

Cluster is constantly crashing.
Sometimes it works stable for 2 days. Sometimes five minutes after 2 servers stand.
server.cnf was tested with different parameters. The result did not change
When the setup is not installed, the single server is running without problems.
Clean installation several times.
iptables stop
selinux disable
yum repo
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.1/centos6-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
Centos 6.9 64bit
yum install MariaDB-server MariaDB-client
Erorr Log
/var/lib/mysql/maria1.err
180305 16:17:03 [ERROR] mysqld got signal 11 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
To report this bug, see https://mariadb.com/kb/en/reporting-bugs
We will try our best to scrape up some info that will hopefully help
diagnose the problem, but since we have already crashed,
something is definitely wrong and this may fail.
Server version: 10.1.31-MariaDB
key_buffer_size=134217728
read_buffer_size=131072
max_used_connections=5
max_threads=153
thread_count=2
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 467163 K bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
Thread pointer: 0x0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 0x0 thread_stack 0x48400
/etc/my.cnf.d/server.cnf
#
# These groups are read by MariaDB server.
# Use it for options that only the server (but not clients) should see
#
# See the examples of server my.cnf files in /usr/share/mysql/
#
# this is read by the standalone daemon and embedded servers
[server]
# this is only for the mysqld standalone daemon
[mysqld]
bind-address=0.0.0.0
skip-name-resolve
#
# * Galera-related settings
#
[galera]
# Mandatory settings
wsrep_on=ON
wsrep_provider=/usr/lib64/galera/libgalera_smm.so
wsrep_cluster_address="gcomm://10.1.1.11,10.1.1.12"
wsrep_cluster_name='galera_cluster'
wsrep_node_address='10.1.1.11'
wsrep_node_name='maria1'
wsrep_sst_method=rsync
wsrep_sst_auth=sst_user:!!PassWordSs!!
binlog_format=row
default_storage_engine=InnoDB
innodb_autoinc_lock_mode=2
#
# Allow server to accept connections on all interfaces.
#
#bind-address=0.0.0.0
#
# Optional setting
#wsrep_slave_threads=1
#innodb_flush_log_at_trx_commit=0
# this is only for embedded server
[embedded]
# This group is only read by MariaDB servers, not by MySQL.
# If you use the same .cnf file for MySQL and MariaDB,
# you can put MariaDB-only options here
[mariadb]
# This group is only read by MariaDB-10.1 servers.
# If you use the same .cnf file for MariaDB of different versions,
# use this group for options that older servers don't understand
[mariadb-10.1]
Test DB structure
Please report this crash to MariaDB bug tracker

Mariadb configure alloted memory

I want to allocate more memory to my MariaDB server but I am having difficulties in locating the right my.cnf file.
Basically I want to edit the innodb_buffer_pool_size
This is the content of the my.cnf file in /etc/my.cnf
[mysqld]
bind-address = ::
skip_name_resolve
local-infile=0
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
# Settings user and group are ignored when systemd is used.
# If you need to run mysqld under a different user or group,
# customize your systemd unit file for mariadb according to the
# instructions in http://fedoraproject.org/wiki/Systemd
[mysqld_safe]
log-error=/var/log/mariadb/mariadb.log
pid-file=/var/run/mariadb/mariadb.pid
#
# include all files from the config directory
!includedir /etc/my.cnf.d
So I proceeded to check the files in /etc/my.cnf.d for the innodb_buffer_pool_size value, but most of the files are almost empty.
Should I just add the string with the value that I prefer? Or am I looking in the wrong place?
Using Plesk 17.5.3 #18 CentOS 7 and MariaDB 10.1.25
Hope someone can help me out on this one.
I added the inno_db_buffer_size to my.cnf as suggested, but whe
Hi, I adjusted the value and restarted the service, but when I run:
https://github.com/major/MySQLTuner-perl
It gives me the following output:
Hi, I adjusted the value and restarted the service, but when i run:
https://github.com/major/MySQLTuner-perl
It gives me the following output:
Set thread_cache_size to 4 as a starting value
Performance should be activated for better diagnostics
Consider installing Sys schema from https://github.com/mysql/mysql-sys
Variables to adjust:
query_cache_size (=0)
query_cache_type (=0)
query_cache_limit (> 1M, or use smaller result sets)
join_buffer_size (> 256.0K, or always use indexes with joins)
tmp_table_size (> 16M)
max_heap_table_size (> 16M)
thread_cache_size (start at 4)
performance_schema = ON enable PFS
innodb_buffer_pool_size (>= 139M) if possible.
innodb_log_file_size should be (=16M) if possible, so InnoDB total log files size equals to 25% of buffer pool size.
innodb_buffer_pool_instances (=1)
It seems to me that even though I adjusted the value, it's not reflected.
How can I check this?
It is okay that you do not see the innodb_buffer_pool_size. Most of MySQL parameters are not defined in /etc/my.cnf and database server uses the default ones. For innodb_buffer_pool_size it is 128M.
To set this value differ just define it in [mysqld] of /etc/my.cnf. For example innodb_buffer_pool_size = 512M

Phabricator: setup local-disk upload limit?

I'm going to upload files in Phabricator according to this manual. But I find there's a limit 8M for local-disk storage engine in "$your_site/applications/view/PhabricatorFilesApplication/" .
I've already set client_max_body_size 64M in vhost server block for nginx.
Also, post_max_size = 64M, upload_max_filezie = 64M for php.
Then, restart nginx, php-fpm service.
But Phabricator still prints out
No configured storage engine can store this file. See "Configuring File Storage" in the documentation for information on configuring storage engines.
when I upload a file which size exceeds 8M.
Also, there's no storage.local-disk.max-size configuration key.
How can I custom local-disk upload limit?
Phabricator 535c1a5, libphutil aa6cd8f
None of the engines support more than 8MB. Larger files are stored by chunking them client-side and uploading the chunks (the chunk size is currently 4MB).
Apparently, chunking only works with drag-and-drop - try that instead of using the file upload form.
According to the guideline: https://secure.phabricator.com/book/phabricator/article/configuring_file_storage/
After configure nginx and php, you need enable Engine: MySQL and Engine: Local Disk:
First of all go to the phabricator directory which you clone from https://github.com/phacility/phabricator.git
1. Engine: MySQL
phabricator/ $ ./bin/config set storage.mysql-engine.max-size 8388608
2. Engine: Local Disk
phabricator/ $ ./bin/config set storage.local-disk.path /path/to/store/phabricator/files

Random OpenLdap Timeout Issue

I am am currently running OpenLdap 2.4.31 on Ubuntu 12.04 in EC2. I am having an issue where I get random timeouts when doing ldapsearch or ldapadd commands against the ldap server.
There is really no load against the ldap servers, I am using them for name resolution for EC2 internal hostnames and using ldap as an external node classifier for puppet.
When the timeout happens I get the following error:
ldap_sasl_bind(SIMPLE): Can't contact LDAP server
If I rerun the command it works fine, this is causing some issues in my automation (and while I can put in error checking for this it seems odd its happening in the first place).
Here is a copy of my slapd.conf (with some env specific info commented out) hopefully someone has some suggestions on what I am missing in the config to prevent the timeout issue:
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/core.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/collective.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/corba.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/cosine.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/duaconf.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/dyngroup.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/inetorgperson.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/java.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/misc.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/nis.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/openldap.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/ppolicy.schema
include /opt/openldap/openldap-2.4.31/etc/openldap/schema/puppet.schema
pidfile /opt/openldap/openldap-2.4.31/var/run/slapd.pid
argsfile /opt/openldap/openldap-2.4.31/var/run/slapd.args
loglevel 0
serverID 001
database bdb
suffix "dc=example,dc=local"
rootdn "cn=admin,dc=example,dc=local"
rootpw secret
directory /opt/openldap/openldap-2.4.31/var/openldap-data
idletimeout 120
timelimit 300
cachesize 2000
syncrepl rid=000
provider=ldap://10.10.10.10
type=refreshAndPersist
retry="5 5 10 +"
searchbase="dc=example,dc=local"
attrs="*,+"
bindmethod=simple
binddn="cn=admin,dc=example,dc=local"
credentials=secret
syncrepl rid=000
provider=ldap://10.10.10.20
type=refreshAndPersist
retry="5 5 10 +"
searchbase="dc=example,dc=local"
attrs="*,+"
bindmethod=simple
binddn="cn=admin,dc=example,dc=local"
credentials=secret
index entryCSN eq
index entryUUID eq
mirrormode TRUE
overlay syncprov
syncprov-checkpoint 100 10
Ignore this question. My self-healing automation was misconfiguration and was restarting the slapd process every minute on accident.

Resources