Oracle Gateway database link to MSSQL server failed with error "Ora-28500 error with argument 523 80 {82} "
Solution:
Check and modify the .LOC file located in Gateway_Home/<gtw>/driver to get the right PATH to the ODBC library.
$ sqlplus / as sysdba SQL> show parameter undo NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ undo_management string AUTO undo_retention integer 900 undo_tablespace string UNDOTBS1 SQL>The current undo tablespace as suggested by the initialization parameter undo_tablespace is UNDOTBS1. Leave this sysdba as is, open another console, log in as user SCOTT and initiate a transaction.$ sqlplus scott/tiger update emp set sal = sal + 1000 where empno=7839; 1 row updated.With an update on emp table we have initiated a transaction. The undo data is written to a segment in the UNDOTBS1 tablespace. Now leave this SCOTT's session intact and go back to the sysdba console without issuing any COMMIT or ROLLBACK.CREATE UNDO TABLESPACE undotbs2 DATAFILE '/d01/apps/oradata/oraxpo/undotbs201.dbf' SIZE 50M AUTOEXTEND ON NEXT 5M; Tablespace created. -- We created a new UNDO tablespace named UNDOTBS2ALTER SYSTEM SET UNDO_TABLESPACE=UNDOTBS2 SCOPE=BOTH;
System altered. -- Switch the database to the new UNDO tablespace. SQL> DROP TABLESPACE undotbs1 INCLUDING CONTENTS AND DATAFILES; DROP TABLESPACE undotbs1 INCLUDING CONTENTS AND DATAFILES * ERROR at line 1: ORA-30013: undo tablespace 'UNDOTBS1' is currently in use -- Try to drop the tablespace but failed. SQL>With the alter system set undo_tablespace=UNDOTBS2, the database UNDO tablespace is changed and any new transaction's undo data will go to the new tablespace i.e. UNDOTBS2. But the undo data for already pending transaction (e.g. the one initiated by SCOTT before the database UNDO tablespace switch) is still in the old tablespace with a status of PENDING OFFLINE. As far as it is there you cannot drop the old tablespace.set lines 10000 column name format a10 SELECT a.name,b.status FROM v$rollname a,v$rollstat b WHERE a.usn = b.usn AND a.name IN ( SELECT segment_name FROM dba_segments WHERE tablespace_name = 'UNDOTBS1' ); NAME STATUS ---------- --------------- _SYSSMU8$ PENDING OFFLINEThe above query shows the name of the UNDO segment in the UNDOTBS1 tablespace and its status. Now lets see which users/sessions are running this pending transaction.column username format a6 SELECT a.name,b.status , d.username , d.sid , d.serial# FROM v$rollname a,v$rollstat b, v$transaction c , v$session d WHERE a.usn = b.usn AND a.usn = c.xidusn AND c.ses_addr = d.saddr AND a.name IN ( SELECT segment_name FROM dba_segments WHERE tablespace_name = 'UNDOTBS1' ); NAME STATUS USERNA SID SERIAL# ---------- --------------- ------ ---------- ---------- _SYSSMU8$ PENDING OFFLINE SCOTT 147 4So this is SCOTT with SID=147 and SERIAL#=4. Since we know now the user, we can go to him/her and request to end the transaction gracefully i.e. issue a ROLLBACK or COMMIT. However, if this is not possible (say the user initiated the transaction and left for annual leave :) and trust me this happens) you may go ahead and kill the session to release the undo segments in the UNDOTBS1 tablespace.SQL> alter system kill session '147,4'; System altered. SELECT a.name,b.status , d.username , d.sid , d.serial# FROM v$rollname a,v$rollstat b, v$transaction c , v$session d WHERE a.usn = b.usn AND a.usn = c.xidusn AND c.ses_addr = d.saddr AND a.name IN ( SELECT segment_name FROM dba_segments WHERE tablespace_name = 'UNDOTBS1' ); no rows selectedAs we can see once the session is kills we don't see anymore segments occupied in the UNDOTBS1 tablespace. Lets drop UNDOTBS1.SQL> DROP TABLESPACE undotbs1 INCLUDING CONTENTS AND DATAFILES; DROP TABLESPACE undotbs1 INCLUDING CONTENTS AND DATAFILES * ERROR at line 1: ORA-30013: undo tablespace 'UNDOTBS1' is currently in useIf you are retaining undo data then you still won't be able to drop the tablespace because it is still in use by undo_retention. Let the UNDO_RETENTION time pass and then try to drop the tablespace. In my case it is 900 seconds i.e. 15 minutes.-- After 15 minutes. SQL> DROP TABLESPACE undotbs1 INCLUDING CONTENTS AND DATAFILES; Tablespace dropped.
To alter the password expiry policy for a certain user profile
in Oracle first check wich profile the user is in using:
select profile from DBA_USERS where username = <username>;
Then you can change the limit to never expire using:alter profile <profile_name> limit password_life_time UNLIMITED;
select resource_name,limit from dba_profiles where profile='<profile_name>';
SELECT
ts.tablespace_name,
TO_CHAR(SUM(NVL(fs.bytes,0))/1024/1024, '99,999,990.99') AS MB_FREE
FROM
user_free_space fs,
user_tablespaces ts,
user_users us
WHERE
fs.tablespace_name(+) = ts.tablespace_name
AND ts.tablespace_name(+) = us.default_tablespace
GROUP BY
ts.tablespace_name;
-- See what the current values are EXEC sp_configure;
select * from v$locked_object lo join dba_objects o on lo.object_id = o.object_id
where o.object_name = 'xxPACKAGE NAMExx' and o.object_type = 'PACKAGE';
First of all you can check if user password not expire:
SELECT LIMIT FROM dba_profiles WHERE resource_name ='FAILED_LOGIN_ATTEMPTS'
and PROFILE = (select profile from dba_users where username = 'SCOTT');
Replace scott with user you are interested in , if it is
unlimited or no rows selected it means it wont expire.You can disable passsword expiration for specified user:
SELECT PROFILE FROM dba_users WHERE username = 'User you are interested in';
When you know profile name, you can change it:
ALTER PROFILE <profile_name> LIMIT FAILED_LOGIN_ATTEMPTS UNLIMITED;ALTER PROFILE <profile_name> LIMIT PASSWORD_LIFE_TIME UNLIMITED;
Best regards.
USE YourDBGOEXEC sp_change_users_login 'Report'GOUSE YourDBGOEXEC sp_change_users_login 'Auto_Fix', 'ColdFusion', NULL, 'cf'GOUSE YourDBGOEXEC sp_change_users_login 'update_one', 'ColdFusion', 'ColdFusion'GOUSE YourDBGOEXEC sp_dropuser 'ColdFusion'GOYour log on session is no longer valid. Would you like to log back in so you can continue working? If you do not log in, any outstanding data changes in your forms will not be saved.
Your Session has expired, please login againSolution:
<session_timeout oa_var="s_sesstimeout">1800000</session_timeout>And set to the appropriate value. Note that s_sesstimeout is in milliseconds so multiple by (1000*60) to get the time in minutes that is represented in the profile option.
<session_timeout oa_var="s_sesstimeout">1800000</session_timeout>Then next time you run adconfig.sh (or a patch/clone does) then you won't have to reset profile options.