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

Thread: sqlplus -s

  1. #1
    Join Date
    Nov 2000
    Posts
    175
    Hi Everyone,

    Quick Question. I am running a ksh script and trying to login to sqlplus.
    When I put

    SQLPLUS=${ORACLE_HOME}/bin/sqlplus
    $SQLPLUS -s/ <
    It keeps bombing, asking for a password.

    when I run it without the -s, it works. Does anyone have an answer for this.

    Thanks,
    Kathy

  2. #2
    Join Date
    Nov 2000
    Location
    greenwich.ct.us
    Posts
    9,092
    of course, you have a space between the -s and /, right? Post the block of code that doesn't work...
    Jeff Hunter

  3. #3
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    It means that your OS authnetication had not been setin your init.ora parameter. Verify the docs on how to set that up.

    Sam
    Thanx
    Sam



    Life is a journey, not a destination!


  4. #4
    Join Date
    Nov 2000
    Posts
    175
    No I do not have a space between the -s/. Now this works on another box, alright.

    I checked the init file and here are the settings I have.

    remote_os_authent = true # enable remote ops$ logins
    os_authent_prefix=ops$

    After this hot backup runs I will put the -s back in and see if I am still getting the same errors. I don't get it because i thought the -s just means running in silent mode.

    Anymore thoughts,

  5. #5
    Join Date
    Nov 2000
    Posts
    175
    update here is the code that doesn't work

    SQLPLUS=${ORACLE_HOME}/bin/sqlplus
    $SQLPLUS -s/ <

    here is the code that does:
    SQLPLUS=${ORACLE_HOME}/bin/sqlplus
    $SQLPLUS / <
    Thx,

  6. #6
    Join Date
    Nov 2000
    Location
    greenwich.ct.us
    Posts
    9,092
    Yes, -s is just silent mode. No output from SQLPLUS will be sent to the screen.

    To check to make sure OS authentication is active, try sqlplus without the -s flag. It sounds like you have tried that and it works...

    This works for me:

    sqlplus -s /@dbname << EOF
    select count(*) from user_objects;
    exit
    EOF
    Jeff Hunter

  7. #7
    Join Date
    Nov 2000
    Location
    greenwich.ct.us
    Posts
    9,092
    This also works fine for me:


    export SQLPLUS=$ORACLE_HOME/bin/sqlplus
    $SQLPLUS -s /@dbname << EOF
    select count(*) from user_objects;
    exit
    EOF

    Jeff Hunter

  8. #8
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    Check your

    sqlnet.ora: sqlnet.authentication_services = (NTS)


    Sam
    Thanx
    Sam



    Life is a journey, not a destination!


  9. #9
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    Originally posted by kburrows
    update here is the code that doesn't work

    SQLPLUS=${ORACLE_HOME}/bin/sqlplus
    $SQLPLUS -s/ <

    here is the code that does:
    SQLPLUS=${ORACLE_HOME}/bin/sqlplus
    $SQLPLUS / <
    Thx,
    I might be repeating the obvious, but Jeff has allready pointed at the source of your trubles (it just might be that you missunderstood his point): you *need* a space between -s parameter and your slash.

    Instead of

    $SQLPLUS -s/ << EOF

    use

    $SQLPLUS -s / << EOF


    As for Sam's suggestion: isnt the sqlnet.authentication_services = (NTS) relevant only for NT environment?

    [Edited by jmodic on 06-14-2001 at 03:31 PM]
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

  10. #10
    Join Date
    Nov 2000
    Posts
    175
    I will try it with the space.

    And Yes, I think the sqlnet is for NT, I am running unix box 4.

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