MongoDB Pre-boot system Setup to resolve partial warning issues

Source: Internet
Author: User

1. Multi-core system resource allocation

2017-10-13t17:57:02.650+0800 I CONTROL [initandlisten] * * Warning:you is running on a NUMA machine.2017-10-13t17:57:02.6 50+0800 I CONTROL [initandlisten] * * We suggest launching mongod like this to avoid performance problems:2017-10-13t17:57: 02.650+0800 I CONTROL [initandlisten] * * Numactl--interleave=all Mongod [Other options]

Just like in the hint, the startup script is written as follows:

Numactl--interleave=all/path/to/mongod--config/path/to/mongodb.conf

2, large memory page problems

2017-10-13t17:57:02.650+0800 I control [initandlisten]2017-10-13t17:57:02.650+0800 i control [initandlisten] * * WARNING:/sys/kernel/mm/transparent_hugepage/enabled is ' always '. 2017-10-13t17:57:02.650+0800 I CONTROL [ Initandlisten] * * We suggest setting it to ' Never ' 2017-10-13t17:57:02.650+0800 I CONTROL [initandlisten]2017-10-13t17:57 : 02.650+0800 I CONTROL [initandlisten] * * WARNING:/sys/kernel/mm/transparent_hugepage/defrag is ' always '. 2017-10-13t17:57:02.650+0800 I CONTROL [initandlisten] * * We suggest setting it to ' never '

We cat on the above two files, found that the content is "[always] madvise never", we need to be prompted to change it to never, but this setting is not very good change, so a relatively simple solution is to turn it on when the boot, do not change the default configuration. And the modification of this file needs to be done under the root user, it is not possible to sudo-s directly in the startup script. So the solution is as follows:

sudo vim/etc/rc.local Add the following two sentences in the back of Echo never >/sys/kernel/mm/transparent_hugepage/enabledecho never >/sys/kernel/ Mm/transparent_hugepage/defrag

3, Bonus

Remember to change the/etc/security/limits.conf in the Nofile, or 1024 of the nofile will certainly be due to file open too many system problems.

The first two warning only cause performance problems, while the third causes a system error.

4, the other access control warning will not have to control

MongoDB Pre-boot system Setup to resolve partial warning issues

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.