您好,欢迎访问三七文档
当前位置:首页 > IT计算机/网络 > 数据库 > 使用benchmark跑oracle基准测试-XXXX0810
逻辑:存储映射lun给oracle主机(linux)用安装oracle11gr2forlinux在oracle下,配置监听在oracle下,建立tpc的业务表空间,用户,授权在windown2008客户端安装oracle客户端软件,配置tns在windown2008客户端,安装benchmarkfactory使用benchmarkfactory跑基准测试oracle安装包:p13390677_112040_Linux-x86-64_1of7.zipp13390677_112040_Linux-x86-64_2of7.ziporacle客户端forwindowns:win32_11gR2_client.zipbenchmarkfactory安装包:Benchmark.Factory.zipxmanager安装包:安装包在192.168.8.8的/data/home/lf/下安装oracle11gr2forlinux说明:存储映射过来多少个lun,根据存储的大小,本例映射40个lun,块大小是16k,其中34个作为tpc的业务表空间用,6个作为redolog用编辑hosts文件[root@localhost~]#cat/etc/hosts127.0.0.1localhostlocalhost.localdomainlocalhost4localhost4.localdomain4::1localhostlocalhost.localdomainlocalhost6localhost6.localdomain6192.168.8.247localhost配置yum源[root@localhost~~]#cat/etc/yum.repos.d/redhat.repo[RHEL]name=RHEL6.4baseurl=file:///mediagpgcheck=0gpgkey=file:///media/RPM-GPG-KEY-redhat-releaseenabled=1[root@localhost~~]#cat/etc/rc.local#!/bin/sh##Thisscriptwillbeexecuted*after*alltheotherinitscripts.#Youcanputyourowninitializationstuffinhereifyoudon't#wanttodothefullSysVstyleinitstuff.touch/var/lock/subsys/localmount-oloop/opt/OracleLinux-R6-U6-Server-x86_64-dvd.iso/media/[root@localhost~~]#ls/opt/OracleLinux-R6-U6-Server-x86_64-dvd.iso/opt/OracleLinux-R6-U6-Server-x86_64-dvd.iso[root@localhost~~]#通过yum安装依赖包yuminstall-ycompat-libstdc++-33elfutils-libelfelfutils-libelf-develgccgcc-c++\glibcglibc-commonglibc-develglibc-headerskshlibaiolibaio-devellibgcc\libstdc++libstdc++-develmakesysstatunixODBCunixODBC-develmksh\nss-softokn-freebl-3.12.9-11.el6.i686libgcc-4.4.7-3.el6.i686\libstdc++-4.4.7-3.el6.i686pam-1.1.1-13.el6.i686dumpxtermvsftpd修改内核参数(服务器内存是32G)[root@localhost~]#vi/etc/sysctl.confkernel.shmall=8388608此参数设置为系统内存/4096kernel.shmmax=34359738367此参数设置成系统内存大小减1bytekernel.shmmni=4096fs.file-max=6815744net.ipv4.ip_local_port_range=900065500net.core.rmem_default=1048576net.core.rmem_max=4194304net.core.wmem_default=262144net.core.wmem_max=1048576fs.aio-max-nr=1048576vm.swappiness=1kernel.sem=50106412805010128修改IO计划(添加elevator=deadline)[root@localhost~]#vim/boot/grub/menu.lstdefault=0timeout=5splashimage=(hd0,0)/grub/splash.xpm.gzhiddenmenutitleRedHatEnterpriseLinux(2.6.32-358.el6.x86_64)root(hd0,0)kernel/vmlinuz-2.6.32-358.el6.x86_64roroot=/dev/mapper/VolGroup-lv_rootrd_NO_LUKSelevator=deadlineLANG=en_US.UTF-8rd_NO_MDrd_LVM_LV=VolGroup/lv_swapSYSFONT=latarcyrheb-sun16crashkernel=128Mrd_LVM_LV=VolGroup/lv_rootKEYBOARDTYPE=pcKEYTABLE=usrd_NO_DMrhgbquietinitrd/initramfs-2.6.32-358.el6.x86_64.img关闭防火墙serviceiptablesstopserviceip6tablesstopchkconfigiptablesoffchkconfigip6tablesoff将selinux禁用即可,也就是修改vi/etc/selinux/config文件,修改后的内容为:SELINUX=disabled修改用户限制vi/etc/security/limits.conforaclesoftnproc2047oraclehardnproc16384oraclesoftnofile4096oraclehardnofile65536oraclesoftstack10240修改环境变量vi/etc/profileif[$USER=oracle]||[$USER=grid];thenif[$SHELL=/bin/ksh];thenulimit-p16384ulimit-n65536elseulimit-u16384-n65536fiumask022fi创建用户组groupadd-g1000oinstallgroupadd-g1100asmadmingroupadd-g1200dbagroupadd-g1201opergroupadd-g1300asmdbagroupadd-g1301asmoper创建用户Oracle和griduseradd-goinstall-Gasmdba,dba,operoracle修改用户密码passwdoracle密码设置成oracle创建名文件安装路径,设置文件权限mkdir-p/u01/app/oraclechownoracle:oinstall/u01/app/oraclechmod-R775/u01chown-Roracle:oinstall/u01修改Oracle用户环境变量vim/home/oracle/.bash_profileORACLE_BASE=/u01/app/oracleORACLE_HOME=$ORACLE_BASE/product/11.2.4/dbhome_1ORACLE_SID=orclexportORACLE_UNQNAME=orclLD_LIBRARY_PATH=$ORACLE_HOME/libPATH=$PATH:$ORACLE_HOME/bin:$HOME/binexportORACLE_BASEORACLE_HOMEORACLE_SIDLD_LIBRARY_PATHPATHexportLANG=C#aliassqlplus='rlwrapsqlplus'#aliasrman='rlwraprman'安装xwindows组件yumgroupinstallXWindowSystem添加Enable=1vi/etc/gdm/custom.conf#GDMconfigurationstorage[daemon][security]AllowRemoteRoot=truePort=177[xdmcp]Enable=1[greeter][chooser][debug]重启reboot安装oracle数据库上传安装包p13390677_112040_Linux-x86-64_1of7.zipp13390677_112040_Linux-x86-64_2of7.zip至rac01下面的/opt目录解压unzipp13390677_112040_Linux-x86-64_1of7.zipunzipp13390677_112040_Linux-x86-64_2of7.zip解压时会自动在/opt目录下生成database目录root#chmod777/opt/database/然后通过本地图形界面xmanager安装数据库软件。[oracle@host~]$exportDISPLAY=192.168.8.95:0.0(这儿配置装有xmanager的windows端IP)[oracle@host~]$/opt/database/runInstallerroot用户执行红框中的语句netca监听dbca建库创建选择定制创建orcl默认下一步选择统一密码:oracleyes选择文件系统形式建立数据库非闪回,非归档默认下一步sga配置为80%内存注意:不要使用useAutomaticMemoryManagement否则设置80%共享内存会报错,数据库无法启动。sizing,根据实际业务情况,此处选择32k的块大小,processes是链接数据库的user数,尽量大一些,此处选择8000选择简体中文temp和undo表空间尽量大一些,此处选择如下redolog为三组,每组一个G点击finish说明:存储映射过来多少个lun,根据存储的大小,本例映射40个lun,块大小是16k,其中34个作为tpc的业务表空间用,6个作为redolog用kernel/vmlinuz-2.6.32-358.el6.x86_64roroot=/dev/mapper/VolGroup-lv_rootrd_NO_LUKSelevator=deadlineLANG=en_US.UTF-8rd_NO_MDrd_LVM_LV=VolGroup/lv_swapSYSFONT=latarcyrheb-sun16crashkernel=128Mrd_LVM_LV=VolGroup/lv_rootKEYBOARDTYPE=pcKEYTABLE=usrd_NO_DMrhgbquiet[oracle@host~]$exportDISPLAY=192.168.8.95:0.0(这儿配置装有xmanager的windows端IP)注意:不要使用useAutomaticMemoryManagement否则设置80%共享内存会报错,数据库无法启动。此处选择32k的块大小,processes是链接数据库的user数,尽量大一些,此处选择8000kernel/vmlinuz-2.6.32-358.el6.x86_64roroot=/dev/mapper/VolGroup-lv_rootrd_NO_LUKSele
本文标题:使用benchmark跑oracle基准测试-XXXX0810
链接地址:https://www.777doc.com/doc-13966 .html