1、确认操作系统环境变量中的JAVA_HOME=D:\Oracle\Middleware\jdk160_29与安装部署的位置保持一致;
2、编辑D:\Oracle\Middleware\wlserver_12.1\server\bin\installSvc.cmd文件,增加标红部分内容:
if "%WL_USE_AMD64DLL%" == "true" set EXTRAPATH=%WL_HOME%\server\native\win\x64\;%WL_HOME%\server\bin;%JAVA_HOME%\jre\bin;%JAVA_HOME%\bin;%WL_HOME%\server\native\win\x64\oci920_8
@rem domain的名称
set DOMAIN_NAME=base_domain@rem 一般为默认set SERVER_NAME=AdminServer @rem domain的路径set USERDOMAIN_HOME=D:\Oracle\Middleware\user_projects\domains\base_domainset WLS_PW=weblogic123rem *** Install the service
"%WL_HOME%\server\bin\wlsvc" -install -svcname:"wlsvc %DOMAIN_NAME%_%SERVER_NAME%" -javahome:"%JAVA_HOME%" -execdir:"%USERDOMAIN_HOME%" -maxconnectretries:"%MAX_CONNECT_RETRIES%" -host:"%HOST%" -port:"%PORT%" -extrapath:"%EXTRAPATH%" -password:"%WLS_PW%" -cmdline:%CMDLINE%3、在DOS窗口中运行>installSvc.cmd
执行成功后将在系统服务中出现“wlsvc base_domain_AdminServer”服务,启动后即可;