Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-36651

mariadb cannot configure the perimission of log file

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Not a Bug
    • None
    • N/A
    • Server
    • None

    Description

      The binlog and audit logs of MariaDB are automatically generated, but the permissions cannot be set to the expected 0500

      ls -l /var/log/mysql
      total 4496
      -rw-rw---- 1 mysql mysql     417 Apr 19 14:20 mysql-bin.000007
      -rw-rw---- 1 mysql mysql 4590255 Apr 19 17:03 mysql-bin.000008
      -rw-rw---- 1 mysql mysql      64 Apr 19 14:20 mysql-bin.index
       
      ls -l /var/log/
      drwx------ 2 mysql mysql     4096 Apr 19 14:20 mysql
      -rw-rw---- 1 mysql mysql  3888844 Apr 19 17:04 mysqld-audit.log
      -rw-rw---- 1 mysql mysql 52428892 Apr 19 13:52 mysqld-audit.log.1
      -rw------- 1 mysql mysql  3328239 Apr 19 14:20 mysqld.log
      
      

      this is my mariadb config

      [mysqld]
      skip-name-resolve
      datadir=/var/lib/mysql
      socket=/var/run/mysql/mysql.sock
      pid-file=/var/run/mysql/mysqld.pid
      user=mysql
      binlog_format=ROW
      bind-address=
      default_storage_engine=innodb
      innodb_autoinc_lock_mode=2
      innodb_flush_log_at_trx_commit=0
      innodb_buffer_pool_size=122M
      max_connections = 1000
      server_id = 1
      server_audit_logging=ON
      plugin_load_add=server_audit
      server_audit_events=CONNECT,TABLE
      server_audit_file_path=/var/log/mysqld-audit.log
      server_audit_file_rotations=5
      server_audit_file_rotate_size=52428800
       
      # default to standalone
      wsrep_cluster_address=gcomm://
      wsrep_sst_method=rsync
       
       
      character-set-server=UTF8
      collation-server=utf8_general_ci
      wsrep_retry_autocommit=1000
      wsrep_sync_wait=0
      secure-file-priv=/tmp
      local-infile=0
      log-error=/var/log/mysqld.log
      sql_mode="STRICT_ALL_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"
      default_password_lifetime=365
       
      # enable binlog
      log_bin=/var/log/mysql/mysql-bin.log
      expire_logs_days=10
      max_binlog_size=100M
      binlog_format=ROW
      
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            zzzzzoy zzzzzoy
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.