Monday, August 25, 2008
Arg! the telnet client is disabled by default in Vista
I'm trying to fix my dad's website, after his gallery suffered a sql injection and his database is no longer with us. I needed to check if port 2077 was open on the server to map a folder as a drive on my windows explorer after a few problems with my ftp connection timing out.
To make the story short, how to enable the telnet client on Vista:
Go to Control Panel.
Go to Programs.
Go to Program and Features.
Click Turn Windows Feature on or off.
Check mark the telnet client.
To make the story short, how to enable the telnet client on Vista:
Go to Control Panel.
Go to Programs.
Go to Program and Features.
Click Turn Windows Feature on or off.
Check mark the telnet client.
Labels: vista
Adding an NHibernate collection to your QuickWatch initializes it
I spent most of the day trying to improve performance on an application. We use NHibernate 2.0 and try to lazy load most of the collections.
I found these two links very useful for troubleshooting my performance issue:
http://djeeg.blogspot.com/2006/08/nhibernateutilisinitialized.html
and the NHibernate reference:
http://www.hibernate.org/hib_docs/nhibernate/html/performance.html
The curious thing is I got really confused when testing my
NHibernateUtil.IsInitialized(_myobject.MyCollection) line and it was false
but I saw a query retrieving the collection in Profiler...
until I realized that adding the collection to the Watch initializes it. The same happens if you open this collection in QuickWatch. :-p
I found these two links very useful for troubleshooting my performance issue:
http://djeeg.blogspot.com/2006/08/nhibernateutilisinitialized.html
and the NHibernate reference:
http://www.hibernate.org/hib_docs/nhibernate/html/performance.html
The curious thing is I got really confused when testing my
NHibernateUtil.IsInitialized(_myobject.MyCollection) line and it was false
but I saw a query retrieving the collection in Profiler...
until I realized that adding the collection to the Watch initializes it. The same happens if you open this collection in QuickWatch. :-p
Labels: NHibernate, Out of Curiosity
Wednesday, August 06, 2008
This merge replication error: The merge process could not connect to the Publisher 'Server:database' is so misleading
We have a merge topology in place with pull subscriptions, this is the merge agent runs at the subscribers.
One of our subscriptions in had the error that the merge process couldn't find the server. The server was there and the ping was fine, also the Replication Monitor was able to register the error with the x mark.
The details of the ertor are as follows:
Command attempted:
{call sp_MSensure_single_instance (N'Merge Agent Name', 4)}
Error messages:
The merge process could not connect to the Publisher 'Server:database'. Check to ensure that the server is running. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147199368)
Get help: http://help/MSSQL_REPL-2147199368
Another merge agent for the subscription(s) is running or the server is working on a previous request by the same agent. (Source: MSSQLServer, Error number: 21036)
Get help: http://help/21036
Our error was due to the second cause. It seems the subscriber had lost power while replicating, and any replication after that could not acquire a lock for the merge agent. We restarted the subscriber machine, reinitialized the subscription, with no luck. Only when we dropped the subscription and recreated it again the subscriber was able to run the replication agent again. Just a curious note for the future as this error is not well documented. The only MSDN forum thread that deals with is is still unanswered here...
One of our subscriptions in had the error that the merge process couldn't find the server. The server was there and the ping was fine, also the Replication Monitor was able to register the error with the x mark.
The details of the ertor are as follows:
Command attempted:
{call sp_MSensure_single_instance (N'Merge Agent Name', 4)}
Error messages:
The merge process could not connect to the Publisher 'Server:database'. Check to ensure that the server is running. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147199368)
Get help: http://help/MSSQL_REPL-2147199368
Another merge agent for the subscription(s) is running or the server is working on a previous request by the same agent. (Source: MSSQLServer, Error number: 21036)
Get help: http://help/21036
Our error was due to the second cause. It seems the subscriber had lost power while replicating, and any replication after that could not acquire a lock for the merge agent. We restarted the subscriber machine, reinitialized the subscription, with no luck. Only when we dropped the subscription and recreated it again the subscriber was able to run the replication agent again. Just a curious note for the future as this error is not well documented. The only MSDN forum thread that deals with is is still unanswered here...
Labels: Merge Replication, SQL Server stuff