ESP dSeries Workload Automation

 View Only
  • 1.  SQLCMD -E is passing server name as trusted account

    Posted Jul 22, 2020 04:30 PM
    When I execute SQLCMD.EXE  -E it should use the trusted account but instead my DBA tells me it is passing the server name as the user ID. In our 11.3 system it is executing fine, but we just upgraded to 12.2 and it will not seem to work.

    Windows job
    command: %ESP.PROG_DIR_MSQL_SERVER_BINN\SQLCMD.EXE
    arguments to pass: -E -b -ic:\input\PPI600E_ESA.sql -oc:\reports\PPI600E_ESA.txt -S %ESP.CAWA_DB\%ESP.CAWA_DB -h-1

    Where the variables are setup correctly in global variables.

    The error looks like:
    Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : Login failed for user 'DOMAIN\SERVER$'


  • 2.  RE: SQLCMD -E is passing server name as trusted account

    Broadcom Employee
    Posted Jul 22, 2020 11:51 PM
    Hi,

    Can you please raise a ticket for this.

    Ravi Kiran


  • 3.  RE: SQLCMD -E is passing server name as trusted account

    Posted Jul 23, 2020 09:22 AM
    Created case per your recommendation.


  • 4.  RE: SQLCMD -E is passing server name as trusted account

    Posted Jul 24, 2020 06:30 AM
    Can you share the spool file showing this error? There are several ways to setup the command/arguments. We just upgrade from 12.0 to 12.2 and all of our SQLCMD.exe jobs still run as expected.

    Sample1:
    Command to run C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\130\Tools\Binn\SQLCMD.EXE
    Arguments to pass -E -S rscsqlspr01\ssis -Q "master.dbo.CallSSIS32 'Load Employees for PC Support'"

    Sample2 - stored procedure
    Contents of SQLCMD.CMD:
    SQLCMD -E -S %1 -Q %2 -b

    Command to run C:\ESPAgent\SQLCMD.cmd
    Arguments to pass VRSCSQL8\RSCSQL08 "Enterprise_Automation.dbo.stp_tdp_TriggerDailyAudit"


    Sample3 - input file
    Contents of MSSQL_SQLCMD_input_file.cmd
    sqlcmd -E -S %1 -d %2 -i %3 -b

    Command to run C:\ESPAgent\MSSQL_SQLCMD_input_file.cmd
    Arguments to pass 013PRODENT01 Enterprise c:\ESPAgent\CouponCleanupExecution.sql



  • 5.  RE: SQLCMD -E is passing server name as trusted account

    Posted Jul 24, 2020 10:59 AM
    Spool is not helpful.

    All we get for error is as specified above:
    Sqlcmd: Error: Microsoft ODBC Driver 17 for SQL Server : Login failed for user 'DOMAIN\SERVER$'

    The job definition is: