.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Post New Web Links

clustered node change notification

Posted By:      Posted Date: October 05, 2010    Points: 0   Category :Sql Server

Hello Friends,


I need a sql server script for my notification for the following.

I have node 1 and node 2 in my clustered environment.


Instances 1 and 2 usually runs on node 1. Instance 2 usually on node 2.


Sometimes they switch without notification. I need to know when they switch. Because I copy files from instances.


Need to know only what instance changed from which node and vice versa.


Any ideas and answers would be greatly appreciated.



View Complete Post

More Related Resource Links

Node Change Notification


Hello Friends/Colleagues,


I have 2 nodes active/active with 3 virtual instances.

2 instances on node 1 and 3d instance on node 2.


Sometimes they automatically change from node 1 to node 2.

Is there any way that I get some notification regarding the instance that have changed from one node to another?


I found following may be probable solution:

EXEC master..xp_cmdshell 'cluster resource "SQL Server (Instance Name)"'

Result: Instance Name, Node Name

Put results into table..........Again run the command.....compare.......too much stuff.....

If someone knows the easy path to this.......


How could I get the information that has been changed?


Your help would be really great!



Treeview - how to change node icon depending on node contents

I have a treeview in an MVVM application: <TreeView ItemsSource="{Binding RootNodes}"> <TreeView.ItemContainerStyle> <Style TargetType="{x:Type TreeViewItem}"> <Setter Property="IsExpanded" Value="{Binding IsExpanded, Mode=TwoWay}" /> <Setter Property="IsSelected" Value="{Binding IsSelected, Mode=TwoWay}" /> <Setter Property="FontWeight" Value="Normal" /> <Style.Triggers> <Trigger Property="IsSelected" Value="True"> <Setter Property="FontWeight" Value="Bold" /> </Trigger> </Style.Triggers> </Style> </TreeView.ItemContainerStyle> <TreeView.ItemTemplate> <HierarchicalDataTemplate ItemsSource="{Binding Children}"> <TextBlock Text="{Binding NodeName}" /> </HierarchicalDataTemplate> </TreeView.ItemTemplate> </TreeView> The treeview is bound to an ObservableCollection called RootNodes. Elements in the RootNodes collection expose a member "NodeName" which is the text for the nodes in the treeview at runtime. They also expose a member called "NodeType", effectively an enumeration that indicates what type of icon should be displa

ASP.Net - App Pool restarts because of file change notification

Hi All,IIS restarts everytime i delete a file. I came across this code which was supposed to fic the problem but the line f.GetValue(..) in last but one line returns null. Can anyone tell me why this is happening -//FIX disable AppDomain restart when deleting subdirectory//This code will turn off monitoring from the root website directory.//Monitoring of Bin, App_Themes and other folders will still be operational, so updated DLLs will still auto deploy.System.Reflection.PropertyInfo p = typeof(System.Web.HttpRuntime).GetProperty("FileChangesMonitor", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.Static);object o = p.GetValue(null, null);System.Reflection.FieldInfo f = o.GetType().GetField("_dirMonSubdirs", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.IgnoreCase);object monitor = f.GetValue(o);System.Reflection.MethodInfo m = monitor.GetType().GetMethod("StopMonitoring", System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic); m.Invoke(monitor, new object[] { });

XML binding and notification on change

Dear all, I have a customer project when I need to display data into a WPF application. Data are deliver by my customer as flat XML file struture. For exemple: Information relative to a GOOD will be store in a GOOD.XML file Information relative to a CONTACT will be store in a CONTACT.XML file and exmaple of this structure is as follow : <GOODS> <GOOD> <CATEGORIE>APPARTEMENT</CATEGORIE> <NB_PIECES>3</NB_PIECES> <NB_CHAMBRES>2</NB_CHAMBRES> <SURF_HAB>60</SURF_HAB> <SURF_CARREZ>60,6</SURF_CARREZ> <SURF_SEJOUR>21</SURF_SEJOUR> <SURF_TERRAIN>0</SURF_TERRAIN> <ETAGE>0</ETAGE> <CODE_ETAGE>RJ</CODE_ETAGE> <NB_ETAGES>4</NB_ETAGES> <ANNEE_CONS>1996</ANNEE_CONS> <CUISINE>AMERICAINE</CUISINE> </GOOD> </GOODs> So the file avove will be sen from my customer app on a network drive. then I will read that file and bind my applicaction against. If my customer provide a file update, he will drop the new file at same network location and my application should read new data . The number of file extracted will be around 40 . Each file represent a separate object My questions are : 1- At first I was planning to build a local database as SQL express based on those file and work on the db but now I wonder if I should go to that

Cluster Node Change


Hello Friends/Colleagues,


I have 2 nodes active/active with 3 virtual instances.

2 instances on node 1 and 3d instance on node 2.


Sometimes they automatically change from node 1 to node 2.

Is there any way that I get some notification regarding the instance that have changed from one node to another?


I found following may be probable solution:

EXEC master..xp_cmdshell 'cluster resource "SQL Server (Instance Name)"'

Result: Instance Name, Node Name

Put results into table..........Again run the command.....compare.......too much stuff.....

If someone knows the easy path to this.......


How could I get the information that has been changed?


Your help would be really great!



treeview selected node font style does not change


Hi All,

I have a treeview and I am giving the node style in code behind.

Treeview design is as below:

<asp:TreeView ID="tvIARHierarchies" runat="server" NodeIndent="15" ShowExpandCollapse="true"
                                        ShowLines="True" Width="98%" OnSelectedNodeChanged="tvIARHierarchies_SelectedNodeChanged">
                                        <ParentNodeStyle Font-Bold="False" />
                                        <HoverNodeStyle Font-Underline="True" ForeColor="#6666AA" />

Change Xml Node Attribute


Hello all...

I am trying to change the attributes of a xml node in a smart device application (pda).

The first problem I have is that xmlDoc.SelectSingleNode("xpath"); does not work.

I found another way to select each time the node i need (xmlDoc.DocumentElement.ChildNodes.Item(currentPosition))

and now I need to change the values of the node's attributes.

I have done this for a web application before but does not work here and cannot figure out what to do...

this is the code I have...

                XmlElement newElement = xmlList.CreateElement("SUB");
                XmlAttribute nameAttribute = xmlList.CreateAttribute("Name");
                nameAttribute.Value = tbProductName.Text;
                XmlAttribute priceAttribute = xmlList.CreateAttribute("Price");
                priceAttribute.Value = tbProductPrice.Text;
                XmlAttribute offerAttribute = xmlList.CreateAttribute("Offer");
                offerAttribute.Value = tbProductOffer.Text;
                XmlAttribute offerPriceAttribute = xmlList.CreateAttribute("OfferPrice");

Clustered SQL 2008 R2 x64, Oracle linked server works on one node, fails on the other


Juicy bits:

- SQL Server 2008 R2 x64

- Microsoft SQL Server 2008 R2 (RTM) - 10.50.1600.1 (X64)   Apr  2 2010 15:48:46   Copyright (c) Microsoft Corporation  Enterprise Edition (64-bit) on Windows NT 6.1 <X64> (Build 7600: ) 

- Active/passive cluster

- Oracle client 11gR1

- "Allow Inprocess" provider option is enabled


I'm stumped.  Our development, QA and UAT environments are all running the same versions of Windows, SQL, and Oracle client.  Linked server between SQL and Oracle works just fine.


Production is clustered.  The linked server works just fine on one node of the cluster, but if we failover to the other node, attempts to use the linked server in any way, OPENQUERY, GUI, etc..., cause the following error:

OLE DB provider "OraOLEDB.Oracle" for linked server "ORACLE" returned message "ORA-12634: Memory allocation failed".

Msg 7303, Level 16, State 1, Line 1

Cannot initialize the data source object of OLE DB provider "OraOLEDB.Oracle" for linked server "ORACLE".


What am I missing?  I've reinstalled the Oracle client on the defective node, verified that the SQL Server service account has full rights to the Oracle client dir

The action 'Move to node SQLN1' did not complete. An error occured moving the clustered service or


Hello All,

We have two nodes clustered 2008 SQL server running 5 instances (one default instance and the rest named instances). The default instance failed over to node 2 and now I cannot fail it back to node 1 and keep getting the following error when I try to move the instance I get the following error in Failover Cluster Managemen:

" The action 'Move to node SQLNV1' did not complete. An error occurred moving the clustered services or application 'SQL Server (MSSQLSERVER)'. the operation failed because either the specified cluster node is not the owner of the group, or the node is not possible owner of the group"

Thanks in advance!



Change the format of List Alert subscription Notification


When we subscribe to any list item for alerts we get an email message for confirmation of successfull subscription.


the email  looks like below :


Subject : You have successfully created an alert for 'Team Discussion: Topic 1


Body ;

Alert 'Team Discussion: Topic 1' has successfully been added on 'Test Site'.

You will receive alerts in e-mail. The timing and criteria for the alerts depend on the settings entered when the alert was added.

You can change this alert or any of your other alerts on the My Alerts on this Site page.


I wish to change the format of this email. Any Inputs ??


How to re-enable clustered node from previously Passive back to Active cluster?


Hi all experts,


I pretty new in SQL database along with WinServ clustering, so please mind my knowledge level in the overall process.


Base on the screenshot above, we have currently a single cluster created base in which that is controlling DB1 and DB2. Primarily DB1 would be our Active node whereas DB2 would be our Passive, both have it's own designated Public and Private IP. After a small issue previously in which our cluster service failed, it seems that the failover has taken place in which at the moment is running on DB2, which bears the question now is would it be possible to have DB1 being the Active node without downtime? and what is the process flow to change reactivate it back?

Servers Details:

- Win2k3 Ent Application Server

- Win2k3 Ent DB1&2

- IBM DS5020 SAN Storage

On the disk management on each DB servers, we are not able to see the LUNs in DB1 (shown as Unreadable) whereas on DB2 it is shown as normal, in which we would assume that this is normal since DB2 is the active node.

Thanks for reading & most of my search base on this question ended up in this forum, which I would assume that this is the correct place to ask.


2 Node Clustered SQl 2008 Sql Server Agent & Analysis Services Fail on only one node



Until recently this worked ok, however now on one of the 2 nodes if I fail over SQL all of the services start, on the other node, Sql Server Agent & Analysis Services will not come on line. I have checked some of the other links suggestiing fixes but they dont seem to apply. On the Node where it fails you get an error 53 for the server agent the Analysis Services fails with Generic service 'Analysis Services' could not be brought online (with error '1060') during an attempt to open the service.  Possible causes include: the service is either not installed or the specified service name is invalid.

attached is the details from the Sql Log

2011-04-06 13:13:32.05 Server      Microsoft SQL Server 2008 R2 (RTM) - 10.50.1600.1 (X64)
 Apr  2 2010 15:48:46
 Copyright (c) Microsoft Corporation
 Enterprise Edition (64-bit) on Windows NT 6.1 <X64> (Build 7600: )

2011-04-06 13:13:32.05 Server      (c) Microsoft Corporation.
2011-04-06 13:13:32.05 Server      All rights reserved.
2011-04-06 13:13:32.05 Server      Server process ID is 4744.
2011-04-06 13:13:32.05 Server      System Manufacturer: 'Dell Inc.', System Model: 'PowerEdge R610'.
2011-04-06 13:

How to Localize Windows Forms and Change the Language at Runtime

Localization is the process of customizing your application to a particular language, culture or locale. Visual Studio provides support for localizing Windows Forms with much ease. In this article, we will see how to localize windows forms and give the user the ability to change to his preferred language at runtime.
When you run a localized application, the appearance is determined by two culture values. The UICulture property is used to specify which resource files will be loaded for the form. The Culture property, on the other hand, determines how strings such as dates, numerals, and currency amounts are formatted.
Let us see the steps required to create a localized form. You can then expand this example and adopt the same approach for the rest of the forms in your project

Selected to change the background color of the page



As this site, http://www.borfin.com.tr/genel/Default.aspx, How can I change the background color selected pages.

Bug: Does not change column type from nvarchar to ntext


Scenario: If you create a table with a column of type nvarchar, populate it with some content and try to modify it using the WebMatrix editor, from nvarchar to ntext, it does not display any error message or warning that this is not possible. It silently saves and reverts the change, back to nvarchar. Wasted some hours on this issue as I thought my column was ntext, but in fact was still nvarchar.

Expected behavior: It should change to ntext, or if SQL CE doesn't support that, it should notify the user that no change was applied.

How to change the default page base class?


I've tried setting the <pages pageBaseType="DynamicWebPage" /> value in web.config, but when I response.write out the page type, I'm still getting Microsoft.WebPages.WebPage.

I'm simply trying to sub-class WebPage and add some additional functionality such as a dynamic PageData dictionary similar to Phil Haack's dynamic ViewData dictionary.



SqlDataSource how to change the stored procedures at run time



Is it possible to change the select, insert and update stored procedure of an SqlDataSource at run time. I don't mean to change the definition of the stored procedure, but I mean to change the assignment, i.e. To change the select stored procedure from "selectSP1" to "selectSP2" at run time. Is it possible?



ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend