Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-01555: snapshot too old in autonomous database access a remote database via DB link

TorJun 24 2021

Hi, I have a free tier autonomous database (v19) that queries a on premise standard edition 2 also v19 (hosted on a VM in the Oracle Cloud, Ashburn, same region as the autonomous databases). The queries are executed within Oracle APEX (Applications Express) This has been running fine for months but all of a sudden today I started getting ORA-01555 on basic sub second queries. The same queries that fail within APEX work fine within SQL Plus. But I am able to reproduce the problem in SQL Plus if I do a create table X as select * from y@db_link. The error appears within milli seconds. The on premise DB uses auto undo and I tried to increase undo_retention and I tried to switch to a new much larger undo tablespace with no luck. I have also tried to bounce both the autonomous and on premise databases. Performing queries without going through the DB link works fine.
What did change today is that I spun up a second free tier autonomous database (also v19) and I created a DB link from that to the same on premise database but connecting to a different schema. The new database works great and has none of these issues. I also tested creating a DB link from the new autonomous database to the same schema in the on premise database that seems to result in these ORA-01555 errors and those exact same queries that error on the initial autonomous database do not error on the new. So it seems like the issue is not with the on premise database but rather with the initial autonomous database and that my action of spinning up a new one and creating a database link from it somehow triggered the initial autonomous database to exhibit these issues.

Appreciate any pointers!

Comments
Post Details
Added on Jun 24 2021
10 comments
1,261 views