Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase «««34567»»

SQL Overview SSIS Package III - Full Package Expand / Collapse
Author
Message
Posted Monday, November 9, 2009 12:01 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Wednesday, June 11, 2014 7:43 AM
Points: 184, Visits: 1,007
First, when a cluster instance is started, you can check if the active node has changed. The active node name is captured in the [SQL_Overview].[dbo].[SQL_Servers] table. You can add a column to the SSIS_ServerList to track the active node and create a special report when it changes.

If the instance is restarted multiple times in the day, the SQL Overview error log report could be updated to include records of it happening. It might already.

I personally watch for unexpected instance restarts and if it is a cluster, I check the windows event log to find the cause of the failover. Most of our cluster failovers are caused by window security patching.




David Bird

My PC Quick Reference Guide
Post #816019
Posted Monday, November 9, 2009 12:37 PM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Tuesday, July 22, 2014 7:14 AM
Points: 32, Visits: 593
Hi Dave,
One way to accomplish this would be to read the errorlogs to get the last date. This will be the LogDate and the NetBIOS name of the node in the error log when the rollover occurred. Try the below code and see if this may work for you. This can easily be rolled into the DBA Repository, which I will be doing to the next update to the original solution.

--Read Error Logs

DECLARE @TSQL NVARCHAR(2000)
DECLARE @lC INT


CREATE TABLE #TempLog (
LogDate DATETIME,
ProcessInfo NVARCHAR(50),
[Text] NVARCHAR(MAX))


CREATE TABLE #logF (
ArchiveNumber INT,
LogDate DATETIME,
LogSize INT
)

INSERT INTO #logF
EXEC sp_enumerrorlogs
SELECT @lC = MIN(ArchiveNumber) FROM #logF


WHILE @lC IS NOT NULL
BEGIN
INSERT INTO #TempLog
EXEC sp_readerrorlog @lC
SELECT @lC = MIN(ArchiveNumber) FROM #logF
WHERE ArchiveNumber > @lC
END

select * from #templog where text like '%netbios%'

DROP TABLE #TempLog
DROP TABLE #logF
Post #816057
Posted Thursday, March 4, 2010 2:39 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Yesterday @ 3:21 PM
Points: 161, Visits: 751
I know that this thread is old, but I'm hoping you're still answering questions David. These articles are extremely helpful! Very easy to follow for a beginner.

I had one question that I wasn't sure if someone else hit as well. The tempdb.sql script creates all necessary tables in the tempdb. That works just fine. However, when the SQL Service is bounced those tables are removed. I had to recreate them. Is there a possible work around for this?
Post #877190
Posted Friday, March 5, 2010 5:23 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Tuesday, July 22, 2014 7:14 AM
Points: 32, Visits: 593
The package should be checking for their existence and creating them anew automatically. Are you saying that is not the case? At least that is how it worked in the original SQL Magazine DBA Repository. Or perhaps these are temp tables that store permanent values with the modified repository?
Rodney Landrum
Post #877543
Posted Friday, March 5, 2010 8:26 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Yesterday @ 3:21 PM
Points: 161, Visits: 751
I do see that it does create the temp tables in each step if they don't exist. I don't see where it would be storing permanent values, at least I can't find any. But the instructions do say to create them, step 8.

I'm still running this manually from BIDS, I haven't deployed it to SSMS yet. Maybe that is the problem? The MultiServer connection is setup to point to the server housing the SQL_Overview database (at least initially) and it expects those temp tables to be there. So when the instance was restarted, they were dropped, then I couldn't run it manually any longer without recreating them. I believe that's the problem.

So I guess my real question is (if my prior assumption is correct), once I deploy this to SSMS and schedule it, will it behave the same way if the instance is restarted or will it not care at that point since all the create statements will be executed?

I appreciate your help!
Post #877680
Posted Friday, March 5, 2010 9:00 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Tuesday, July 22, 2014 7:14 AM
Points: 32, Visits: 593
I believe you are right that it will be handled appropriately when scheduled. At least I have not had any issues. Design is different because now you will be fighting validation issues.
Rodney
Post #877713
Posted Friday, March 5, 2010 9:03 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Yesterday @ 3:21 PM
Points: 161, Visits: 751
Great, thank you!
Post #877719
Posted Friday, March 5, 2010 9:36 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Wednesday, June 11, 2014 7:43 AM
Points: 184, Visits: 1,007
The scheduled job in the second step creates the temp tables on the local server. This allows the SSIS package to start.

Then when an item in the package connects to a remote instance the TEMPDB table is recreated on that instance.


David Bird

My PC Quick Reference Guide
Post #877749
Posted Friday, March 5, 2010 9:43 AM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Yesterday @ 3:21 PM
Points: 161, Visits: 751
David, thank you for your reply.

I hadn't made it that far in the documentation. I now see that you specifically point that out under the Create Job section.

My apologies!
Post #877754
Posted Friday, August 12, 2011 11:03 AM
SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Monday, July 14, 2014 3:43 PM
Points: 203, Visits: 52
This SQL Overview is great help but I am having a problem with Part 3.

I am getting an odd error from the Multiserver in the SQL_Overview_part3_package. It doesn't have the sql instance and when i try to add it the package doesn't remember it. The package fails when i run it from my desktop or from the SQL server.
Why doesn't the connection remember the database name where I ahve the SQL_Overview database? It worked fine in Parts 1 and 2.
Is it possible to get a discription of what goes into Package 3?
Post #1159402
« Prev Topic | Next Topic »

Add to briefcase «««34567»»

Permissions Expand / Collapse