天天看点

HGDB4.3.2在CentOS 6.x中安装和卸载指导手册1.安装版本及注意事项2.状态检查

目录

文档用途

详细信息

相关文档

文档用途

介绍HGDB4.3.2在CentOS 6.8系统上的安装和卸载流程。

详细信息

1.安装版本及注意事项

1.1 安装版本

操作系统 CentOS 6.8 x86_64
HGDB HGDB 4.3.2

2.状态检查

2.1 检查SWAP空间

[[email protected] ~]# grep MemTotal /proc/meminfo

MemTotal:        1020072 kB

[[email protected] ~]# grep SwapTotal /proc/meminfo

SwapTotal:        835580 kB

[[email protected] ~]# free -h

             total       used       free     shared    buffers     cached

Mem:          996M       179M       816M       200K        11M        63M

-/+ buffers/cache:       103M       892M

Swap:         815M         0B       815M

2.2 操作系统

[[email protected] ~]# cat /etc/redhat-release

CentOS release 6.8 (Final)

[[email protected] ~]# uname -a

Linux hgtest 2.6.32-642.el6.x86_64 #1 SMP Tue May 10 17:27:01 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

2.3 关闭防火墙

[[email protected] ~]# service iptables stop

iptables: Setting chains to policy ACCEPT: filter               [  OK  ]

iptables: Flushing firewall rules:                         [  OK  ]

iptables: Unloading modules:                             [  OK  ]

[[email protected] ~]# chkconfig iptables off

2.4 关闭selinux

[[email protected] ~]# setenforce 0

[[email protected] ~]# sed -i "s/SELINUX=enforcing/SELINUX=disabled/g" /etc/selinux/config

[[email protected] ~]# cat /etc/selinux/config

# This file controls the state of SELinux on the system.

# SELINUX= can take one of these three values:

#     enforcing - SELinux security policy is enforced.

#     permissive - SELinux prints warnings instead of enforcing.

#     disabled - No SELinux policy is loaded.

SELINUX=disabled

# SELINUXTYPE= can take one of these two values:

#     targeted - Targeted processes are protected,

#     mls - Multi Level Security protection.

SELINUXTYPE=targeted 

2.5 主机名和时间检查

[[email protected] ~]# cat /etc/hosts

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4

::1         localhost localhost.localdomain localhost6 localhost6.localdomain6

[[email protected] ~]# cat /etc/sysconfig/clock

ZONE="Asia/Shanghai"

2.6 安装系统软件包

[[email protected] ~]# vi /etc/yum.repos.d/highgo.repo

[Server]

name=Red Hat Enterprise Linux $releasever Beta - $basearch - Source

baseurl=file:///media/cdrom

enabled=1

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

创建/media/cdrom目录:

[[email protected] ~]# mkdir /media/cdrom

挂载操作系统镜像:

[[email protected] ~]# mount /dev/sr0 /media/cdrom

安装系统软件包:

[[email protected] ~]# yum install wget readline readline-devel zlib zlib-devel openssl openssl-devel pam-devel libxml2-devel libxslt-devel python-devel tcl-devel gcc gcc-c++ -y

2.7 创建用户

[[email protected] ~]# groupadd -g 5866 highgo

[[email protected] ~]# useradd -u 5866 -g highgo highgo; echo XXXXXX(密码) | passwd -f --stdin highgo

Changing password for user highgo.

passwd: all authentication tokens updated successfully.

2.8 创建相关目录

[[email protected] ~]# mkdir -p /data/highgo/4.3.2

[[email protected] ~]# mkdir -p /data/highgo/hgdbbak/archive

[[email protected] ~]# chown -R highgo:highgo /data

2.9 修改内核参数

[[email protected] ~]# vi /etc/sysctl.conf

添加以下内容:

#for highgo db 4.3.2

kernel.shmmni = 4096

kernel.sem = 4096 2147483647 2147483646 512000

fs.file-max = 7672460

net.ipv4.ip_local_port_range = 9000 65000

net.core.rmem_default = 1048576

net.core.rmem_max = 4194304

net.core.wmem_default = 262144

net.core.wmem_max = 1048576

net.ipv4.tcp_tw_recycle = 1

net.ipv4.tcp_max_syn_backlog = 4096

net.core.netdev_max_backlog = 10000

vm.overcommit_memory = 0

fs.aio-max-nr = 1048576

net.ipv4.tcp_timestamps = 0

vm.overcommit_memory = 2

vm.overcommit_ratio = 90

vm.min_free_kbytes = 524288

root用户运行如下命令是参数立即生效:

[[email protected] ~]# sysctl -p

2.10 修改用户限制

[[email protected] ~]# vi /etc/security/limits.conf

添加如下内容:

#for highgo db 4.3.2

highgo soft  core unlimited

highgo hard  nproc unlimited

highgo soft  nproc unlimited

highgo hard  memlock unlimited

highgo hard  nofile 1024000

highgo soft  memlock unlimited

highgo soft  nofile 1024000

详细的安装,卸载命令请登录【瀚高技术支持平台】查看

https://support.highgo.com/#/index/docContent/3e948d5b025290f0