14 Replies Latest reply on Nov 9, 2007 2:37 PM by floyd.may

    Invalid column name 'ToS'

    Don331

       We're seing the error

      2007-10-31 12:27:28,438 [Scheduler] ERROR SolarWinds.Orion.NetFlow.ScheduledTask - CollapseLevel1 threw an exception.
      System.Data.SqlClient.SqlException: Invalid column name 'ToS'.
      Invalid column name 'ToS'.

       

      All over the swdebug log.  Got all the hotfixes installed.

      Anyone else? 

        • Re: Invalid column name 'ToS'

          I just ran into this with another customer.  Please do the following:

          1. Shut down your NetFlow collector service.
          2. Run the following in SQL enterprise manager on your NTA database.  Let me know if it encounters any errors.
            declare @mycount int
            declare @query nvarchar(2000)
            DECLARE @ParmDefinition nvarchar(500)
            SET @ParmDefinition = N'@mycountout int OUTPUT'
            set @query = N'select @mycountout =count(*) from nodes'
            execute sp_executesql @query, @ParmDefinition, @mycountout = @mycount output
            create table #tmpNodes (tmpid int identity, nodeID int)
            insert into #tmpNodes select NodeID from Nodes
            declare @row int
            set @row = 1
            WHILE(@row <= @mycount)
            BEGIN
            declare @tablename nvarchar(100)
            declare @node nvarchar(100)
            set @ParmDefinition = N'@rowin int, @NodeIdOut int output'
            set @query = N'select @NodeIdOut = NodeID from #tmpNodes Where tmpid = @rowin'
            execute sp_executesql @query, @ParmDefinition, @rowin = @row, @NodeIdOut = @node output
            SET @row = @row + 1
            set @tablename = 'NetFlowDetail_' + @node
            set @query = N'if exists (select * from INFORMATION_SCHEMA.COLUMNS where TABLE_NAME = ''' + @tablename +
            ''') and not exists ( select * from INFORMATION_SCHEMA.COLUMNS
            where TABLE_NAME = ''' + @tablename + ''' and COLUMN_NAME = ''ToS'' )
            begin
            alter table ' + @tablename + ' add ToS int
            end'
            exec sp_executesql @query
            END
            drop table #tmpNodes

            GO

            This is an excerpt from the database upgrade script that should have run when you ran the configuration wizard after upgrading to 2.2.  You should expect this to take quite a while (minutes, maybe hours), so you should probably plan this for off-hours.
          3. Restart your collector service.  Once restarted, the collector service should groom out the data over a period of a few hours.
          Also, can you please open a Support ticket with the title "Thwack - Failed Upgrade to NetFlow 2.2" and attach your Diagnostics?  I'd like to examine why the upgrade failed.
            • Re: Invalid column name 'ToS'
              Don331

               Ran it... ran clean, no errors.. said some 168 row affected.

               

              Case is 22624

               

              Thanks! 

                • Re: Invalid column name 'ToS'

                  Can you run SolarwindsDiagnostics.exe from the Orion folder and not the NetflowTrafficAnalysis folder, and then attach those diags to case 22624?

                  Thanks! 

                    • Re: Invalid column name 'ToS'
                      Don331

                      Floyd,


                       Just did it!


                       


                      Thanks,


                      Don

                        • Re: Invalid column name 'ToS'
                          Don331

                          Looks like the problem is still there:


                          2007-10-31 17:05:21,060 [6] ERROR SolarWinds.Orion.Common.SWEventLogging - NetFlow Receiver Service [SWORION] Started- listening on Port=2055
                          2007-10-31 17:05:21,248 [Scheduler] INFO  SolarWinds.Orion.NetFlow.Collapse - Performing level 1 collapse for source intervals 1321315 to 1321315
                          2007-10-31 17:05:21,248 [Scheduler] ERROR SolarWinds.Orion.NetFlow.ScheduledTask - CollapseLevel1 threw an exception.
                          System.Data.SqlClient.SqlException: Invalid column name 'ToS'.
                          Invalid column name 'ToS'.
                             at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
                             at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
                             at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
                             at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
                             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)
                             at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
                             at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
                             at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
                             at SolarWinds.Orion.Common.SqlHelper.ExecuteNonQuery(SqlCommand command, SqlConnection connection, SqlTransaction transaction)
                             at SolarWinds.Orion.NetFlow.NetFlowSummaryDAL.CollapseFlows(Int32 startInterval, Int32 endInterval, String sourceTable, String destinationTable, SqlConnection connection, SqlTransaction transaction)
                             at SolarWinds.Orion.NetFlow.NetFlowSummaryDAL.CollapseFlows(Int32 startInterval, Int32 endInterval, Int32 sourceLevel, Int32 nodeId, SqlConnection connection, SqlTransaction transaction)
                             at SolarWinds.Orion.NetFlow.CollapseLevel1.DoCollapse(Int32 startInterval, Int32 endInterval, SqlConnection connection, SqlTransaction transaction)
                             at SolarWinds.Orion.NetFlow.Collapse.CollapseFlowsForInterval(Int32 startInterval, SqlConnection connection)
                             at SolarWinds.Orion.NetFlow.Collapse.CollapseFlows(Int32 nodeId)
                             at SolarWinds.Orion.NetFlow.Collapse.CollapseAllLevel1(Dictionary`2 settings)
                             at SolarWinds.Orion.NetFlow.Collapse.CollapseLevel1Task(Object state)
                             at SolarWinds.Orion.NetFlow.Collapse.CollapseTaskHandler(Object state)
                             at SolarWinds.Orion.NetFlow.ScheduledTask.DoWork()
                             at SolarWinds.Orion.NetFlow.ScheduledTask.Run()
                          2007-10-31 17:05:21,279 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_130
                          2007-10-31 17:05:21,279 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_132
                          2007-10-31 17:05:21,295 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_135
                          2007-10-31 17:05:21,295 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_136
                          2007-10-31 17:05:21,295 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_137
                          2007-10-31 17:05:21,326 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_139
                          2007-10-31 17:05:21,342 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_143
                          2007-10-31 17:05:21,342 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_154
                          2007-10-31 17:05:21,357 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_158
                          2007-10-31 17:05:21,357 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_159
                          2007-10-31 17:05:21,357 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_160
                          2007-10-31 17:05:21,373 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_161
                          2007-10-31 17:05:21,513 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowSummaryDAL - 0 rows deleted from NetFlowSummary3
                          2007-10-31 17:05:25,263 [Scheduler] INFO  SolarWinds.Orion.NetFlow.Scheduler - Got ShuttingDownEvent. Exiting.
                          2007-10-31 17:05:25,263 [17] ERROR SolarWinds.Orion.Common.SWEventLogging - NetFlow Receiver Service [SWORION] Stopped

                          • Re: Invalid column name 'ToS'

                            Don, can you look at any of the NetFlowDetail_* tables and see if they now have a ToS column? 

                              • Re: Invalid column name 'ToS'
                                Don331

                                 Floyd,

                                 

                                All the tables have the ToS column!

                                 

                                Don 

                                  • Re: Invalid column name 'ToS'

                                    What about the NetFlowSummary tables? 

                                      • Re: Invalid column name 'ToS'
                                        bbusbey

                                        I'm getting the error:


                                        System.Data.SqlClient.SqlException: Invalid column name 'ToS'.
                                        Invalid column name 'ToS'.
                                           at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
                                           at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
                                           at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
                                           at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
                                           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)
                                           at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
                                           at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
                                           at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
                                           at SolarWinds.Orion.Common.SqlHelper.ExecuteNonQuery(SqlCommand command, SqlConnection connection, SqlTransaction transaction)
                                           at SolarWinds.Orion.NetFlow.NetFlowSummaryDAL.CollapseFlows(Int32 startInterval, Int32 endInterval, String sourceTable, String destinationTable, SqlConnection connection, SqlTransaction transaction)
                                           at SolarWinds.Orion.NetFlow.NetFlowSummaryDAL.CollapseFlows(Int32 startInterval, Int32 endInterval, Int32 sourceLevel, Int32 nodeId, SqlConnection connection, SqlTransaction transaction)
                                           at SolarWinds.Orion.NetFlow.CollapseLevel1.DoCollapse(Int32 startInterval, Int32 endInterval, SqlConnection connection, SqlTransaction transaction)
                                           at SolarWinds.Orion.NetFlow.Collapse.CollapseFlowsForInterval(Int32 startInterval, SqlConnection connection)
                                           at SolarWinds.Orion.NetFlow.Collapse.CollapseFlows(Int32 nodeId)
                                           at SolarWinds.Orion.NetFlow.Collapse.CollapseAllLevel1(Dictionary`2 settings)
                                           at SolarWinds.Orion.NetFlow.Collapse.CollapseLevel1Task(Object state)
                                           at SolarWinds.Orion.NetFlow.Collapse.CollapseTaskHandler(Object state)
                                           at SolarWinds.Orion.NetFlow.ScheduledTask.DoWork()
                                           at SolarWinds.Orion.NetFlow.ScheduledTask.Run()
                                        2007-11-01 16:04:38,508 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_4
                                        2007-11-01 16:04:38,523 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_5
                                        2007-11-01 16:04:38,523 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_10
                                        2007-11-01 16:04:38,523 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_14
                                        2007-11-01 16:04:38,523 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_16
                                        2007-11-01 16:04:38,523 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_17
                                        2007-11-01 16:04:38,539 [Scheduler] INFO  SolarWinds.Orion.NetFlow.NetFlowDetailDAL - 0 rows groomed from NetFlowDetail_43


                                         


                                        Bruce