Linux(四):centos7 Weblogic12.2安装部署

Linux centos7 Weblogic12.2安装部署

环境准备:

jdk-8u221-linux-x64.tar.gz

fmw_12.2.1.4.0_wls_Disk1_1of1.zip

 

Weblogic12.2安装部署步骤:

一、添加weblogic用户,并设置密码 

useradd weblogic

passwd weblogic

2、添加用户sudo权限修改 /etc/sudoers

vi /etc/sudoers

# User privilege specification

root ALL=(ALL) ALL

username ALL=(ALL) ALL       例如: weblogic ALL=(ALL) ALL

 

二、配置JDK1.8

#切换用户

su weblogic

#解压缩

#tar xvf jdk-8u221-linux-x64.tar.gz

#配置环境变量:vi .bash_profile

export JAVA_HOME=/home/weblogic/jdk1.8.0_221

export PATH=.:$JAVA_HOME/bin:$PATH

export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar

[weblogic@mongo-svr8 ~]$ java -version

java version "1.8.0_221"

Java(TM) SE Runtime Environment (build 1.8.0_221-b11)

Java HotSpot(TM) 64-Bit Server VM (build 25.221-b11, mixed mode)

 

三、安装weblogic

1. 创建响应文件 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 Home

#除了这里需要为需要安装的目录以外,别的地方不需要做修改

ORACLE_HOME=/home/weblogic/oracle

 

#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 Password

 

MYORACLESUPPORT_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 configuration

 

DECLINE_SECURITY_UPDATES=true

 

#Set this to true if My Oracle Support Password is specified

 

SECURITY_UPDATES_VIA_MYORACLESUPPORT=false

 

#Provide the Proxy Host

 

PROXY_HOST=

 

#Provide the Proxy Port

 

PROXY_PORT=

 

#Provide the Proxy Username

 

PROXY_USER=

 

#Provide the Proxy Password

 

PROXY_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=

2' 创建Loc文件 oraInst.loc

inventory_loc=/home/weblogic/oraInventory

inst_group=weblogic

3、执行安装

[weblogic@mongo-svr8 ~]$ java -jar fmw_12.2.1.4.0_wls.jar -silent -responseFile /home/weblogic/wls.rsp -invPtrLoc /home/weblogic/oraInst.loc -ignoreSysPrereqs

-silent 表明使用静默安装的方式

-responseFile 指定响应文件的路径

-invPtrLoc 指定安装清单文件路径

-ignoreSysPrereqs 忽略一些输出(可以不加此选项)

安装的时候会进行校验,如jdk版本检查,cpu速度,交换空间大小,临时空间大小等,复制会显示百分比进度条,时间较长,耐心等待。

Oracle Fusion Middleware 12c WebLogic Server 和 Coherence 12.2.1.4.0 的 安装 已成功完成。

日志已成功复制到/home/weblogic/oraInventory/logs。----->说明weblogic已经安装成功了。

4. 创建域文件和创建域

4.1、创建域目录

[weblogic@mongo-svr8 ~]$ mkdir -p /home/weblogic/oracle/Middleware/user_projects/domains/base_domain

4.2、创建:create_domain.rsp响应文件

//读取模板,需要修改的路径

read template from "/home/weblogic/oracle/wlserver/common/templates/wls/wls.jar";

//需要修改jdk路径

set JavaHome "/home/weblogic/jdk1.8.0_221";

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";

 

//Create Machine

//create Machine "base" as Machinename;

 

//use templates default weblogic user

find User "weblogic" as u1;

set u1.password "weblogic";

//需要修改的域路径 

write domain to "/home/weblogic/oracle/Middleware/user_projects/domains/base_domain";

 

// The domain name will be "demo-domain"

 

close template;

4.3、创建域

[weblogic@mongo-svr8 ~]$ cd /home/weblogic/oracle/wlserver/common/bin

[weblogic@mongo-svr8 bin]$ ./config.sh -mode=silent -silent_script=/home/weblogic/create_domain.rsp -logfile=/home/weblogic/create_domain.log

启动weblogic

创建好域之后,生成了启动weblogic的脚本

[weblogic@mongo-svr8 oracle]$ cd /home/weblogic/oracle/Middleware/user_projects/domains/base_domain

[weblogic@mongo-svr8 base_domain]$ ls

autodeploy  bin  common  config  console-ext  fileRealm.properties  init-info  lib  nodemanager  resources  security  startWebLogic.sh

设置启动时的密码,否则需要手动输入

mkdir -p /home/weblogic/oracle/Middleware/user_projects/domains/base_domain/servers/AdminServer/security

cat > /home/weblogic/oracle/Middleware/user_projects/domains/base_domain/servers/AdminServer/security/boot.properties <<'EOF'

username=weblogic

password=weblogic123

EOF

 

手动启动weblogic

[weblogic@mongo-svr8 oracle]$ cd /home/weblogic/oracle/Middleware/user_projects/domains/base_domain

[weblogic@mongo-svr8 base_domain]$ ./startWebLogic.sh

访问10.1.1.31:7001/console

参考:

https://blog.csdn.net/huangbaokang/article/details/89338558

https://www.wanghaiqing.com/article/f5d711ba-22ee-464e-a47d-269034988c97/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

宁宁可可

您的鼓励是我创作的动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值