The company is using Odoo for internal information management. As the business grows, the performance of Ubuntu servers has become a bottleneck. To solve these problems, the focus of recent work will be on performance adjustment, the entire processing process will also be recorded here for future review. Install Odoo8.0http: // www.linuxidc.com/linux/2015-12/126177.htmon the git source code in UbuntuServer14.04LTS
The company is using Odoo for internal information management. As the business grows, the performance of Ubuntu servers has become a bottleneck. To solve these problems, the focus of recent work will be on performance adjustment, the entire processing process will also be recorded here for future review.
Install Odoo8.0 http://www.linuxidc.com/Linux/2015-12/126177.htm with git source code on Ubuntu Server 14.04 LTS
How to install OpenERP (Odoo) http://www.linuxidc.com/Linux/2015-06/118497.htm in CentOS 7.x
1. According to the relevant information and suggestions, there is a preread parameter in the linux file system, you can view it by using the following command:
Blockdev -- getra/dev/sda
The general default value is 256. We can change this data to a larger value. The recommended range is between 4096-16384. The common problem with insufficient pre-read is that the disk write speed is higher than the read speed.
The command format for changing parameters is blockdev -- setra 4096/dev/sda.
You need to set each disk separately. Generally, you can write the adjustment command to the rc. local STARTUP script.
2. in linux, each time a user accesses a file, the system updates one of the attributes of the file (the last access time). When a user accesses data, the system constantly writes data, this is also a small overhead in the system. We can disable this behavior by adding the noatime option to the mounted volume in the/etc/fstab file:
/Dev/sda1/ext3 noatime, errors = remount-ro 0 1
After the modification, run the sudo mount-a command to take effect.
3. in Linux, there are two parameters for read caching and switching: You can add two lines in/etc/sysctl. conf:
Vm. swappiness = 0
Vm. overcommit_memory = 2
You can view these parameters in/proc/sys/vm /.
4. For Shared Memory settings, the default value of shared memory in ubuntu is very low. To make better use of server resources, we will adjust the default value. There is an online adjustment script.
#! /Bin/bash
Page_size = 'getconf PAGE_SIZE'
Phys_pages = 'getconf _ PHYS_PAGES'
Shmall = 'expr $ phys_pages/2'
Shmmax = 'expr $ shmall \ * $ page_size'
Echo kernel. shmmax = $ shmmax
Echo kernel. shmall = $ shmall
Run./shmsetup>/etc/sysctl. conf directly as root.
Sysctl-p
For more information about Ubuntu, see Ubuntu special page http://www.linuxidc.com/topicnews.aspx? Tid = 2
This article permanently updates the link address: Http://www.linuxidc.com/Linux/2016-03/129058.htm