龙空技术网

CentOS7.X单机部署weblogic12.1.3(静默安装)

运维Danrtsey 113

前言:

现时兄弟们对“centos65weblogic”都比较看重,同学们都需要剖析一些“centos65weblogic”的相关文章。那么小编在网摘上收集了一些有关“centos65weblogic””的相关内容,希望咱们能喜欢,我们快快来了解一下吧!

生产搭建环境:

操作系统:CentOS7.5

内存大小:16GB

硬盘:100G

注:正文中的参数与部署路径等,请根据实际需求修改

1、软件准备:

jdk-8u161-linux-x64.rpmfmw_12.1.3.0.0_wls.jar

2、jdk的环境安装与配置

(1)创建路径,并上传jdk安装包,这里使用的是rpm包

# mkdir /opt/software/# rpm -ivh /opt/software/jdk-8u161-linux-x64.rpm

(2)配置java环境

# vi /etc/profile--添加如下配置export JAVA_HOME=/usr/java/jdk1.8.0_161export CLASSPATH=.:$CLASSPATH:$JAVA_HOME/lib:$JAVA_HOME/jre/lib:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jarexport PATH=$JAVA_HOME/bin:$JAVA_HOME/jre/bin:$PATH:$HOME/binsource /etc/profile && java -version# vi $JAVA_HOME/jre/lib/security/java.security--添加如下配置securerandom.source=file:/dev/./urandom

3、创建weblogic的用户与组

# groupadd ginstall# useradd -m -g ginstall weblogic# passwd weblogic

4、配置系统内核参数

# vi /etc/sysctl.conf--添加优化参数kernel.shmmax = 536870912kernel.shmmni = 4096kernel.shmall = 15728640kernel.sem = 250 32000 100 128net.ipv4.ip_local_port_range = 9000 65500net.core.rmem_default = 4194304net.core.rmem_max = 4194304net.core.wmem_default = 262144net.core.wmem_max = 1048576fs.aio-max-nr = 1048576fs.file-max = 6815744# sysctl -p

5、修改系统资源限制

# vi /etc/security/limits.conf--添加如下配置weblogic soft nproc 16384weblogic hard nproc 16384weblogic soft nofile 65536weblogic hard nofile 65536weblogic soft stack 10240

6、修改环境变量

# vi /etc/profile添加如下配置if [ $USER = "weblogic" ]; thenif [ $SHELL = "/bin/ksh" ]; thenulimit -p 16384ulimit -n 65536elseulimit -u 16384 -n 65536fifi# source /etc/profile

7、安装weblogic

(1)、创建安装目录

# mkdir -p /weblogic/rsp/oraInventory# mkdir /weblogic/rsp/logs# chown -R weblogic:ginstall /weblogic

(2)、weblogic安装配置

# su -l weblogic$ vi /weblogic/rsp/wls.rsp--添加如下配置内容[ENGINE]#DO NOT CHANGE THIS.Response File Version=1.0.0.0.0[GENERIC]#The oracle home location. This can be an existing Oracle Home or a new Oracle HomeORACLE_HOME=/weblogic/middleware#Set this variable value to the Installation Type selected. e.g. WebLogic Server, Coherence, Complete with Examples.INSTALL_TYPE=WebLogic Server#Provide the My Oracle Support Username. If you wish to ignore Oracle Configuration Manager configuration provide empty string for user name.MYORACLESUPPORT_USERNAME=#Provide the My Oracle Support PasswordMYORACLESUPPORT_PASSWORD=<SECURE VALUE>#Set this to true if you wish to decline the security updates. Setting this to true and providing empty string for My Oracle Support username will ignore the Oracle Configuration Manager configurationDECLINE_SECURITY_UPDATES=true#Set this to true if My Oracle Support Password is specifiedSECURITY_UPDATES_VIA_MYORACLESUPPORT=false#Provide the Proxy HostPROXY_HOST=#Provide the Proxy PortPROXY_PORT=#Provide the Proxy UsernamePROXY_USER=#Provide the Proxy PasswordPROXY_PWD=<SECURE VALUE>#Type String (URL format) Indicates the OCM Repeater URL which should be of the format [scheme[Http/Https]]://[repeater host]:[repeater port]COLLECTOR_SUPPORTHUB_URL=

(3)、创建应答文件

$ vi /weblogic/rsp/oraInst.locinventory_loc=/weblogic/rsp/oraInventoryinst_group=ginstall

(4)、开始安装

$ cd /opt/software$ java -jar fmw_12.1.3.0.0_wls.jar -silent -responseFile /weblogic/rsp/wls.rsp -invPtrLoc /weblogic/rsp/oraInst.loc

8、创建域,注意加粗部分,需要更改密码

$ vi /weblogic/rsp/domain.rspread template from "/weblogic/middleware/wlserver/common/templates/wls/wls.jar";set JavaHome "/usr/java/jdk1.8.0_161";set ServerStartMode "prod";find Server "AdminServer" as AdminServer;set AdminServer.ListenAddress "";set AdminServer.ListenPort "7001";set AdminServer.SSL.Enabled "true";set AdminServer.SSL.ListenPort "7002";//We can directly create a new managed server.create Server "base" as BASE;set BASE.ListenAddress "";set BASE.ListenPort "8081";//set BASE.SSL.Enabled "true";//set BASE.SSL.ListenPort "8082″;//Create Machinecreate Machine "base" as Machinename;//use templates default weblogic userfind User "weblogic" as u1;set u1.password "password";write domain to "/weblogic/middleware/user_projects/domains/base_domain/";// The domain name will be "base-domain"close template;

9、创建域操作

$ cd /weblogic/middleware/wlserver/common/bin$ ./config.sh -mode=silent -silent_script=/weblogic/rsp/domain.rsp -logfile=/weblogic/rsp/logs/domain.log

10、配置免密登录(加粗的password需要替换为上述创建域时所更改的密码)

$ mkdir -p /weblogic/middleware/user_projects/domains/base_domain/servers/AdminServer/security/$ vi /weblogic/middleware/user_projects/domains/base_domain/servers/AdminServer/security/boot.propertiesusername=weblogicpassword=password

11、修改jvm参数

$ vi /weblogic/middleware/user_projects/domains/base_domain/bin/setDomainEnv.sh#根据操作系统的内存对应修改参数值,支持使用m或g,如下为配置8G内存WLS_MEM_ARGS_64BIT="-Xms8192m -Xmx8192m"#或者使用如下配置WLS_MEM_ARGS_64BIT="-Xms8g -Xmx8g"

12、启动weblogic

# su - weblogic$ nohup /weblogic/middleware/user_projects/domains/base_domain/bin/startWebLogic.sh >/dev/null 2>&1 &

13、停止weblogic

# su - weblogic$ nohup /weblogic/middleware/user_projects/domains/base_domain/bin/stopWebLogic.sh >/dev/null 2>&1 &

14、访问weblogic控制台

标签: #centos65weblogic #centos安装weblogic12