Results 1 to 8 of 8

Thread: help ~ ..

  1. #1
    Join Date
    Mar 2004
    Posts
    18

    Unanswered: help ~ ..

    eh i know this is kindda stupid. but im a noob when it comes to oracle this kind of stuffs. ive installed SQL PLUS in my comp. im able to log into the SQL in the past. say, the last time was around 2-3 weeks ago. im not sure whether ive changed the username and the password. but i cant seem to be able to log into it anymore. does anyone knows is there any way to retrieve the username and the password without logging into the SQL first ?

    thanks alot.

  2. #2
    Join Date
    Nov 2003
    Location
    India
    Posts
    114

    Re: help ~ ..

    Try with Default Id/Password combinations

    scott/tiger
    sys/change_on_install

  3. #3
    Join Date
    Sep 2003
    Location
    Virginia, USA
    Posts
    246
    You cannot retrieve passwords from Oracle, even if you logon as SYS AS SYSDBA (the root user.) This is because passwords are created using a one-way hashing algorithm and then discarded - the original password is never stored or retained by Oracle.

    However, if you use Windows NT/2K/XP and you have ability to logon directly to the server, you are in luck. Just update your sqlnet.ora file to have SQLNET.AUTHENTICATION_SERVICES=(NTS), and make sure your Windows user is a member of the Windows user group ORA_DBA, then launch SQL*Plus from the DOS prompt and issue the command "CONNECT / AS SYSDBA". Viola! You're in as the root user without being prompted for a password (this is why most companies restrict who has operating system ability to logon to Oracle servers!) Now that you're in you can change the password for any given user X using the SQL*Plus command "PASSWORD X". Example, type PASSWORD MARKJ and press Return. It will prompt for the new password.
    MarkRem
    Author, Oracle Database 10g: From Nuts to Soup
    http://www.remidata.com/book_nuts2soup.htm

  4. #4
    Join Date
    Mar 2004
    Posts
    18
    Originally posted by markrem

    ... then launch SQL*Plus from the DOS prompt and issue the command "CONNECT / AS SYSDBA". Viola! You're in as the root user without being prompted for a password (this is why most companies restrict who has operating system ability to logon to Oracle servers!) Now that you're in you can change the password for any given user X using the SQL*Plus command "PASSWORD X". Example, type PASSWORD MARKJ and press Return. It will prompt for the new password.
    uh .. sorry about this. but how do i launch the sql from the dos prompt ?
    cd\oracle\ora90\bin > then do i launch the sqlplusw or the sqlplus or something else to get into the root user?

  5. #5
    Join Date
    Jan 2004
    Location
    India
    Posts
    113
    Assuming Oracle 9i on Windows:
    It is not mandatory to use the dos prompt u can launch sqlplus from double clicking the icon also.
    then enter
    Uername: /as sysdba

    If its the same machine on which the db(single no other Oracle Db is present) resides then u don't need to give connection string.

    then issue the following:

    select username from dba_users;
    or
    select username from all_users;

    U will get all the usernames present in ur DB.
    Then u can very well alter any user and assign any passwrd of ur choice.

    Like:
    alter user scott identified by lion;

    Default passwords are
    Sys -> change_on_install
    System->manager

    If u r working with oracle version lower than 9i
    Svrmgrl would be another option for you where u need to connect internal
    the default passwrd of internal is oracle.
    Internal user has been removed in 9i.
    SqlPlus is an exe just type and press enter key
    u will come to
    Sql>

    Hope it helps
    Kaushik

  6. #6
    Join Date
    Sep 2003
    Location
    Virginia, USA
    Posts
    246
    sorry, it does not need to be from DOS, but you can be more efficient from DOS as it has built-in command history buffers you can take advantage of. example, press up/down arrows to scroll through all of your prior SQL*Plus commands.

    Anyways ... to launch from DOS prompt ... you don't need to change directory, so for simple example I will assume you are at C:\.

    1. c:\> set oracle_sid=mysid
    2. c:\> sqlplus /nolog
    3. SQL> connect / as sysdba

    if you have the env variable LOCAL setup, then you should not need to issue the first command (set oracle_sid=sid).
    MarkRem
    Author, Oracle Database 10g: From Nuts to Soup
    http://www.remidata.com/book_nuts2soup.htm

  7. #7
    Join Date
    Mar 2004
    Posts
    18
    hmm sorry about this .. but i cant seem to be able to get it. when i use the command connect /as sysdba. it prompt me for a password instead...

  8. #8
    Join Date
    Jan 2004
    Location
    India
    Posts
    113
    R u trying it from a client m/c or the server itself.

    From the client m/c u probably are logging into the system with a different userid(OS userid) than the userid of the server(using which u installed the s/w). If u need to have windows authenticated users in the db there is a procedure for which I don't think u need it right a way.
    Do one thing go to the server and issue /as sysdba
    then u wil be able to get into the sql plus---this is the easiest option.

Posting Permissions

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