Установка APEX 5.0 (Embedded PL/SQL Gateway)

1. Скачать apex_5.0.zip. Распоковать в D:\apex
2. Создать новый tablespace
CREATE TABLESPACE APEX DATAFILE ‘D:\app\oradata\apex\apex01.dbf’ SIZE 64M AUTOEXTEND ON NEXT 10M;
3. @apexins APEX APEX TEMP /i/
4. @apxchpwd
5. @apex_epg_config D:\app
6. При обновление сущесутвующего apex: @apxldimg D:\app
7. Разблокировать пользователей
ALTER USER anonymous ACCOUNT UNLOCK;
ALTER USER apex_public_user ACCOUNT UNLOCK;
8. EXEC dbms_xdb.sethttpport(8080);
9. EXEC dbms_xdb.setListenerLocalAccess(l_access => FALSE);
— если TRUE — только localhost, если FALSE — все адреса
10. Для Oracle 11g выполнить
DECLARE
ACL_PATH VARCHAR2(4000);
BEGIN
— Look for the ACL currently assigned to ‘*’ and give APEX_050000
— the «connect» privilege if APEX_050000 does not have the privilege yet.

SELECT ACL INTO ACL_PATH FROM DBA_NETWORK_ACLS
WHERE HOST = ‘*’ AND LOWER_PORT IS NULL AND UPPER_PORT IS NULL;

IF DBMS_NETWORK_ACL_ADMIN.CHECK_PRIVILEGE(ACL_PATH, ‘APEX_050000′,’connect’) IS NULL THEN
DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(ACL_PATH,’APEX_050000′, TRUE, ‘connect’);
END IF;

EXCEPTION
— When no ACL has been assigned to ‘*’.
WHEN NO_DATA_FOUND THEN
DBMS_NETWORK_ACL_ADMIN.CREATE_ACL(‘power_users.xml’,
‘ACL that lets power users to connect to everywhere’,
‘APEX_050000’, TRUE, ‘connect’);
DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL(‘power_users.xml’,’*’);
END;
/
COMMIT;

http://hostname:port/apex
Workspace: INTERNAL
Username: ADMIN
Password: *****

— APEX верии 3.2 можно удалить
DROP USER APEX_030200 CASCADE;

— Выключить XMLDB HTTP сервер
EXEC DBMS_XDB.SETHTTPPORT(0);
SELECT DBMS_XDB.GETHTTPPORT FROM DUAL;