Skip to content

Different paths to configs for mariadb and redis on Rocky Linux 8 #43

@Spockie

Description

@Spockie

[root@server ~]# rpm -qf /etc/my.cnf.d/server.cnf
error: file /etc/my.cnf.d/server.cnf: No such file or directory

[root@server ~]# rpm -qf /etc/my.cnf.d/mariadb-server.cnf
mariadb-server-10.3.35-1.module+el8.6.0+1005+cdf19c22.x86_64

[root@server ~]# rpm -qf /etc/redis/redis.conf
error: file /etc/redis/redis.conf: No such file or directory

[root@server ~]# rpm -qf /etc/redis.conf
redis-5.0.3-5.module+el8.5.0+657+2674830e.x86_64

I have tried it yesterday for system running on Rocky Linux 8 (freshly updated).

Quick for me was to copy your role (from .ansible/...) to my playbooks/roles directory and then edit it.

rbicker.nextcloud/handlers/main.yml

 - name: mysql optimization
   lineinfile:
-    path: /etc/my.cnf.d/server.cnf
+    path: /etc/my.cnf.d/mariadb-server.cnf
     regexp: '^{{ item.option }}'
     line: '{{ item.option }}={{ item.value }}'
     insertafter: '\[mysqld\]'

rbicker.nextcloud/tasks/main.yml

 - name: ensure mysql binary logging is disabled
   lineinfile:
-    path: /etc/my.cnf.d/server.cnf
+    path: /etc/my.cnf.d/mariadb-server.cnf
     state: absent
     regexp: "^log-bin$"
   notify:
@@ -255,7 +255,7 @@

 - name: ensure redis options are set
   lineinfile:
-    path: /etc/redis/redis.conf
+    path: /etc/redis.conf
     regexp: '^{{ item.option }}\s'
     line: "{{ item.option }} {{ item.value }}"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions