OEM Jobs
DBAsupport.com Forums - Powered by vBulletin
Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: OEM Jobs

  1. #1
    Join Date
    Jan 2002
    Posts
    113
    I am trying to create a job using OEM that will use SQL*Plus. I am running a simple script (select sysdate from dual; ), but I keep getting the same error:


    SP2-0306: Invalid option.
    Usage: CONN[ECT] [logon] [AS {SYSDBA|SYSOPER}] | [INTERNAL]
    where ::= [/][@] | /
    SP2-0306: Invalid option.
    Usage: CONN[ECT] [logon] [AS {SYSDBA|SYSOPER}] | [INTERNAL]
    where ::= [/][@] | /

    It seems that OEM is not able to logon and issue the select statement. Any ideas?

    I have OEM on windows2000, management server on the same machine, and connecting to a unix(DYNIX/PTX) database. The intelligent agent on the unix server is running fine. Thanks.

    Arm yourself with knowledge

  2. #2
    Join Date
    Oct 2001
    Posts
    126
    two ways to solve this problem.

    First method: set up the preferred credentials in the preferences for that database you want to access.

    Second method: Enter user login info on the parameters tab.

    Susan

  3. #3
    Join Date
    Jan 2002
    Posts
    113
    Thanks Susan


    I have tried both of those options with the SYSTEM user before but I get the same error.

    Dean

    Arm yourself with knowledge

  4. #4
    Join Date
    Feb 2001
    Posts
    41
    Dean,

    I just tried to run your sql through OEM jobs and it worked.

    Here are the steps:

    1. Create a job > (jobname)
    2. select Destination Type i.e. (Database)
    3. select Destination i.e. (Database Name)
    4. In Tasks window select "Run SQL*Plus Script"
    5. In Parameter window type "select sysdate from dual;" in Script Text
    6. In Schedule window check radio button "Immediately"
    7. Click submit & save to library

    When the job completed, view job in Job History window, check Progress, highlight Completed and click Show Output.

    Hopefully, you'll see the output.

    Cheers!
    Farrukh



  5. #5
    Join Date
    Oct 2001
    Posts
    126
    I believe that you have validated the user login and password from both oem console and sql*plus application. How did you create that sql*plus job which failed?

    Susan

  6. #6
    Join Date
    Jan 2002
    Posts
    113
    I create the job exactly as FARRUKH described. The output generated lists the error I stated. It seems that I am creating the job correctly. The preferred credentials are for a valid database user and not and OS user, right?
    Arm yourself with knowledge

  7. #7
    Join Date
    Feb 2001
    Posts
    41
    Dean,

    You should have both OS user & Database user in preferred credentials.

    Cheers!
    Farrukh

  8. #8
    Join Date
    Oct 2001
    Posts
    126
    If you use the global_name on the listener.ora file, make sure no double quotation mark around the value.

    Delete all IA configuration files, such as services.ora, snmp_ro.ora,etc. Then, restart the IA and listener, and discover nodes on OEM console.

    Run your job.

    Hope this would take care of your problem.

    Susan

  9. #9
    Join Date
    Oct 2001
    Posts
    126
    It is not required to have both OS user & Database user in preferred credentials. It will save time for login.

    Susan

  10. #10
    Join Date
    Jan 2002
    Posts
    113
    I have changed all accounts to the same username and password (win2k, oracle, oem, unix). Now the job is submitted and hangs in the active state. I cannot remove the job.
    Arm yourself with knowledge

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