Results 1 to 10 of 10
  1. #1
    Join Date
    Sep 2002
    Posts
    456

    Unanswered: Oracle 9i and user SYS

    According to the Oracle documentation; user SYS and SYSTEM are created as part of the Database creation. Then it says....connect to the instance as user SYS and create the database (if creating database manually)....so we have user SYS and SYSTEM even before a database is created....I know what Oracle is telling is correct but can somebody explain so I can understand how all this is happening.....Database in question is 9i and could be on AIX or NT.

    Thanks.

  2. #2
    Join Date
    Jun 2004
    Posts
    796
    Provided Answers: 1
    Read this excellent article and all will be revealed...

    http://www.gennick.com/sqlplus_excerpt_10.html
    90% of users' problems can be resolved by punching them - the other 10% by switching off their PCs.

  3. #3
    Join Date
    Sep 2002
    Posts
    456
    Thanks for the info.

    Question; when is the sys user created? After create database command has issued or it's there all along but as OS user one is able to log in as SYS or SYSTEM.

    dollar

  4. #4
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    Which came first; the chicken or the egg?
    How will getting an answer make your life better?
    > can somebody explain so I can understand how all this is happening....
    It is magic and this knowledge is limited to only Grand Wizards
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  5. #5
    Join Date
    Sep 2002
    Posts
    456
    anacedent...your attitude is as small as your brain...I hope moderator of this forum take notice of your reponse. As they say stupid people will always show their stupidity in one form or another....but you show it all the time.

    dollar

  6. #6
    Join Date
    Jun 2004
    Posts
    796
    Provided Answers: 1
    The answer to every question (as my old mentor taught me) is "It's too technical for you to understand".

    We're not being small-minded, but have you got kids? Have you ever had them sit on your knee & keeping asking you "but why?" every time you answer a question?

    The honest answer to your questions is to get a really good book on the subject & read it, or search the Internet for related articles. This forum can & will answer most questions, but not the "but why?" variety, as the thread can go on & on & on & on & on & on & on....
    90% of users' problems can be resolved by punching them - the other 10% by switching off their PCs.

  7. #7
    Join Date
    Jul 2003
    Posts
    2,296
    it is a tricky (if not meaningless) question to answer.

    in Unix/Linux, without a database, you can issue:
    sqlplus "/ as sysdba"
    what does this mean?
    Well, technically, you are connected as SYS to an idle instance (ie: no instance or database). From here you could startup an instance and create a database. SO, does that mean the SYS user was created before your database was created? Not really since you cannot do this in a Windows environment (you need to use the ORADIM utility).

    Once you issue the startup nomount pfile=/a/b/c/init.ora you have now started up an instance which means no database yet, all you have done is started an instance. Once you issue the create database command then you can create and set the passwords for SYS and SYSTEM users (among many other things that get created at this point).

    So, you need to conenct as SYS in order to create a DB, but you also create the USERS/passwords when the database is created.
    - The_Duck
    you can lead someone to something but they will never learn anything ...

  8. #8
    Join Date
    Sep 2003
    Posts
    237
    had similar questions; made my peace with this explanation; you have just installed oracle; there is no instance(database) so no SYSTEM tablespce, no TEMp tablespace, no system tables,no users.
    you make sure the os user(say oracle) is part of the group 'dba';(in nt local administrator)
    you sign as oracle; then keyin "sqlplus /nolog"; "connect / as sysdba;"; sqlplus checks that you are a member of the right group(dba) and allows you sysdba privileges which is you can do anything in sqlplus. When you execute "create database..." statement, it creates system tablespace, creates a whole bunch of oracle core tables(ending in $),other tables,indexes,procedures etc. with SYS as the owner, and a bunch of views with system as the owner etc. So CREATE DATABASE creates the users SYS,SYSTEM; you change the passwords from the original defaults of "change_on_install" and "manager" respectively. afterwards you can logon to sqlplus and "connect system/manager as sysdba" when sqlplus looks at your SID, goes to that instance's system tables, checks the user/password and lets you in.so to get sysdba privileges you are a user belonging to group "dba" or you know the user/password of a user in an instance who has been given sysdba role(sys and system automatically get that role); HTH
    mota

  9. #9
    Join Date
    Sep 2002
    Posts
    456
    Thands dbamota and Duck

    I am new to Oracle but asked this question to few senior level DBA's as well and they didn't have good answer so thought of putting it here. From what I read it seems very much like connect internal concept but one I thought Oracle was going away from, I guess not!!!

    Thanks again.

    dollar

  10. #10
    Join Date
    Jun 2004
    Location
    Liverpool, NY USA
    Posts
    2,509
    The connect internal using svrmgrl has gone away, but the concept of connecting as a priviledged user without password will always need to be with us.
    Bill
    You do not need a parachute to skydive. You only need a parachute to skydive twice.

Posting Permissions

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