DBAsupport.com Forums - Powered by vBulletin
Results 1 to 5 of 5

Thread: imp '/as sysdba'

  1. #1
    Join Date
    Oct 2001
    Location
    Stockholm, Sweden
    Posts
    33

    imp '/as sysdba'

    To become sysdba in sqlplus I can simply enter the command:
    # sqlplus '/as sysdba'
    (as the system user oracle... with ORACLE_HOME and ORACLE_SID set..)

    So far so good...But now I want to import my dump with imp...
    Can I connect as sysdba without knowing the password like the syntax
    with sqlplus..

    # imp '/as sysdba'
    (as the system user oracle... with ORACLE_HOME and ORACLE_SID set..)

    does not work..

  2. #2
    Join Date
    Feb 2000
    Location
    Singapore
    Posts
    1,758
    You should import as user SYSTEM. If you do not know the password for SYSTEM. Login as sqlplus / as sysdba and change the password for SYSTEM.
    Sanjay G.
    Oracle Certified Professional 8i, 9i.

    "The degree of normality in a database is inversely proportional to that of its DBA"

  3. #3
    Join Date
    Oct 2001
    Location
    Stockholm, Sweden
    Posts
    33
    Found a workaround with external identification....that might be the solution I will use....

    But I don't really want to create a user for this and the question
    is if this user that have an external identification can be sysdba?

    Another question is if I can start an import thru sqlplus?
    # sqlplus '/as sysdba'
    SQL>

    I can mention that the reason that I want to be able to connect without passwords is that I am witing shllescripts that will create
    a user, a tablespace, grants and then import data from an export-dump...
    I don't want the password as clear text in my scripts...

  4. #4
    Join Date
    Oct 2001
    Location
    Stockholm, Sweden
    Posts
    33
    Originally posted by SANJAY_G
    You should import as user SYSTEM. If you do not know the password for SYSTEM. Login as sqlplus / as sysdba and change the password for SYSTEM.
    Well, that's another workaround...

    But the problem is that I don't want to interfer with the DBA on the server and reset his "system-user"-password...

    When running my scripts I am root.. and then su's to the unixuser oracle...which is able to run sqlplus without being prompted for passwords..
    sqlplus '/as sysdba'

    This lets me execute sqripts for creating user, tablespace, grants and so on.....
    But not import an export-dump!!...

  5. #5
    Join Date
    Nov 2002
    Location
    New Delhi, INDIA
    Posts
    1,796
    Try this

    Code:
    Z:\>imp file=exp.dmp show=y full=y
    
    Import: Release 9.2.0.4.0 - Production on Thu Jul 8 18:23:15 2004
    
    Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.
    
    Username: sys as sysdba
    Password:
    or

    Code:
    Z:\>imp file=ptgr02.dmp show=y full=y
    
    Import: Release 9.2.0.4.0 - Production on Thu Jul 8 18:23:15 2004
    
    Copyright (c) 1982, 2002, Oracle Corporation.  All rights reserved.
    
    Username: sys@orcl as sysdba
    Password:
    Amar
    "There is a difference between knowing the path and walking the path."

    Amar's Blog  Get Firefox!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width