none
Ubuntu - SQL Server 2012 - Microsoft ODBC Driver 13 - Error: 18456, Severity: 14, State: 8 RRS feed

  • Question

  • I have been attempting to get "Microsoft ODBC Driver 13 for SQL Server" running in Ubuntu for two days now, and I am out of ideas / have exhausted Google.

    Everything in the install log looks fine, and ldd shows that all of the dependencies are met.

    This is my ODBC.ini

    [MSSQL]
    Description=Microsoft ODBC Driver 13 for SQL Server
    Driver=/opt/microsoft/msodbcsql/lib64/libmsodbcsql-13.0.so.0.0
    Server=<my_server>\<my_sqlserver_instance_name>,1433
    Database=PDS
    Threading=1
    UsageCount=1

    Testing ODBC with isql yields this response:

    vagrant@vagrant-ubuntu-trusty-64:~$ isql -v MSSQL sa <password>
    [28000][unixODBC][Microsoft][ODBC Driver 13 for SQL Server][SQL Server]Login failed for user 'sa'.
    [ISQL]ERROR: Could not SQLConnect

    The SQL Server error log:

    2016-04-22 13:35:04.52 Logon       Error: 18456, Severity: 14, State: 8.
    2016-04-22 13:35:04.52 Logon       Login failed for user 'sa'. Reason: Password did not match that for the login provided. [CLIENT: <my_ip>]

    I can log in to the named server using the sa user and "SQL Server Authentication" using Microsoft SQL Server Management Studio, so I do not believe this is a "Windows Authentication" issue which seems to be the standard answer for this error-severity-state combination.

    I have no idea where to go from here. ANY help is greatly appreciated!!!

    Monday, April 25, 2016 2:26 PM

Answers

  • Hi MilchmannZwei,

    According to the error message, try to use sqlcmd instead of isql, and use password that combines uppercase and lowercase letters and numbers only. Or do not specify the -P option, enter the password until it prompts.


    Sam Zha
    TechNet Community Support

    • Marked as answer by MilchmannZwei Tuesday, April 26, 2016 7:41 PM
    Tuesday, April 26, 2016 5:15 AM
    Moderator

All replies

  • Hi MilchmannZwei,

    According to the error message, try to use sqlcmd instead of isql, and use password that combines uppercase and lowercase letters and numbers only. Or do not specify the -P option, enter the password until it prompts.


    Sam Zha
    TechNet Community Support

    • Marked as answer by MilchmannZwei Tuesday, April 26, 2016 7:41 PM
    Tuesday, April 26, 2016 5:15 AM
    Moderator
  • Hi MilchmannZwei,

    According to the error message, try to use sqlcmd instead of isql, and use password that combines uppercase and lowercase letters and numbers only. Or do not specify the -P option, enter the password until it prompts.


    Sam Zha
    TechNet Community Support

    This is the result of using sqlcmd:

    vagrant@vagrant-ubuntu-trusty-64:~$ sqlcmd -S MSSQL -U sa
    Password: 
    Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : Login timeout expired.
    Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : TCP Provider: Error code 0x2AF9.
    Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible. Check if instance name is correct and if SQL Server is configured to allow remote connections. For more information see SQL Server Books Online..
    vagrant@vagrant-ubuntu-trusty-64:~$

    The SQL Server log:

    Absolutely nothing.

    It should probably be noted that I had to make this symbolic link to make sqlcmd work:

    sudo ln -s /usr/lib64/libodbc.so.2 /lib/x86_64-linux-gnu/libodbc.so.2

    Tuesday, April 26, 2016 4:31 PM
  • Hi MilchmannZwei,

    According to the error message, try to use sqlcmd instead of isql, and use password that combines uppercase and lowercase letters and numbers only. Or do not specify the -P option, enter the password until it prompts.


    Sam Zha
    TechNet Community Support


    A break, and a google search for examples instead of relying on the man page yielded a connection.  So now I know the machines CAN talk to each other.  Thank you for putting me on the right track Sam Zha.
    Tuesday, April 26, 2016 7:40 PM