oracle11g - PLSQL package installation -


anybody here knows how install plsql package in oracle 11g? trying use these 2 packages: 1.dbms_network_acl_admin 2.dbms_network_acl_utility

i using oracle application express, far sql not able identify these .. thank you.

installing plsql packages dbms_network_acl_admin

you can check whether exist first, run user sys:

select *   dba_objects  name = ... 

if don't exist on oracle rdbms (i don't know whether maybe express edition excludes them, seems illogical), database not installed well. easiest way re-install database. in case don't need replace software, create new database.

the advanced way reinstall parts of data dictionary. if have never done before, can assume database end corrupt. can try instance executing ?/dbs/catqm.sql.

replace ? path oracle_home lives , rdbms/admin. such $oracle_home/rdbms/admin on linux. remember close database other users.

maintaining acl

the comments led conclusion acl missing. approach use maintain them in package. please careful, 11.2.0.3 has bad habit of crashing session of connected user on acl maintenance despite preventive measures.

warning! script allows access ports between 1 , 32767. want restrict applicable ports application. ease of use i've pasted here 32k ports.

warning 2! maintenance of acl can non-trivial , can lead security risks (which gracefully accepted upto release 11 of oracle :-). involve sysadmin or networkadmin in case of doubt.

-- -- when ora-24247 errors continue despite creation of network acl, -- first remove acl user sys using: -- -- begin --   dbms_network_acl_admin.drop_acl('/sys/acls/invantive-producer.xml'); -- end; -- -- occurs incidentally on oracle 11g r1. -- prompt create access control lists.  declare   l_principal     varchar2(30) := upper('&&itgen_user_owner_login');   l_acl           varchar2(300);   l_acl_full_path varchar2(300);   l_dummy         pls_integer;   --   -- temporary disable code, causes installation   -- issues.   --   l_skip_acl_maintenance boolean := false;   --   -- temporarily disable granting acl access.   --   l_skip_acl_grants boolean := false; begin   l_acl := 'invantive-producer.xml';   l_acl_full_path := '/sys/acls/' || l_acl;   --   if not l_skip_acl_maintenance       --     -- drop superfluous network acls users , roles no longer exist.     --     -- dropping network acls tricky. queries on view dba_network_acls     -- lead ora-600. query seems work reliable on oracle 11g r1.     --     -- first delete acl privileges no acl exists.     -- during this, ignore problems.     --     r in     ( select nae.acl       ,      nae.principal         dba_network_acl_privileges nae        nae.principal               not in               ( select usr.username                   dba_users usr                union                 select rle.role                   dba_roles rle              )     )     loop       begin         dbms_network_acl_admin.delete_privilege         ( r.acl         , r.principal         );         dbms_output.put_line('dropped superfluous acl ' || r.acl || '  ' || r.principal || '.');       exception         when others                   dbms_output.put_line('ignoring error ' || sqlerrm);       end;     end loop;     --     -- try time, not ignoring problems.     --     r in     ( select nae.acl       ,      nae.principal         dba_network_acl_privileges nae        nae.principal               not in               ( select usr.username                   dba_users usr                union                 select rle.role                   dba_roles rle              )     )     loop       dbms_network_acl_admin.delete_privilege       ( r.acl       , r.principal       );       dbms_output.put_line('dropped superfluous acl ' || r.acl || '  ' || r.principal || '.');     end loop;     --     -- create new network acl when not yet exist.     --     begin       select 1         l_dummy         resource_view rvw        rvw.any_path = l_acl_full_path       ;       dbms_output.put_line('acl ' || l_acl || ' present. no action.');     exception       when no_data_found               dbms_network_acl_admin.create_acl         ( acl             => l_acl         , description     => 'normal access invantive producer'         , principal       => 'sys'         , is_grant        => true         , privilege       => 'connect'         , start_date      => null         , end_date        => null         );         dbms_network_acl_admin.assign_acl         ( acl        => l_acl         , host       => '*'         , lower_port => 1 /* attention! may want tighten this! */         , upper_port => 32767 /* attention! may want tighten this! */         );         dbms_output.put_line('created acl ' || l_acl || ' port 1 till 32767.');     end;   else     dbms_output.put_line('skipped maintenance of access control lists.');   end if;   --   if not l_skip_acl_grants       --     -- update privilges acl when not correct.     --     r_usr     in     ( select l_principal principal         dual       union       --       -- unspecified invantive schema.       --       -- sys, itgen_schemas_r can contain multiple rows.       --       select sma_r.name principal         itgen_schemas_r sma_r     )     loop       begin         select 1           l_dummy           dba_network_acl_privileges nae          nae.acl        = l_acl_full_path         ,    nae.principal  = r_usr.principal         ,    nae.privilege  = 'connect'         ,    nae.is_grant   = 'true'         ,    nae.invert     = 'false'         ,    nae.start_date null         ,    nae.end_date   null         ;         dbms_output.put_line('connect privileges granted ' || l_principal || '. no action.');       exception         when no_data_found                   dbms_network_acl_admin.add_privilege           ( acl         => l_acl           , principal   => l_principal           , is_grant    => true           , privilege   => 'connect'           , start_date  => null           , end_date    => null           );           dbms_output.put_line('connect privileges granted ' || l_principal || '.');       end;     end loop;     --     commit;   else     dbms_output.put_line('skipped grants of access control lists.');   end if; end; / 

Comments

Popular posts from this blog

php - regexp cyrillic filename not matches -

c# - OpenXML hanging while writing elements -

sql - Select Query has unexpected multiple records (MS Access) -