关闭numa,内存优化,至于什么是numa,大家自己上网上查一下,文章很多。
最近在测试mariadb,要想选型,千万不要听别人说那个好那个不好,要自己实践,说白了就是多做实验,多敲命令,自己去感受,适合自己的才是最好的。
至于选什么,就看你能hold住那种数据库了。
mysql5.6.x
[root@mysql92~]#yuminstallnumactl-y
[root@mysql92~]#numactl--interleave=allmysqld_safe--defaults-file=/etc/f&
[1]7592
[root@mysql92~]#
[root@mysql92~]#17010319:04:34mysqld_safeLoggingto'/data/mysqllogs/error.log'.
17010319:04:34mysqld_safeStartingmysqlddaemonwithdatabasesfrom/data/mysqldata
mariadb10.1.x
[root@mysql91~]#mysqld_safe--defaults-file=/etc/f--numa-interleave&
[1]4066
[root@mysql91~]#17010319:06:52mysqld_safeLoggingto'/log/mysql/error.log'.
mysql & mariadb mysqld_safe的区别
最近一直在和贺春旸老师学习mariadb,自己也在不断地测试,发现mariadb 的服务层做的确实要比
mysql 要好很多。看参数自己找区别吧。Mariadb
[root@mysql91~]#mysqld_safe--help
Usage:/usr/bin/mysqld_safe[OPTIONS]
--no-defaultsDon'treadthesystemdefaultsfile
--core-file-size=LIMITLimitcorefilestothespecifiedsize
--defaults-file=FILEUsethespecifieddefaultsfile
--defaults-extra-file=FILEAlsousedefaultsfromthespecifiedfile
--ledir=DIRECTORYLookformysqldinthespecifieddirectory
--open-files-limit=LIMITLimitthenumberofopenfiles
--crash-script=FILEScripttocallwhenmysqldcrashes
--timezone=TZSetthesystemtimezone
--malloc-lib=LIBPreloadsharedlibraryLIBifavailable
--mysqld=FILEUsethespecifiedfileasmysqld
--mysqld-version=VERSIONUse"mysqld-VERSION"asmysqld
--dry-runSimulatethestarttodetecterrorsbutdon'tstart
--nice=NICESettheschedulingpriorityofmysqld
--no-auto-restartExitafterstartingmysqld
--nowatchExitafterstartingmysqld
--plugin-dir=DIRPluginsareunderDIRorDIR/VERSION,if
VERSIONisgiven
--skip-kill-mysqldDon'ttrytokillstraymysqldprocesses
--syslogLogmessagestosyslogwith'logger'
--skip-syslogLogmessagestoerrorlog(default)
--syslog-tag=TAGPass-t"mysqld-TAG"to'logger'
--flush-cachesFlushandpurgebuffers/cachesbefore
startingtheserver
--numa-interleaveRunmysqldwithitsmemoryinterleaved
onallNUMAnodes
Allotheroptionsarepassedtothemysqldprogram.MySQL
[root@mysql92~]#mysqld_safe--help
Usage:/usr/bin/mysqld_safe[OPTIONS]
--no-defaultsDon'treadthesystemdefaultsfile
--defaults-file=FILEUsethespecifieddefaultsfile
--defaults-extra-file=FILEAlsousedefaultsfromthespecifiedfile
--ledir=DIRECTORYLookformysqldinthespecifieddirectory
--open-files-limit=LIMITLimitthenumberofopenfiles
--core-file-size=LIMITLimitcorefilestothespecifiedsize
--timezone=TZSetthesystemtimezone
--malloc-lib=LIBPreloadsharedlibraryLIBifavailable
--mysqld=FILEUsethespecifiedfileasmysqld
--mysqld-version=VERSIONUse"mysqld-VERSION"asmysqld
--nice=NICESettheschedulingpriorityofmysqld
--plugin-dir=DIRPluginsareunderDIRorDIR/VERSION,if
VERSIONisgiven
--skip-kill-mysqldDon'ttrytokillstraymysqldprocesses
--syslogLogmessagestosyslogwith'logger'
--skip-syslogLogmessagestoerrorlog(default)
--syslog-tag=TAGPass-t"mysqld-TAG"to'logger'
Allotheroptionsarepassedtothemysqldprogram.
如果觉得《mysql numa_mysql 内存优化之关闭numa》对你有帮助,请点赞、收藏,并留下你的观点哦!