Forum Stats

  • 3,853,717 Users
  • 2,264,259 Discussions
  • 7,905,435 Comments

Discussions

How to resolve SQL Developer error?

13»

Answers

  • Kinjan Bhavsar
    Kinjan Bhavsar Member Posts: 95 Blue Ribbon

    Hi @EdStevens ,

    Some good news, I am now able to connect to DB from SQL developer


    Do let me know if I need to check anything to be 100% sure?

  • EdStevens
    EdStevens Member Posts: 28,778 Gold Crown

    Looks good to me. Since you got 'success' on 'test', why didn't you just follow up with 'save', and then do an actual connection?

    BTW, I wouldn't connect as SYS. Connecting to oracle DB as SYS (sysdba) is like connecting to linux as 'root'. It is all powerful, with few, if any protections. Like riding a unicycle on a tightrope while juggling chainsaws. You should never connect as SYS unless absolutely required to do what you need. And by the same token, I wouldn't use SYSTEM as my general 'dba' account. Create your own local dba account, something like XXX_DBA, where 'xxx' is an acronym for your organization's name - or some such. Using SYS or SYSTEM makes it too easy to accidentally create your own local objects under the SYS or SYSTEM schemas, which you _should not do_.


    And I would continue to follow up on your ssh connection issue until it is resolved. You will learn a lot, and with it working you will really be able to treat your VM exactly like a server in the data center.

  • Kinjan Bhavsar
    Kinjan Bhavsar Member Posts: 95 Blue Ribbon

    Hi @EdStevens

    So you recommend to create a new user using create user command and grant dba rights to that user and try to connect it in SQL Developer?

    If yes, then what should I select in role? Should it be default or SYSDBA?

  • EdStevens
    EdStevens Member Posts: 28,778 Gold Crown

    So you recommend to create a new user using create user command and grant dba rights to that user and try to connect it in SQL Developer?

    I thought that was exactly what I was saying.

    And no, do not use SYSDBA. That is not a role, but a very special and unique privilege. You really shouldn't grant it to anyone. If, say, you grant it to user FRED, then when FRED connects "as sysdba", he is really connecting as SYS, with all the rights, privileges, responsibilities, and dangers thereof.

    It's as simple as I described. Create a user, and grant it the DBA role

    create user my_dba identified by "fubar" default tablespace users;
    grant dba to my_dba;
    


  • Kinjan Bhavsar
    Kinjan Bhavsar Member Posts: 95 Blue Ribbon

    Thanks @EdStevens

    Thank you very much for your help throughout the process. I will keep learning new things regarding installation and other activities which are required for a developer to learn.