Internal Oracle Error in SYS.UTL_HTTP.READ_TEXT - ORA-6512 @ line 1336
I have a PLSQL program that performs an HTTP POST to fetch data from an external website. The website is returning the contents of a file in the HTTP response. This program has been working for years and just started giving us trouble recently at a particular client. The issue cannot be reproduced locally, only on a specific client machine when trying to download a particular set of XML files through this HTTP interface.
The stack trace is:
ORA-29273: HTTP request failed
ORA-06512: at "SYS.UTL_HTTP", line 1336
ORA-06502: PL/SQL: numeric or value error
ORA-06512: at "SYS.UTL_HTTP", line 1336The code in question is:
PROCEDURE SEND_REQUEST
p_REQUEST IN CLOB,
p_RESPONSE OUT CLOB,
p_HEADERNAMES OUT STRING_COLLECTION,
p_HEADERVALUES OUT STRING_COLLECTION,
p_ERRORMESSAGE OUT VARCHAR2
) IS
v_HTTP_REQ UTL_HTTP.REQ;
v_HTTP_RESP UTL_HTTP.RESP;
v_REQUEST_LEN NUMBER;
v_POS NUMBER;
v_COUNT NUMBER;
v_TEXT VARCHAR2(8192);
v_LEN NUMBER;
BEGIN
-- raise Request_Failed error if an HTTP error occurs
UTL_HTTP.SET_RESPONSE_ERROR_CHECK(TRUE);
UTL_HTTP.SET_DETAILED_EXCP_SUPPORT(FALSE);
-- extend timeout to 10 minutes
UTL_HTTP.SET_TRANSFER_TIMEOUT(60 * 10);
v_HTTP_REQ := UTL_HTTP.BEGIN_REQUEST(G_URL, 'POST');
-- disable cookies for this request
UTL_HTTP.SET_COOKIE_SUPPORT(v_HTTP_REQ, FALSE);
-- authentication
IF g_USERNAME IS NOT NULL THEN
UTL_HTTP.SET_AUTHENTICATION(v_HTTP_REQ, g_USERNAME, g_PASSWORD);
END IF;
-- upload request body
v_REQUEST_LEN := DBMS_LOB.GETLENGTH(p_REQUEST);
UTL_HTTP.SET_HEADER(v_HTTP_REQ, 'Content-Type', 'application/x-www-form-urlencoded');
UTL_HTTP.SET_HEADER(v_HTTP_REQ, 'Content-Length', v_REQUEST_LEN);
-- write the CLOB request data
v_POS := 1;
WHILE v_POS <= v_REQUEST_LEN LOOP
v_LEN := 8192;
DBMS_LOB.READ(p_REQUEST, v_LEN, v_POS, v_TEXT);
UTL_HTTP.WRITE_TEXT(v_HTTP_REQ, v_TEXT);
v_POS := v_POS + v_LEN;
END LOOP;
-- get the response
v_HTTP_RESP := UTL_HTTP.GET_RESPONSE(v_HTTP_REQ);
-- read it into CLOB
DBMS_LOB.CREATETEMPORARY(p_RESPONSE, TRUE);
DBMS_LOB.OPEN(p_RESPONSE, DBMS_LOB.LOB_READWRITE);
LOOP
BEGIN
UTL_HTTP.READ_TEXT(v_HTTP_RESP, v_TEXT, 8192);
EXCEPTION
WHEN UTL_HTTP.END_OF_BODY THEN
ERRS.LOG_AND_CONTINUE('Send_Request: Exeception occurred reading text from the http response.',
p_LOG_LEVEL => LOGS.C_LEVEL_INFO_MORE_DETAIL);
v_TEXT := '';
END;
EXIT WHEN NVL(LENGTH(v_TEXT), 0) = 0;
DBMS_LOB.WRITEAPPEND(p_RESPONSE, LENGTH(v_TEXT), v_TEXT);
END LOOP;
DBMS_LOB.CLOSE(p_RESPONSE);
-- gather response headers
p_HEADERNAMES := STRING_COLLECTION();
p_HEADERVALUES := STRING_COLLECTION();
v_COUNT := UTL_HTTP.GET_HEADER_COUNT(v_HTTP_RESP);
v_POS := 1;
WHILE v_POS <= v_COUNT LOOP
p_HEADERNAMES.EXTEND();
p_HEADERVALUES.EXTEND();
UTL_HTTP.GET_HEADER(v_HTTP_RESP, v_POS, p_HEADERNAMES(p_HEADERNAMES.LAST), p_HEADERVALUES(p_HEADERVALUES.LAST));
v_POS := v_POS + 1;
END LOOP;
UTL_HTTP.END_RESPONSE(v_HTTP_RESP);
-- success!
p_ERRORMESSAGE := NULL;
EXCEPTION
WHEN UTL_HTTP.REQUEST_FAILED THEN
ERRS.LOG_AND_CONTINUE('Send_Request: Exeception Request Failed caught.', p_LOG_LEVEL => LOGS.C_LEVEL_INFO_MORE_DETAIL);
WHEN OTHERS THEN
ERRS.LOG_AND_CONTINUE('Send_Request: Exeception Others caught.', p_LOG_LEVEL => LOGS.C_LEVEL_INFO_MORE_DETAIL);
END SEND_REQUEST;It fails specifically at the section that is reading text from the response:
UTL_HTTP.READ_TEXT(v_HTTP_RESP, v_TEXT, 8192);
...Any thoughts?
I have used a packet sniffer, Wireshark, to monitor the HTTP traffic between the website and database during the issue. There is nothing malformed with the Response content. No special chars that I can find. Etc.
The machine in question that is failing is running 10gR2.
I have done some searching and I found this forum post:
utl_http.read_text and multi-byte support
and this Oracle bug:
https://support.oracle.com/CSP/main/article?cmd=show&type=BUG&id=4015165&productFamily=Oracle
Not really much help.
Any help would be appreciated.
Thanks,
GatorPaul
Edited by: 939368 on Jun 7, 2012 2:27 PM
In this case, and most cases, the NLS_LENGTH_SEMANTICS is set to 'BYTE'. Realize that this is an Oracle application that we deploy into an external customer environment and we do not always have the ability to control NLS Settings.
So, based on your explanation, I would expect that an approach like this would fix it:
v_TEXT VARCHAR2(32766);
UTL_HTTP.READ_TEXT(v_HTTP_RESP, v_TEXT, 8192);
Here we are saying, get the next 8192 characters, but put that into a buffer that allows up to 32K bytes. This should allow for the enough room for up to 4 bytes per character. Am I understanding you correctly?
But here is my question:
I put a fix in place today, where I increased both the v_TEXT byte size and the GET_TEXT 'len' parameter to 32766 and it fixed the issue. By doing that, I am telling it: Give me the next 32766 characters and put it into a VARCHAR2(32766). Given your explanation, I would expect this to overflow the v_TEXT variable as well, or at least have the potential to do so.
We were processing 5 different XML responses. They were all failing originally. After the change, they all passed. Their sizes were 47K, 21K, 14K, 48K, and 21K. If the XML file was small, < 32K then maybe is slipped under the radar given the new buffer size of 32766. But what about the 2 files that were over 32K. Very curious on your thoughts. I did not have a loop counter in there to see how many times it was looping to parse the 48K file. With a new buffer size of 32K I would expect it to loop 2x. But, I know in this case, the file was streamed over the network using 14 smaller TCP packets, none of which were more than 9000 bytes. Maybe the PLSQL looped 14 times as well.
When the process was failing for all 5 files, I do know at that time it was always failing on the first loop (first 8192 characters).
Anyway, Thanks for the advice. I will let you guys know if I uncover anymore info.
G8torPaul
Edited by: G8torPaul on Jun 12, 2012 2:04 PM
Edited by: G8torPaul on Jun 12, 2012 2:04 PM
Edited by: G8torPaul on Jun 12, 2012 2:05 PM
Similar Messages
-
My customer has an issue, and error message as below:
<PRE>Oracle error 1403: java.sql.SQLException: ORA-01403: no data found ORA-06512:
at line 1 has been detected in FND_SESSION_MANAGEMENT.CHECK_SESSION. Your
session is no longer valid.</PRE>
Servlet error: An exception occurred. The current application deployment descriptors do not allow for including it in this response. Please consult the application log for details.
And customer’s statement is: Upgrade from EBS 11.5.10 to 12.1.3. Login the EBS, open any forms and put it in idle. Then refresh the form, error happens
Then, I checked ISP, and found two notes:
Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid (Doc ID 1284094.1)
Note 1319380.1: Webadi Gl Journal Posting Errors After Atg R12.1.3 (Doc ID 1319380.1)
But these two notes are both WebADI.
Following is the data collection from customer:
1. Run UNIX command to check .class file version:
strings $JAVA_TOP/oracle/apps/bne/utilities/BneViewerUtils.class | grep Header--> S$Header: BneViewerUtils.java 120.33.12010000.17 2010/11/21 22:19:58 amgonzal s$
2. Run SQL to check you patch level:
SELECT * FROM fnd_product_installations WHERE patch_level LIKE '%BNE%';--> R12.BNE.B.3
3. Run SQL to check patch '9940148' applied or not:
SELECT * FROM ad_bugs ad WHERE ad.bug_number = '9940148';--> No Rows returned
4. Run SQL to check patch '9785477' applied or not:
SELECT * FROM ad_bugs WHERE bug_number in ('9785477');-->
BUG_ID APPLICATION_SHORT_NAME BUG_NUMBER CREATION_DATE ARU_RELEASE_NAME CREATED_BY LAST_UPDATE_DATE LAST_UPDATED_BY TRACKABLE_ENTITY_ABBR BASELINE_NAME GENERIC_PATCH LANGUAGE
576982 11839583 2011/8/7 上午 08:20:36 R12 5 2011/8/7 上午 08:20:36 5 pjt B n US
516492 9785477 2011/6/12 上午 11:42:45 R12 5 2011/6/12 上午 11:42:45 5 bne B n US
546109 9785477 2011/6/12 下午 01:17:41 R12 5 2011/6/12 下午 01:17:41 5 bne B n ZHT
5. Run SQL to check the status of object ‘FND_SESSION_MANAGEMENT’
SELECT * FROM dba_objects do WHERE do.object_name = 'FND_SESSION_MANAGEMENT';-->
OWNER OBJECT_NAME SUBOBJECT_NAME OBJECT_ID DATA_OBJECT_ID OBJECT_TYPE CREATED LAST_DDL_TIME TIMESTAMP STATUS TEMPORARY GENERATED SECONDARY NAMESPACE EDITION_NAME
APPS FND_SESSION_MANAGEMENT 219425 PACKAGE 2004/10/30 下午 01:52:35 2011/8/7 上午 08:18:39 2011-08-07:08:18:26 VALID N N N 1
APPS FND_SESSION_MANAGEMENT 226815 PACKAGE BODY 2004/10/31 上午 01:05:40 2011/8/7 上午 08:18:54 2011-08-07:08:18:27 VALID N N N 2
So, my question is: Customer’s BneViewerUtils.java version is already 120.33.12010000.17, which greater than 120.33.12010000.14. Is there any others solutions for this issue? Does customer still need to apply patch '9940148' based on action plan of
Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid?
Customer's EBS version is 12.1.3; OS is HP-UX PA-RISC (64-bit); DB is 11.2.0.2.
Thanks,
JackieAnd customer’s statement is: Upgrade from EBS 11.5.10 to 12.1.3. Login the EBS, open any forms and put it in idle. Then refresh the form, error happens
Idle for how long? Is the issue with all sessions?
Please see these docs/links
User Sessions Get Timed Out Before Idle Time Parameter Values Are Reached [ID 1306678.1]
https://forums.oracle.com/forums/search.jspa?threadID=&q=Timeout+AND+R12&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001
Then, I checked ISP, and found two notes:
Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid (Doc ID 1284094.1)
Note 1319380.1: Webadi Gl Journal Posting Errors After Atg R12.1.3 (Doc ID 1319380.1)
But these two notes are both WebADI.Can you find any details about the error in Apache log files and in the application.log file?
Any errors in the database log file?
So, my question is: Customer’s BneViewerUtils.java version is already 120.33.12010000.17, which greater than 120.33.12010000.14. Is there any others solutions for this issue? No.
Does customer still need to apply patch '9940148' based on action plan ofIf the issue not with Web ADI, then ignore this patch. However, if you use Web ADI you could query AD_BUGS table and verify if you have the patch applied.
Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid?
Customer's EBS version is 12.1.3; OS is HP-UX PA-RISC (64-bit); DB is 11.2.0.2.If you could not find any details in the logs, please enable debug as per (R12, 12.1 - How To Enable and Collect Debug for HTTP, OC4J and OPMN [ID 422419.1]).
Thanks,
Hussein -
bnjr a tous,
j'ai un big probleme.
l'eureur "internal software error:. \ Vobulator \ block Planner \ BlockPlanner.cpp, line 217"
s'affiche a la derniere etape, c-à-d quant il faut copier sur dvd.
tout aide sera la bien venu.
merci
- NTSC
- plusieurs menus avec animation
- QUELQUE VIDEOS, montage fait avec premier pro
- windows 7J'ai le même problème, pourtant lorsque je fait une simulation le prog n'affiche aucun problème. J'ai importé ma séquence depuis première pro, j'ai rendu le diaporama. Quand je lance la génération il bug sur la line 217 nommé plus haut. J'ai fait un export du film en h.264 puis tenté de l'utiliser sur la time line mais ça bug aussi l'image reste figée. J'ai lu les conseils mais je comprends pas bien "enlever les marqueurs de chapitres à la fin des timelines". J'ai un menu, un diaporama et un sous menu avec 20 chapitre et j'utilise 4,44Go de l'espace DVD. J'attends de vos nouvelles car là je sais plus quoi faire du tout à part acheter un mac et monter sous final cut
-
Error while using utl_http.request :ORA-12535: TNS:operation timed
Hi.
I'm using 11g
I'm trying to use utl_http.request
I tried select utl_http.request('http://srvab.us.oracle.com') from dual;
and get the below error
Error report:
SQL Error: ORA-29273: HTTP request failed
ORA-06512: at "SYS.UTL_HTTP", line 1577
ORA-12535: TNS:operation timed out
ORA-06512: at line 1
29273. 00000 - "HTTP request failed"
*Cause: The UTL_HTTP package failed to execute the HTTP request.
*Action: Use get_detailed_sqlerrm to check the detailed error message.
Fix the error and retry the HTTP request.
I have tried the below steps after checking Oracle KM
BEGIN
DBMS_NETWORK_ACL_ADMIN.CREATE_ACL(acl => 'ACL_OPSLOG.xml',
description => 'ACL SRVAP AUTOSR PURPOSES',
principal => 'username',
is_grant => true,
privilege => 'connect',
start_date => null,
end_date => null );
COMMIT;
END;
BEGIN
DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL (
acl => 'ACL_OPSLOG.xml',
host => '*.us.oracle.com',
lower_port => null,
upper_port => null);
COMMIT;
END;
But still no luck.Please assist
Thanks
ArchanaAccording to the exception, the error is not ACL related, but network related.
Basic test. Connect to the Oracle server using a console (e.g. ssh or telnet into the server). On that server, test the network connectivity to the web server. E.g.
telnet srvab.us.oracle.com 80If this fails, then so will PL/SQL code in that Oracle server. -
Hi,
I am trying to exp a table from an oracle 9i db to an oracle 11g db.
exp USERID=user1/pass1@db9i TABLES=test FILE=test.dmp ROWS="y" statistics="none" GRANTS="n" INDEXES="n" TRIGGERS="n" CONSTRAINTS="n"
While trying to import i get an error
*"IMP-00017: following statement failed with ORACLE error 942:*
*"BEGIN SYS.DBMS_REPUTIL.SYNC_UP_REP('CYGENT_ADMIN','AGENT_ROOT_MAP'); END;"*
_when i do_
imp USERID=user2/pass2@db11g TABLES=test FILE=test.dmp FROMUSER=user1 TOUSER=user2 SHOW=Y
the last line i see is
*"BEGIN SYS.DBMS_REPUTIL.SYNC_UP_REP('CYGENT_ADMIN','AGENT_ROOT_MAP'); END;"*
_Question_
What do i need to do so that the last line (SYNC_UP_REP) is not included in the export dump.
Have tried searching for this but without much luck.
Appreciate the help.Explain your usage of Advanced Replication capabilities. Where, what, and why.
-
I am working in C++ in this environment:
$ which CC
/hep1/lang/sunstudio11/SUNWspro/prod/bin/CC
$ CC -V
CC: Sun C++ 5.8 Patch 121017-10 2007/02/21
$ uname -a
SunOS hep 5.9 Generic_118558-37 sun4u sparc SUNW,A70
I have run into the following internal compiler error more than once:
>> Assertion: (../lnk/v2mangler.cc, line 136)
while processing ./tempdir/xxx.c at line 0.
... where xxx.c is the preprocessed file. The error message is always the same (i.e. generated from line 136 of v2mangler.cc and complaining about line 0 of the preprocessed file). I have tried without success to isolate line(s) in my C++ source causing the error. It might help to know what the compiler is trying to do near line 136 of v2mangler.cc which triggers this error.This assertion prevents to mangle negative number. The source of this negative number is not clear without test case.
-
Internal (Oracle) Error of JPS/WSRP Output
The system consists of upgrated portal (AS 1.2 + Portal 1.4) with dedicated OC4j container (in the same server) where JPS/WSRP portlets are installed. When testing my portlets I've founded the error I'm writing about.
Sometimes portlet fails to show the result. This error is caused not by an exception raised while generating the output HTML, but after this, when execution exits the rendering entry point of the portel (doDispatch() methof of GenericPortlet). No this is a problem of some side-effect: I've saved the output into the file and then written the portlet just outputing this file into portlet_response.getPortletOutputStream() (UTF-8 HTML).
I found that this error is HTML-output depended. I slightly modified that HTML file, just added a space in its middle, and the error disappeared.
NOTE THAT IT IS NOT JUST THE PROBLEM OF MINE. Everybody creating JSR portlets may meet it. It is an error somewhere within wsrp-install.jar implementation.
If those who responsible for JSR portlets implementation needs the error file, I can send it. (I've met this error not once, with different HTML content.)The system consists of upgrated portal (AS 1.2 + Portal 1.4) with dedicated OC4j container (in the same server) where JPS/WSRP portlets are installed. When testing my portlets I've founded the error I'm writing about.
Sometimes portlet fails to show the result. This error is caused not by an exception raised while generating the output HTML, but after this, when execution exits the rendering entry point of the portel (doDispatch() methof of GenericPortlet). No this is a problem of some side-effect: I've saved the output into the file and then written the portlet just outputing this file into portlet_response.getPortletOutputStream() (UTF-8 HTML).
I found that this error is HTML-output depended. I slightly modified that HTML file, just added a space in its middle, and the error disappeared.
NOTE THAT IT IS NOT JUST THE PROBLEM OF MINE. Everybody creating JSR portlets may meet it. It is an error somewhere within wsrp-install.jar implementation.
If those who responsible for JSR portlets implementation needs the error file, I can send it. (I've met this error not once, with different HTML content.) -
hi
I am getting the following error while calling the procedure in the batch process
ORA-06512: at "SYS.UTL_HTTP", line 1022
ORA-29270: too many open HTTP requests
Could you please help me on this? As this is getting affected in the live databases.
ORA-06512: at "SYS.UTL_HTTP", line 1022
ORA-29270: too many open HTTP requests
CREATE OR REPLACE PROCEDURE Send_To_Spg(
PTRANSACTION_ID IN VARCHAR2,
PCHANNEL_TYPE IN VARCHAR2 DEFAULT NULL,
PCSS_ORDER_NUMBER IN VARCHAR2 DEFAULT NULL,
PTELEPHONE_NUMBER IN VARCHAR2 DEFAULT NULL,
PSCENARIO_TYPE IN VARCHAR2 DEFAULT NULL,
PCUSTOMER_REQUIRED_DATE IN VARCHAR2 DEFAULT NULL,
PCUSTOMER_REQUIRED_TIME IN VARCHAR2 DEFAULT NULL,
PCANCELLATION_REASON IN VARCHAR2 DEFAULT NULL,
PCANCELLATION_NOTES IN VARCHAR2 DEFAULT NULL,
PSMPF_RETENTION IN VARCHAR2 DEFAULT NULL,
PEMERGENCY_WINBACK IN VARCHAR2 DEFAULT NULL,
PCSS_PROJECT_ID IN VARCHAR2 DEFAULT NULL,
PCSS_ORDER_NOTES IN VARCHAR2 DEFAULT NULL,
PREASON_FOR_CESSATION IN VARCHAR2 DEFAULT NULL,
P_RESPONSE OUT VARCHAR2,
PSMART_USER_ID IN VARCHAR2 DEFAULT NULL,
PORACLE_ERROR OUT VARCHAR2,
PORACLE_ERROR_MESSAGE OUT VARCHAR2,
PRESPONSE_TIME OUT NUMBER,
PDATA_TRANSFER_STATUS OUT VARCHAR2)
IS
v_scenario_type VARCHAR2(20); -- Varialble to Hold Time Out of every request to SPG
v_transaction_time NUMBER; -- Total time in which Request to SPG was processed
v_record_inserted_at DATE; -- Date/Time about the record insertion to the Error Handler
v_start_time NUMBER; -- Variable to hold Start Time for calculationg Transaction Time
v_url VARCHAR2(32767);-- URL to use when sending data to SPG
vtransaction_id VARCHAR2(18); -- Variable to hold Transaction ID for the request
v_buffer VARCHAR2(32760);-- Variable to read response from the SPG interface
v_timeout PLS_INTEGER; -- Time Out for each Transaction
v_oracle_err_msg VARCHAR2(600); -- Variable to hold Oracle Error Message
v_resp UTL_HTTP.RESP; -- Response Object
v_req UTL_HTTP.REQ; -- Request Object
v_userid_pwd SMT_ORACLE_PARAMETERS%ROWTYPE; --Variable declared to contain User ID & Password
vl_RetCode VARCHAR2(5000);
vl_std_returnCode VARCHAR2(3000);
--PDATA_TRANSFER_STATUS Holds the Data Transfer Status which can have possible values as
-- N => Data Has not been sent to SPG
-- Y => Received Successful response from SPG
-- F => On the First try to Send data to SPG Oracle Error Occured or response from SPG was a faulure
-- S => On the Second try to Send data to SPG Oracle Error Occured or response from SPG was a faulure
-- T => Data Has been transferred to the Error Log Table
-- X => Data need not be transfered to Error Log Table.
--Location of the timeout, URL & User Id & Password in Standing Data.
c_url_stopwlr SMT_ORACLE_PARAMETERS.PARAMETER_CODE%TYPE:='SPG_WLR';-- Stop WLR URL
c_url_cancelown SMT_ORACLE_PARAMETERS.PARAMETER_CODE%TYPE:='SPG_OWN';-- Cancel own URL
c_url_cancelother SMT_ORACLE_PARAMETERS.PARAMETER_CODE%TYPE:='SPG_OTH';-- Cancel other URL
c_url_amendcrd SMT_ORACLE_PARAMETERS.PARAMETER_CODE%TYPE:='SPG_CRD';--Amend CRD URL
c_spg_useridpwd SMT_ORACLE_PARAMETERS.PARAMETER_CODE%TYPE:='SPGIDPWD'; --Contains user id and pwd
ctimeout smt_parameters.parameter_code%TYPE:='SPGTO'; --This holds the timeout parameter
BEGIN
--In case the calling batch process can pass this value this SQL read will not be required & can be deleted
--Read data transfer status for the transaction Id
SELECT data_transfer_status INTO PDATA_TRANSFER_STATUS FROM SPG_INTERFACE_TABLE
WHERE transaction_id = PTRANSACTION_ID;
--Record the start time
v_start_time:=DBMS_UTILITY.GET_TIME;
--If Data transfer status is S then send the record to error handler
IF PDATA_TRANSFER_STATUS = 'S' THEN
Error_Handler(PTRANSACTION_ID,PSMART_USER_ID,PORACLE_ERROR,PORACLE_ERROR_MESSAGE,v_record_inserted_at,PDATA_TRANSFER_STATUS);
ELSE
--In case Data Tranfer Status is something other than S then send the request to SPG
--Initialise other variables which will be populated during the journey
P_RESPONSE := '';
PORACLE_ERROR := NULL;
PORACLE_ERROR_MESSAGE := NULL;
PRESPONSE_TIME := 0;
--Read timeout parameter from standing data.
BEGIN
SELECT VALUE INTO v_timeout FROM smt_parameters WHERE parameter_code=ctimeout;
EXCEPTION
WHEN NO_DATA_FOUND THEN
v_timeout:=30;
WHEN OTHERS THEN
v_timeout:=30;
END;
-- Construct the URL for Stop WLR Scenario
IF PSCENARIO_TYPE = 'STOP_WLR' THEN
BEGIN
-- Read the Initial URL from Standing Data
SELECT VALUE
INTO v_url
FROM SMT_ORACLE_PARAMETERS
WHERE parameter_code = c_url_stopwlr
AND host_id = ( SELECT host_id
FROM SMART_HOSTS A
WHERE EXISTS ( SELECT 1
FROM DB_PARAMETERS b
WHERE A.hostname = b.hostname
AND A.database_id = b.database_id));
--handle unforseen exception
EXCEPTION
WHEN NO_DATA_FOUND THEN
v_url:='Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_winback_details'; --After testing the same, URL will be fetched from the Query
WHEN OTHERS THEN
v_url:='Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_winback_details'; --After testing the same, URL will be fetched from the Query
END;
--construct the URL depending on the parameters to be passed to the url
v_url := v_url || '?';
v_url := v_url || 'p_data_entered=' || Smart_Urlencode('xmloverhttp') || '&';
v_url := v_url || 'p_channel_type=' || Smart_Urlencode(PCHANNEL_TYPE)|| '&';
v_url := v_url || 'p_css_start_order_no=' || Smart_Urlencode(PCSS_ORDER_NUMBER)|| '&';
v_url := v_url || 'p_tel_no=' || Smart_Urlencode(PTELEPHONE_NUMBER)|| '&';
v_url := v_url || 'p_crd=' || Smart_Urlencode(PCUSTOMER_REQUIRED_DATE)|| '&';
v_url := v_url || 'p_take_over_time=' || Smart_Urlencode(PCUSTOMER_REQUIRED_TIME)|| '&';
v_url := v_url || 'p_retainsmpf=' || Smart_Urlencode(PSMPF_RETENTION)|| '&';
--v_url := v_url || 'p_emergency_winback=' || Smart_Urlencode(PEMERGENCY_WINBACK)|| '&';
v_url := v_url || 'p_projectno=' || Smart_Urlencode(PCSS_PROJECT_ID)|| '&';
v_url := v_url || 'p_ordernotes=' || Smart_Urlencode(PCSS_ORDER_NOTES)|| '&';
v_url := v_url || 'p_reason_cessation=' || Smart_Urlencode(PREASON_FOR_CESSATION);
ELSIF PSCENARIO_TYPE='CANCEL_OWN' THEN
--Fetch the URL for cancel own from standing data.
BEGIN
SELECT VALUE
INTO v_url
FROM SMT_ORACLE_PARAMETERS
WHERE parameter_code = c_url_cancelown
AND host_id = ( SELECT host_id
FROM SMART_HOSTS A
WHERE EXISTS ( SELECT 1
FROM DB_PARAMETERS b
WHERE A.hostname = b.hostname
AND A.database_id = b.database_id));
--handle unforseen exception
EXCEPTION
WHEN NO_DATA_FOUND THEN
v_url := 'Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_cancelown_details'; --After testing the same, URL will be fetched from the Query
WHEN OTHERS THEN
v_url := 'Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_cancelown_details'; --After testing the same, URL will be fetched from the Query
END;
--construct the URL
v_url := v_url || '?';
v_url := v_url || 'p_data_entered=' ||Smart_Urlencode('xmloverhttp')|| '&';
v_url := v_url || 'p_channel_type=' ||Smart_Urlencode(PCHANNEL_TYPE)|| '&';
v_url := v_url || 'p_css_start_order_no=' ||Smart_Urlencode(PCSS_ORDER_NUMBER)|| '&';
v_url := v_url || 'p_tel_no=' ||Smart_Urlencode(PTELEPHONE_NUMBER)|| '&';
v_url := v_url || 'p_cancel_reason=' ||Smart_Urlencode(PCANCELLATION_REASON)|| '&';
v_url:= v_url || 'p_cancel_notes=' ||Smart_Urlencode(PCANCELLATION_NOTES);
ELSIF PSCENARIO_TYPE='CANCEL_OTHER' THEN
--Fetch the URL for cancel own from standing data.
BEGIN
SELECT VALUE
INTO v_url
FROM SMT_ORACLE_PARAMETERS
WHERE parameter_code = c_url_cancelother
AND host_id = ( SELECT host_id
FROM SMART_HOSTS A
WHERE EXISTS ( SELECT 1
FROM DB_PARAMETERS b
WHERE A.hostname = b.hostname
AND A.database_id = b.database_id));
--handle unforseen exception
EXCEPTION
WHEN NO_DATA_FOUND THEN
v_url := 'Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_cancelother_details'; --After testing the same, URL will be fetched from the Query
WHEN OTHERS THEN
v_url := 'Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_cancelother_details'; --After testing the same, URL will be fetched from the Query
END;
--construct the URL
v_url := v_url || '?';
v_url := v_url || 'p_data_entered=' ||Smart_Urlencode('xmloverhttp')|| '&';
v_url := v_url || 'p_channel_type=' ||Smart_Urlencode(PCHANNEL_TYPE)|| '&';
v_url := v_url || 'p_css_stop_order_no=' ||Smart_Urlencode(PCSS_ORDER_NUMBER)|| '&';
v_url := v_url || 'p_tel_no=' ||Smart_Urlencode(PTELEPHONE_NUMBER)|| '&';
v_url := v_url || 'p_cancel_reason=' ||Smart_Urlencode(PCANCELLATION_REASON);
ELSIF Pscenario_type='AMEND_CRD' THEN
--Fetch the URL for cancel own from standing data.
BEGIN
SELECT VALUE
INTO v_url
FROM SMT_ORACLE_PARAMETERS
WHERE parameter_code = c_url_amendcrd
AND host_id = ( SELECT host_id
FROM SMART_HOSTS A
WHERE EXISTS ( SELECT 1
FROM DB_PARAMETERS b
WHERE A.hostname = b.hostname
AND A.database_id = b.database_id));
--handle unforseen exception
EXCEPTION
WHEN NO_DATA_FOUND THEN
v_url := 'Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_amendcrd_details'; -- After testing the same , URL will be fetched from the Query
WHEN OTHERS THEN
v_url := 'Http://wls.brassi1c.devenv1.bt.co.uk:64738/pls/spgenv/spg_btrc.add_btrc_amendcrd_details'; -- After testing the same , URL will be fetched from the Query
END;
--construct the URL
v_url := v_url || '?';
v_url := v_url || 'p_data_entered=' ||Smart_Urlencode('xmloverhttp')|| '&';
v_url := v_url || 'p_channel_type=' ||Smart_Urlencode(PCHANNEL_TYPE)|| '&';
v_url := v_url || 'p_css_start_order_no=' ||Smart_Urlencode(PCSS_ORDER_NUMBER)|| '&';
v_url := v_url || 'p_tel_no=' ||Smart_Urlencode(PTELEPHONE_NUMBER)|| '&';
v_url := v_url || 'p_crd=' ||Smart_Urlencode(PCUSTOMER_REQUIRED_DATE)|| '&';
v_url := v_url || 'p_css_change_order_numbers='||Smart_Urlencode(PCANCELLATION_REASON);
END IF;
--this is start of setting parameters for utl http object. the show begins...
utl_http.set_transfer_timeout(v_timeout);
--Set the wallet
--XXXXX e.g.UTL_HTTP.SET_WALLET(?file:DirectoryPath?,'put password here?);
--Set proxy
--YYYYY e.g. utl_http.set_proxy(p_proxy_in, p_no_proxy_domains_in);
v_url := REPLACE(v_url,'%27%27','%27'); -- Fix to ensure Double Quotes are converted to Single Quotes
--set the required URL to utl http.
v_req := utl_http.begin_request(v_url);
--Authentication setting
--Fetch the user id and password from stnding data.
BEGIN
SELECT *
INTO v_userid_pwd
FROM SMT_ORACLE_PARAMETERS
WHERE PARAMETER_CODE=c_spg_useridpwd
AND HOST_ID = ( SELECT HOST_ID
FROM SMART_HOSTS A
WHERE EXISTS ( SELECT 1
FROM DB_PARAMETERS B
WHERE A.HOSTNAME = B.HOSTNAME
AND A.DATABASE_ID = B.DATABASE_ID));
EXCEPTION
WHEN NO_DATA_FOUND THEN
P_RESPONSE := 'ORACLE_ERROR: USER id AND Password NOT configured IN SMT_ORACLE_PARAMETERS:SPGIDPWD';
WHEN OTHERS THEN
P_RESPONSE := 'ORACLE_ERROR: USER id AND Password NOT configured IN SMT_ORACLE_PARAMETERS:SPGIDPWD';
END;
--utl_http.set_authentication(v_req, p_username_in, p_password_in);
utl_http.set_authentication(v_req, v_userid_pwd.description, v_userid_pwd.VALUE);
v_resp := utl_http.get_response(v_req);
--Fill in the the response time
PRESPONSE_TIME := (DBMS_UTILITY.GET_TIME - v_start_time)/100;
IF v_resp.reason_phrase = 'OK' THEN
-- Fetch the response
BEGIN
LOOP
utl_http.read_line(v_resp, v_buffer);
P_RESPONSE := P_RESPONSE || v_buffer;
END LOOP;
utl_http.end_response(v_resp);
EXCEPTION
WHEN utl_http.end_of_body THEN
utl_http.end_response(v_resp);
P_RESPONSE := P_RESPONSE || v_buffer;
END;
ELSIF v_resp.reason_phrase <> 'OK' OR P_RESPONSE = '' THEN
--error handling starts
--If the HTTP Status is not OK then store the error information
PORACLE_ERROR_MESSAGE := 'Status Code: '|| v_resp.STATUS_CODE||'. Reason Phrase ' ||v_resp.reason_phrase;
P_RESPONSE := 'ORACLE_ERROR: '|| ' Reason Phrase ' || v_resp.reason_phrase;
PORACLE_ERROR := v_resp.STATUS_CODE;
END IF;
--In case we got successful response from SPG
IF P_RESPONSE LIKE '%<RetCde>0</RetCde>%' THEN
PDATA_TRANSFER_STATUS := 'Y';
ELSE
BEGIN
SELECT message
INTO vl_std_returnCode
FROM SMT_MESSAGES
WHERE MESSAGE_CODE='SPGANTIDTS';
EXCEPTION
WHEN NO_DATA_FOUND THEN
vl_std_returnCode := '-12545,-29273,-1,401,';
WHEN OTHERS THEN
vl_std_returnCode := '-12545,-29273,-1,401,';
END;
--In case there was an error do not update Data Transfer Status
IF PORACLE_ERROR <> NULL AND INSTR(vl_std_returnCode, PORACLE_ERROR || ',', 1, 1) <> 0 THEN
PDATA_TRANSFER_STATUS:=PDATA_TRANSFER_STATUS;
ELSE
vl_RetCode := SUBSTR(P_RESPONSE, INSTR(P_RESPONSE,'<RetCde>', 1, 1),
INSTR(P_RESPONSE,'</RetCde>',1,1)+9 - INSTR(P_RESPONSE,'<RetCde>', 1, 1));
BEGIN
SELECT VALUE
INTO vl_std_returnCode
FROM SMT_ORACLE_PARAMETERS
WHERE PARAMETER_CODE='SPGRCS'
AND HOST_ID = ( SELECT HOST_ID
FROM SMART_HOSTS A
WHERE EXISTS ( SELECT 1
FROM DB_PARAMETERS B
WHERE A.HOSTNAME = B.HOSTNAME
AND A.DATABASE_ID = B.DATABASE_ID));
EXCEPTION
WHEN NO_DATA_FOUND THEN
vl_std_returnCode := '<RetCde>4244</RetCde><RetCde>4245</RetCde><RetCde>4246</RetCde>';
WHEN OTHERS THEN
vl_std_returnCode := '<RetCde>4244</RetCde><RetCde>4245</RetCde><RetCde>4246</RetCde>';
END;
IF INSTR(vl_std_returnCode, vl_RetCode, 1, 1) <> 0 THEN
--needs not to re attempted.
PDATA_TRANSFER_STATUS:='X';
ELSE
--In case we did'nt got SUCCESSFUL response FROM SPG THEN UPDATE the Data Transfer Status so that the failed requests can be picked up BY the NEXT batch job RUN
IF PDATA_TRANSFER_STATUS='N' THEN
--initially if data transfer status was N then update it now to F
PDATA_TRANSFER_STATUS := 'F';
ELSIF PDATA_TRANSFER_STATUS='F' THEN
--initially if data transfer status was N then update it now to S
PDATA_TRANSFER_STATUS := 'S';
END IF;
END IF;
END IF;
END IF;
--Now Update all the modified Values
UPDATE SPG_INTERFACE_TABLE
SET response = P_RESPONSE,
data_transfer_status = PDATA_TRANSFER_STATUS,
oracle_error = PORACLE_ERROR,
oracle_error_message = PORACLE_ERROR_MESSAGE,
response_time = PRESPONSE_TIME
WHERE transaction_id = PTRANSACTION_ID;
COMMIT;
END IF;
EXCEPTION
WHEN OTHERS THEN
--Handling the unhandled exception
PORACLE_ERROR := SQLCODE;
PORACLE_ERROR_MESSAGE := SQLERRM;
P_RESPONSE := 'ORACLE_ERROR: '|| PORACLE_ERROR_MESSAGE;
PRESPONSE_TIME := (DBMS_UTILITY.GET_TIME - v_start_time)/100;
SELECT data_transfer_status INTO PDATA_TRANSFER_STATUS
FROM SPG_INTERFACE_TABLE
WHERE transaction_id=PTRANSACTION_ID;
--New functionality to update the oracle error and oracle error message and not the Data Transfer Status
BEGIN
SELECT message
INTO vl_std_returnCode
FROM SMT_MESSAGES
WHERE MESSAGE_CODE='SPGANTIDTS';
EXCEPTION
WHEN NO_DATA_FOUND THEN
vl_std_returnCode := '-12545,-29273,-1,';
WHEN OTHERS THEN
vl_std_returnCode := '-12545,-29273,-1,';
END;
vl_RetCode := PORACLE_ERROR || ',';
IF INSTR(vl_std_returnCode, vl_RetCode, 1, 1) <> 0 THEN
--If the error is found in above maintained standing data do not change the Data Transfer Status
pdata_transfer_status:=pdata_transfer_status;
ELSE
IF pdata_transfer_status='N' THEN
PDATA_TRANSFER_STATUS := 'F';
DBMS_OUTPUT.PUT_LINE('DUE TO ERROR DATA COULDN''T GET TRANSFERED TO SPG FOR TRANSACTION'||' '||PTRANSACTION_ID);
DBMS_OUTPUT.PUT_LINE(SQLERRM);
ELSIF pdata_transfer_status='F' THEN
PDATA_TRANSFER_STATUS := 'S';
DBMS_OUTPUT.PUT_LINE('DUE TO ERROR DATA COULDN''T GET TRANSFERED TO SPG FOR TRANSACTION'||' '||PTRANSACTION_ID);
DBMS_OUTPUT.PUT_LINE(SQLERRM);
ELSE
DBMS_OUTPUT.PUT_LINE('Failure WHEN sending data TO Error LOG. Data Transfer Status IS ' || PDATA_TRANSFER_STATUS || '. TRANSACTION ID '|| PTRANSACTION_ID);
END IF;
END IF;
--Now update all the information gathered above to the table
UPDATE SPG_INTERFACE_TABLE
SET response = P_RESPONSE,
data_transfer_status = PDATA_TRANSFER_STATUS,
oracle_error = PORACLE_ERROR,
oracle_error_message = PORACLE_ERROR_MESSAGE,
response_time = PRESPONSE_TIME
WHERE transaction_id = PTRANSACTION_ID;
COMMIT;
END;
/I have fixed the problem by own.
Seems there are some while space in the endpoint url.
Fix
http_req:= utl_http.begin_request
trim(l_endpoint_url)
,'POST'
,'HTTP/1.1'
It works...
Regards
BS -
Oracle error ORA-00600 when using Oracle 10g and Sun One Web Server 6.1
I have a java application that was running under Solaris 8 and Oracle 9i. I am trying to get it up and running on a new server that is configured with Solaris 9 and Oracle 10g. Whenever the application tries to connect to the database it receives the following error: ORA-00600 [ttcgcshnd-1][0]. My research indicates that this is an internal Oracle error that represents a low level unexpected condition. I have looked through my configuration for the Web Server and I have not been able to determine the cause of this problem. My DBA tells me that we have the latest patch installed for Oracle! Has anyone encountered this problem before? Any help would be greatly appreciated!
If the problem is also present in a SWING app, i.e. outside the web server, then it is porbably something external to the webserver.
I think you should ensure that the driver and database are compatible with each other. It is very likely that you need a new jdbc driver for the new database.
download from here http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/htdocs/jdbc101020.html
try the ojdbc14.jar -
Getting error : ORA-00600 Internal code error
Hi,
Can any one tell why im getting ORA- 00600 : Internal code error.
thanks,
SumanHello Suman,
The "ORA- 00600 : Internal code error" is generic error and very difficult to resolve.
Please contact Oracle Support (if you have met link support)
Thanks
With Regards
Hemant Joshi.
Bangalore. -
Good Morning All,
One of our RMAN backups is failing with the following error message. Any suggestions would be greatly appreciated.
==================================================================================================
Starting backup at 12/30/2008 22:03:47
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of backup command at 12/30/2008 22:03:47
RMAN-06004: ORACLE error from recovery catalog database: ORA-00904: : invalid identifier
RMAN>
RMAN> ##BACKUP ARCHIVELOG ALL FORMAT '%d_bkp_al_%t_Set%s_Piece%p' delete input;
2>
3> # DELETE ARCHIVELOG UNTIL TIME 'SYSDATE-7';
4>
5> # check if database can be restored
6> # RESTORE DATABASE VALIDATE;
7>
8> # check if controlfile can be restored
9> ##RESTORE CONTROLFILE to '/backups/admin/custpr/custpr_bkp_cntlfile.ctl' VALIDATE;
10>
11> # check if archivelogs for the past two weeks can be restored
12> # RESTORE ARCHIVELOG FROM TIME 'SYSDATE-7' VALIDATE;
13>
14> # - Verify all backups on backup media are intact
15> # CROSSCHECK BACKUP OF DATABASE;
16>
17> # - Display a list of files that need to be backed up based on the retention
18> # policy. For this case study, files that don't have at least 1 backups
19> # will be reported.
20> REPORT NEED BACKUP;
RMAN retention policy will be applied to the command
RMAN retention policy is set to recovery window of 7 days
Report of files whose recovery needs more than 7 days of archived logs
File Days Name
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of report command at 12/30/2008 22:03:48
RMAN-06004: ORACLE error from recovery catalog database: ORA-00904: : invalid identifier
RMAN>
RMAN> # - delete un-necessary backups. This command deletes backups based on the
2> # retention policy.
3> ######### commented out DELETE OBSOLETE - TSM not configured to delete on 68
4> #########DELETE OBSOLETE;
5>
6> # - get complete list of existing backups
7> LIST BACKUP;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of list command at 12/30/2008 22:03:49
RMAN-06004: ORACLE error from recovery catalog database: ORA-00904: : invalid identifier
RMAN>
RMAN> #-end of file-
2> **end-of-file**
RMAN>
Edited by: ORA_UMAIR on Dec 31, 2008 7:51 AMThis Oracle Database is 9.2.0.6.0. Here is the complete log file. The RMAN script that I am using ran successfully many times before.
====================================================================================================
Recovery Manager: Release 9.2.0.6.0 - 64bit Production
Copyright (c) 1995, 2002, Oracle Corporation. All rights reserved.
RMAN>
connected to recovery catalog database
RMAN>
connected to target database: CUSTPR (DBID=525071053)
RMAN>
RMAN> #########################################################################
2> # LEVEL 0 BACKUP #
3> #########################################################################
4>
5> # Configure backups to be written to disk.
6> CONFIGURE DEFAULT DEVICE TYPE TO DISK;
old RMAN configuration parameters:
CONFIGURE DEFAULT DEVICE TYPE TO DISK;
new RMAN configuration parameters:
CONFIGURE DEFAULT DEVICE TYPE TO DISK;
new RMAN configuration parameters are successfully stored
starting full resync of recovery catalog
full resync complete
RMAN>
RMAN> # Set the retention policy to a recovery window of 7 days. This ensures that
2> # RMAN retains all backups needed to recover the database to any point in time
3> # in the last 7 days. You can use the DELETE OBSOLETE command to delete
4> # backups that are no longer required by the retention policy. To exclude a
5> # backup from consideration by the policy, you can use KEEP option with the
6> # BACKUP command.
7> CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
old RMAN configuration parameters:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
new RMAN configuration parameters:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
new RMAN configuration parameters are successfully stored
starting full resync of recovery catalog
full resync complete
RMAN>
RMAN> # Configure RMAN to use two disk channels for backup, restore, recovery, and
2> # maintenance operations.
3> CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
old RMAN configuration parameters:
CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
new RMAN configuration parameters:
CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
new RMAN configuration parameters are successfully stored
starting full resync of recovery catalog
full resync complete
RMAN>
RMAN> # Configure RMAN to write disk backups to the /backup directory.
2> # The format specifier %t is replaced with a 4-byte timestamp, %s with the
3> # backup set number, and %p with the backup piece number.
4> CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/backups/admin/custpr/%d_bkp_df%t_Set%s_Piece%p';
old RMAN configuration parameters:
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/backups/admin/custpr/%d_bkp_df%t_Set%s_Piece%p';
new RMAN configuration parameters:
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/backups/admin/custpr/%d_bkp_df%t_Set%s_Piece%p';
new RMAN configuration parameters are successfully stored
starting full resync of recovery catalog
full resync complete
RMAN>
RMAN> # Configure RMAN to back up the control file after each backup.
2> CONFIGURE CONTROLFILE AUTOBACKUP ON;
old RMAN configuration parameters:
CONFIGURE CONTROLFILE AUTOBACKUP ON;
new RMAN configuration parameters:
CONFIGURE CONTROLFILE AUTOBACKUP ON;
new RMAN configuration parameters are successfully stored
starting full resync of recovery catalog
full resync complete
RMAN>
RMAN> # Configure RMAN to write controlfile autobackups to the /backup directory.
2> CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/backups/admin/custpr/%d_bkp_cf%F';
old RMAN configuration parameters:
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/backups/admin/custpr/%d_bkp_cf%F';
new RMAN configuration parameters:
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/backups/admin/custpr/%d_bkp_cf%F';
new RMAN configuration parameters are successfully stored
starting full resync of recovery catalog
full resync complete
RMAN>
RMAN> # Enable the backup optimization feature introduced in 9i to make sure that
2> # RMAN won't backup an archivelog or datafile if there already exists a backup
3> # of that file. The FORCE option can be used to override optimization on a
4> # specific BACKUP command.
5> CONFIGURE BACKUP OPTIMIZATION ON;
old RMAN configuration parameters:
CONFIGURE BACKUP OPTIMIZATION ON;
new RMAN configuration parameters:
CONFIGURE BACKUP OPTIMIZATION ON;
new RMAN configuration parameters are successfully stored
starting full resync of recovery catalog
full resync complete
RMAN>
RMAN> # Use the SHOW ALL command to see the current configuration settings.
2> SHOW ALL ;
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE DEFAULT DEVICE TYPE TO DISK;
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE 'SBT_TAPE' TO '%d_bkp_cf%F';
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '/backups/admin/custpr/%d_bkp_cf%F';
CONFIGURE DEVICE TYPE 'SBT_TAPE' PARALLELISM 1;
CONFIGURE DEVICE TYPE DISK PARALLELISM 1;
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE SBT_TAPE TO 1; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE SBT_TAPE TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE CHANNEL DEVICE TYPE 'SBT_TAPE' FORMAT '%d_bkp_df%t_Set%s_Piece%p';
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/backups/admin/custpr/%d_bkp_df%t_Set%s_Piece%p';
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO '/orahome2/custprdb/9.2.0/dbs/snapcf_custpr.f'; # default
RMAN>
RMAN> # The following commands are run each day to start the backup cycle.
2> # The steps are:
3> # - Take an incremental level 0 backup of the database. A level 0 backup is
4> # a complete backup of the entire file which can be used as the basis
5> # for a subsequent incremental backup.
6> # - Backup all archivelogs that have not already been backed up.
7> # - Delete on-disk archivelogs older than seven days.
8>
9> BACKUP INCREMENTAL LEVEL 0 FORMAT '/backups/admin/custpr/%d_bkp_df%t_Set%s_Piece%p'
10> DATABASE maxsetsize 33G
11> PLUS ARCHIVELOG FORMAT '/backups/admin/custpr/%d_bkp_al%t_Set%s_Piece%p'
12> delete all input;
Starting backup at 12/30/2008 22:01:40
current log archived
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=11 devtype=DISK
channel ORA_DISK_1: starting archive log backupset
channel ORA_DISK_1: specifying archive log(s) in backup set
input archive log thread=1 sequence=8008 recid=7910 stamp=674638862
input archive log thread=1 sequence=8009 recid=7911 stamp=674671207
input archive log thread=1 sequence=8010 recid=7912 stamp=674697380
input archive log thread=1 sequence=8011 recid=7913 stamp=674780433
input archive log thread=1 sequence=8012 recid=7914 stamp=674784211
input archive log thread=1 sequence=8013 recid=7915 stamp=674863288
input archive log thread=1 sequence=8014 recid=7916 stamp=674863300
channel ORA_DISK_1: starting piece 1 at 12/30/2008 22:01:41
channel ORA_DISK_1: finished piece 1 at 12/30/2008 22:03:47
piece handle=/backups/admin/custpr/CUSTPR_bkp_al674863300_Set3083_Piece1 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:02:07
channel ORA_DISK_1: deleting archive log(s)
archive log filename=/custpr/arch/arch_custpr_8008.log recid=7910 stamp=674638862
archive log filename=/custpr/arch/arch_custpr_8009.log recid=7911 stamp=674671207
archive log filename=/custpr/arch/arch_custpr_8010.log recid=7912 stamp=674697380
archive log filename=/custpr/arch/arch_custpr_8011.log recid=7913 stamp=674780433
archive log filename=/custpr/arch/arch_custpr_8012.log recid=7914 stamp=674784211
archive log filename=/custpr/arch/arch_custpr_8013.log recid=7915 stamp=674863288
archive log filename=/custpr/arch/arch_custpr_8014.log recid=7916 stamp=674863300
Finished backup at 12/30/2008 22:03:47
Starting backup at 12/30/2008 22:03:47
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of backup command at 12/30/2008 22:03:47
RMAN-06004: ORACLE error from recovery catalog database: ORA-00904: : invalid identifier
RMAN>
RMAN> ##BACKUP ARCHIVELOG ALL FORMAT '%d_bkp_al_%t_Set%s_Piece%p' delete input;
2>
3> # DELETE ARCHIVELOG UNTIL TIME 'SYSDATE-7';
4>
5> # check if database can be restored
6> # RESTORE DATABASE VALIDATE;
7>
8> # check if controlfile can be restored
9> ##RESTORE CONTROLFILE to '/backups/admin/custpr/custpr_bkp_cntlfile.ctl' VALIDATE;
10>
11> # check if archivelogs for the past two weeks can be restored
12> # RESTORE ARCHIVELOG FROM TIME 'SYSDATE-7' VALIDATE;
13>
14> # - Verify all backups on backup media are intact
15> # CROSSCHECK BACKUP OF DATABASE;
16>
17> # - Display a list of files that need to be backed up based on the retention
18> # policy. For this case study, files that don't have at least 1 backups
19> # will be reported.
20> REPORT NEED BACKUP;
RMAN retention policy will be applied to the command
RMAN retention policy is set to recovery window of 7 days
Report of files whose recovery needs more than 7 days of archived logs
File Days Name
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of report command at 12/30/2008 22:03:48
RMAN-06004: ORACLE error from recovery catalog database: ORA-00904: : invalid identifier
RMAN>
RMAN> # - delete un-necessary backups. This command deletes backups based on the
2> # retention policy.
3> ######### commented out DELETE OBSOLETE - TSM not configured to delete on 68
4> #########DELETE OBSOLETE;
5>
6> # - get complete list of existing backups
7> LIST BACKUP;
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of list command at 12/30/2008 22:03:49
RMAN-06004: ORACLE error from recovery catalog database: ORA-00904: : invalid identifier
RMAN>
RMAN> #-end of file-
2> **end-of-file**
RMAN>
Recovery Manager complete. -
Capturing oracle error codes into a variable
Hi
Can someone show me how it is possible to save an Oracle defined error code into a variable? What I am trying to do is when a stored procedure fails an Oracle error is raised, such as ORA-xxxx, then pass this code into variable to be saved into a log.
How do I achieve this?user633278 wrote:
How do I achieve this?Function SQLCODE in PL/SQL exception handler returns error code. SQLERRM returns message:
SQL> declare
2 x number;
3 begin
4 x := 1/0;
5 exception
6 when others
7 then
8 dbms_output.put_line('Error code: ' || SQLCODE);
9 dbms_output.put_line('Error message: ' || SQLERRM);
10 end;
11 /
Error code: -1476
Error message: ORA-01476: divisor is equal to zero
PL/SQL procedure successfully completed.
SQL> SY. -
Import error imp-00017: following statement failed with oracle error 1659:
Hi all,
I am trying to import a file (dmp) which is of 1.63GB size,
when I type
imp
dbname/pwd@db
c:\filepath
30720
no
no
yes
yes
yes
I am getting the error imp-00017: following statement failed with oracle error 1659:
-- end it says Ora-01659 unable to allocate minextents beyond 1 in tablespace USERS
--unable to create INITIAL extent for segment in tablespace USERS
--import terminated successfully with warnings
when I looked into
select maxbytes,file_name from dba_data_files where tablespace_name='USERS';3.4360+10 c:\oracle\product\10.2.0\oradata\orcl\users01.dbf
kindly help me in solving this is.
Regards,
aak
Edited by: AAK 460425 on Apr 12, 2009 6:33 PMThanks,
select bytes from user_free_space where tablespace_name='USERS'
BYTES
458752
720896
458752
655360
43384832
is the size less?
My apology I have updated this in the below thread, which is same as this one.
Re: Import error -
500 internal server error when opening file attachment
Hi all,
I dont know whether im placing my query in the right place. if not pls advice.
I have uploaded documents to content management from EP portal. The name of the attachment is stored in SAP custom table and the physical file is stored in EP->content management. When i go content mangement and click the attachment, im able to download the file in most cases. But for one employee, when i go content admin -> i can see the attached file name. when i try to open the attachment i am getting error message "500 Internal server error. Please contact your content admin".
Any help will be appreciated.
Thanks!
Dhiya.Nope. The problem occurs with the admin user. HE is able to download attachments, but when he click one attachment he is getting "500 internal server error contact sys admin"
the same thing happens when he tries to open in
irj/km/docs/documents/attachmentfolder/attachmentfile.doc -
Info : Oracle Errors with Desc
Frnds this is the link where u can find all the oracle errors with the cause.
http://ora-code.com/
Hope u all find it beneficial.
~ VishaLNot sure this adds much more to the docs, except Google Ads :P I suppose that once we've got the page up the ability to zip to a message by putting the code in the URL is marginally faster than looking it up in the book...
Cheers, APC
Maybe you are looking for
-
Me and my wife have two iphone4 can we keep one apple id
can we keep i acct. for both phones yet have difftert app and songs
-
How to put a repeatable shadow at the bottom of a wine bottle
I'll select an image of a bottle (beer or wine) and it's all nice and clean around the bottom, totally isolated from the background. I've asked Photoshop savvy friends how to do this and they all have come up with some workaround that is not repeata
-
Retina MacBook Pro 15 inch Windows 8.1 Bootcamp
Hi all, I'm going to buy a MacBook Pro Retina 15 inch soon and was wondering if anyone has tried bootcamping Windows 8.1 on it and see how well it works? I'm very curious about the display scaling. Besides the display scaling, I am also curious to ho
-
How can we call a C program in Labview
Hi a) In one of our application we have to call a C progran in Labview. I am not able to call it. Can somebody help me. b) When we call a C program ,is Labview makes block diagram for it. Please reply Thanking You
-
Adding multiple swf files to Dreamweaver
I'm trying to upload multiple .swf files to my website with no luck. I've done this with previous versions of Dreamweaver but with CS3 I'm finding it won't happen. I've done the Insert -> Media -> Flash action as before and exported my files to be re