codememo

Mariadb 할당된 메모리 구성

tipmemo 2023. 9. 5. 20:31
반응형

Mariadb 할당된 메모리 구성

MariaDB 서버에 더 많은 메모리를 할당하고 싶지만 올바른 my.cnf 파일을 찾는 데 어려움을 겪고 있습니다.

기본적으로 innodb_buffer_pool_size를 편집하고 싶습니다.

/etc/my.cnf에 있는 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

그래서 innodb_buffer_pool_size 값에 대해 /etc/my.cnf.d의 파일을 확인해 보았지만 대부분의 파일이 거의 비어 있습니다.

원하는 값의 문자열만 추가하면 되나요?아니면 제가 잘못된 곳을 찾고 있는 건가요?

Plesk 17.5.3 #18 Cent 사용OS 7 및 MariaDB 10.1.25

누군가가 이 일을 도와줄 수 있기를 도와주세요.

제안대로 inno_db_buffer_size를 my.cnf에 추가했지만, who

안녕하세요. 값을 조정하고 서비스를 다시 시작했는데, https://github.com/major/MySQLTuner-perl 을 실행하면 다음과 같은 출력이 나옵니다.

안녕하세요. 값을 조정하고 서비스를 다시 시작했는데, https://github.com/major/MySQLTuner-perl 을 실행하면 다음과 같은 출력이 나옵니다.

    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)

제가 보기에는 값을 조정했는데 반영이 안 되는 것 같습니다.이걸 어떻게 확인해야 하나요?

당신이 보지 않아도 괜찮습니다.innodb_buffer_pool_size대부분의 MySQL 매개 변수는 다음에 정의되어 있지 않습니다./etc/my.cnf데이터베이스 서버는 기본 서버를 사용합니다.innodb_buffer_pool_size128M 입니다.
이 값을 설정하려면 에서 정의하십시오.[mysqld]/etc/my.cnf.예를들면innodb_buffer_pool_size = 512M

언급URL : https://stackoverflow.com/questions/45834406/mariadb-configure-alloted-memory

반응형