Hi Everyone,
I am trying to migrate our Sandbox Bitbucket instance to Oracle PDB from Bitbucket internal database.
But when I test the migration from migration wizard, I get following error,
The specified target database could not be validated due to an unexpected error. As a result, Bitbucket cannot migrate to the specified database.
com.atlassian.stash.internal.db.DefaultDatabaseManager.validateConfiguration(DefaultDatabaseManager.java:224)
com.atlassian.stash.internal.migration.DefaultMigrationService.validateConfiguration(DefaultMigrationService.java:85)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
...
Failed to obtain snapshot. Database type: oracle; nested exception is liquibase.exception.DatabaseException: java.sql.SQLSyntaxErrorException: ORA-00942: table or view does not exist
com.atlassian.stash.internal.backup.liquibase.DefaultLiquibaseSession.getSnapshot(DefaultLiquibaseSession.java:77)
com.atlassian.stash.internal.backup.liquibase.LiquibaseMigrationTarget.hasNoClashingTables(LiquibaseMigrationTarget.java:54)
com.atlassian.stash.internal.db.DefaultDatabaseValidator.validate(DefaultDatabaseValidator.java:63)
...
java.sql.SQLSyntaxErrorException: ORA-00942: table or view does not exist
liquibase.snapshot.jvm.CatalogSnapshotGenerator.snapshotObject(CatalogSnapshotGenerator.java:46)
liquibase.snapshot.jvm.JdbcSnapshotGenerator.snapshot(JdbcSnapshotGenerator.java:66)
liquibase.snapshot.SnapshotGeneratorChain.snapshot(SnapshotGeneratorChain.java:49)
...
ORA-00942: table or view does not exist
oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:494)
oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:446)
oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1054)
...
ORA-00942: table or view does not exist
oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:498)
oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:446)
oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1054)
...
The connecting user 'bitbucket' has been created in following way and have following permissions
(I am aware that tablespace should be USERS and not SYSTEM but it is kept intentionally to replicate same permissions from Production database[This is sandbox database] and later we change it to USERS tablespace? [is it really required, please comment] ),
CREATE USER bitbucket
IDENTIFIED BY somePassword
DEFAULT TABLESPACE SYSTEM
QUOTA UNLIMITED ON SYSTEM;
GRANT CONNECT, RESOURCE, CREATE TABLE to bitbucket;
CREATE VIEW bitbucket.all_objects AS
SELECT *
FROM sys.all_objects
WHERE owner = upper('bitbucket');
Please let me know what I am missing here.
It worked with providing dba privileges to bitbucket though I think this is not ideal solution.
Hi @SW
The following trace is related to the permission of the bitbucket in the SYSTEM tablespace:
SQLSyntaxErrorException: ORA-00942: table or view does not exist
The following are the resolution you can attempt:
Regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.