Updated September 9, 2016
A user finds that nodes with a short node name are added into VNQM.
fine as an IPSLA node, but when adding in long named nodes, the wizard states that it is added in successfully, but the node never shows up in the console as an IPSLA node or even in the database.
In such a scenario, the following error occurs in the IpSlaBusinessLayer.log file as a marker to this issue:
2016-08-30 13:29:45,184  ERROR BusinessLayer.Tasks.NodeDiscoveryTask Call:CloseNodeDiscovery - Discovery results not saved.
System.Data.SqlClient.SqlException (0x80131904): String or binary data would be truncated.
The statement has been terminated.
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, SqlDataReader ds)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
at SolarWinds.Orion.Common.SqlHelper.ExecuteScalar(SqlCommand command, SqlConnection connection, SqlTransaction transaction)
at SolarWinds.Orion.Common.SqlHelper.ExecuteScalar(SqlCommand command)
at SolarWinds.Orion.IpSla.Data.DAL.Db.DbSiteDAL.InsertSite(Int32 nodeID, String name, String ipaddress, Boolean isAuto)
at SolarWinds.Orion.IpSla.Data.DAL.Db.DbSiteDAL.CreateSite(Int32 nodeID, String name, String ipaddress, Boolean isAuto)
VNQM version 4 or later
The issue is caused when the names of the node are longer than what can be accepted in the VoipSites table in the VNQM database. Specifically, the Name column in that table is a nvarchar100 column, it can only accept up to 100 characters. If a node name is longer than 100 characters (spaces are considered a character on count) the insert query for the node will fail with the above message because it cannot force the data into that column.
There are 2 options to resolve this issue:
Change the name of the node to place it below 100 characters
Run the query below to up the nvarchar limit on that column.
Please note however, that in the event you do choose to run the following query, any replacement of that table or column by the application (whether through add\remove or through upgrade) will force it to resort back to it's 100 character limit. Be aware of this restriction if the issue then reoccurs after such an event occurs. If it's only a few nodes affected, we recommend just changing the node name to a shorter length.
Run the following query:
alter table voipsites alter column Name nvarchar(150)