cd /u01/media
mkdir -p /u01/apex
unzip apex_19.2.zip -d /u01/
chown -R oracle:dba /u01/apex
cd /u01/apex
-- 以超级管理员身份登录数据库
sqlplus / as sysdba
-- 安装APEX,指定默认表空间和静态文件别名
SQL> @apexins.sql SYSAUX SYSAUX TEMP /i/
-- 安装完毕后数据库会话会自动断开,再次以超级管理员身份登录数据库
sqlplus / as sysdba
-- 创建APEX实例管理员(Instance Administration)及密码,这个密码必须包含特殊符号,否则设置不上。这个密码很重要,是管理APEX平台的账号密码,以后创建新的应用schema、解锁账号等都靠它,第一次登录APEX时也要用到。
SQL> @apxchpwd.sql
-- 配置RESTful Services服务
SQL> @apex_rest_config.sql
提示时,输入
APEX_LISTENER
和
APEX_REST_PUBLIC_USER
帐户的密码。
Passw0rd
-- 禁用数据库内置的PL/SQL网关
SQL> exec dbms_xdb.sethttpport(0);
SQL> exec dbms_xdb.setftpport(0);
-- 解锁ORDS用户账号
SQL> alter user apex_public_user account unlock;
SQL> alter user apex_public_user identified by "your password";
-- 断开数据库会话
SQL> exit
SQL>@apex_rest_config.sql
提示时,输入APEX_LISTENER
和APEX_REST_PUBLIC_USER
帐户的密码。
在Oracle Application Express中配置RESTful服务时,它将创建两个新的数据库帐户。
- APEX_LISTENER
-用于查询存储在Oracle Application Express中的RESTful服务定义的帐户。 - APEX_REST_PUBLIC_USER
-调用存储在Oracle Application Express中的RESTful服务定义时使用的帐户。
ORDS 安装日志
[root@huyi ords]# java -jar ords.war install advanced #java -jar ords.war uninstall 这是卸载
This Oracle REST Data Services instance has not yet been configured.
Please complete the following prompts
Enter the location to store configuration data: /oracle/ords/config #<--------
Enter the name of the database server [localhost]:10.85.10.10 #<--------
Enter the database listen port [1521]: #<--------
Enter 1 to specify the database service name, or 2 to specify the database SID [1]:
Enter the database service name:apex #<--------
Enter 1 if you want to verify/install Oracle REST Data Services schema or 2 to skip this step [1]:
Enter the database password for ORDS_PUBLIC_USER: #<-------- ords用户1
Confirm password:
Requires to login with administrator privileges to verify Oracle REST Data Services schema.
Enter the administrator username:sys #<--------
Enter the database password for SYS AS SYSDBA:
Confirm password:
Retrieving information.
Enter the default tablespace for ORDS_METADATA [SYSAUX]: #<-------- ords用户2
Enter the temporary tablespace for ORDS_METADATA [TEMP]:
Enter the default tablespace for ORDS_PUBLIC_USER [USERS]: #<--------ords用户3
Enter the temporary tablespace for ORDS_PUBLIC_USER [TEMP]:
Enter 1 if you want to use PL/SQL Gateway or 2 to skip this step.
If using Oracle Application Express or migrating from mod_plsql then you must enter 1 [1]:
Enter the PL/SQL Gateway database user name [APEX_PUBLIC_USER]:
Enter the database password for APEX_PUBLIC_USER: #<-------- apex 用户1
Confirm password:
Enter 1 to specify passwords for Application Express RESTful Services database users (APEX_LISTENER, APEX_REST_PUBLIC_USER) or 2 to skip this step [1]:
Enter the database password for APEX_LISTENER: #<--------apex 用户2
Confirm password:
Enter the database password for APEX_REST_PUBLIC_USER: #<--------apex 用户3
Confirm password:
Nov 28, 2019 11:19:07 AM
INFO: reloaded pools: []
Installing Oracle REST Data Services version 19.2.0.r1991647
... Log file written to /root/ords_install_core_2019-11-28_111908_00126.log
... Verified database prerequisites
... Created Oracle REST Data Services proxy user
... Created Oracle REST Data Services schema
... Granted privileges to Oracle REST Data Services
... Created Oracle REST Data Services database objects
... Log file written to /root/ords_install_datamodel_2019-11-28_112000_00843.log
... Log file written to /root/ords_install_apex_2019-11-28_112009_00950.log
Completed installation for Oracle REST Data Services version 19.2.0.r1991647. Elapsed time: 00:01:10.42
Enter 1 if you wish to start in standalone mode or 2 to exit [1]:
Enter the APEX static resources location:/oracle/apex/images
Enter 1 if using HTTP or 2 if using HTTPS [1]:
Enter the HTTP port [8080]:
2019-11-28 11:20:30.496:INFO::main: Logging initialized @194207ms to org.eclipse.jetty.util.log.StdErrLog
Nov 28, 2019 11:20:30 AM
INFO: HTTP and HTTP/2 cleartext listening on port: 8080
Nov 28, 2019 11:20:30 AM
INFO: Disabling document root because the specified folder does not exist: /oracle/ords/config/ords/standalone/doc_root
2019-11-28 11:20:31.885:INFO:oejs.Server:main: jetty-9.4.z-SNAPSHOT; built: 2019-05-02T09:46:34.874Z; git: 14f32d50076f2b706f41a33066eb364d8492e199; jvm 1.8.0_181-b13
2019-11-28 11:20:31.945:INFO:oejs.session:main: DefaultSessionIdManager workerName=node0
2019-11-28 11:20:31.945:INFO:oejs.session:main: No SessionScavenger set, using defaults
2019-11-28 11:20:31.947:INFO:oejs.session:main: node0 Scavenging every 600000ms
Nov 28, 2019 11:20:35 AM
INFO: Configuration properties for: |apex||
db.hostname=10.85.10.10
db.password=******
db.port=1521
db.servicename=apex
db.username=APEX_PUBLIC_USER
resource.templates.enabled=true
security.requestValidationFunction=wwv_flow_epg_include_modules.authorize
security.validationFunctionType=plsql
Nov 28, 2019 11:20:35 AM
WARNING: *** jdbc.MaxLimit in configuration |apex|| is using a value of 10, this setting may not be sized adequately for a production environment ***
Nov 28, 2019 11:20:35 AM
WARNING: *** jdbc.InitialLimit in configuration |apex|| is using a value of 3, this setting may not be sized adequately for a production environment ***
Nov 28, 2019 11:20:38 AM
INFO: Configuration properties for: |apex|pu|
db.hostname=10.85.10.10
db.password=******
db.port=1521
db.servicename=apex
db.username=ORDS_PUBLIC_USER
resource.templates.enabled=true
security.requestValidationFunction=wwv_flow_epg_include_modules.authorize
security.validationFunctionType=plsql
Nov 28, 2019 11:20:38 AM
WARNING: *** jdbc.MaxLimit in configuration |apex|pu| is using a value of 10, this setting may not be sized adequately for a production environment ***
Nov 28, 2019 11:20:38 AM
WARNING: *** jdbc.InitialLimit in configuration |apex|pu| is using a value of 3, this setting may not be sized adequately for a production environment ***
Nov 28, 2019 11:20:39 AM
INFO: Configuration properties for: |apex|al|
db.hostname=10.85.10.10
db.password=******
db.port=1521
db.servicename=apex
db.username=APEX_LISTENER
resource.templates.enabled=true
security.requestValidationFunction=wwv_flow_epg_include_modules.authorize
security.validationFunctionType=plsql