Showing posts with label message. Show all posts
Showing posts with label message. Show all posts

Thursday, March 29, 2012

EndDialog

I have a SB program that sends a message and there is an activation procedure on my queue. The activation procedure takes the message from the queue, does some processing with the data, and ends the conversation. (I may, in the future, consider reusing the dialogs.) What I am wondering about is that I never come across the

'http://schemas.microsoft.com/SQL/ServiceBroker/EndDialog' message type name that indicates that the dialog has ended. Any ideas why?

From your description it sounds like the activated procedure issues the END CONVERSATION verb after processing the first message. After the END CONVERSATION verb was issued on a handle, you will not receive any other message on that conversation (including EndDialog sent by the peer). If we wouldn't ensure that application would have to keep around the state related to that conversation for an undetermined time.

HTH,

~ Remus

P.S. Thanks for writing those SSB articles

|||

Thanks Remus, that definetly makes sense. Because I won't see that EndDialog message type, what is the best way to go about cleaning the conversation up once I am finished? What I have ran into so far is that when I used END CONVERSATION WITH CLEANUP, the conversation remains in sys.conversation_endpoints with a status of 'Conversing', but if I omit 'WITH CLEANUP', the dialog will close as expected. I would like a way to cleanup that message so that it is removed from the catalog view. Does that make sense?

Thanks again,

Tim

|||

Never ever use END CONVERSATION ... WITH CLEANUP. It is realy a last resort statement itended for administrators. Using it in applications can result in very serious problems.

You must decide who ends the conversation first, depending on the business semantics of the conversation. The party that ends the conversation first is the first one that can say 'I am no longer interested in this conversation, even if this last (EndDialog) message never makes it to my peer'. Some common patterns are:

Notification

1) Initiator begins conversation

2) Initiator sends the notification message

3) Target receives the message

4) Target ends the conversations

5) Initiator receives EndDialog message

6) Initiator ends the conversation

Request-Response (when target does not care is response is lost)

1) Initiator begins conversation

2) Initiator sends the request message

3) Target receives the message

4) Target sends response

5) Target ends the conversations

6) Intiator receives the response

7) Initiator receives EndDialog message

8) Initiator ends the conversation

Request-Response (when target does care is response is lost)

1) Initiator begins conversation

2) Initiator sends the request message

3) Target receives the message

4) Target sends response

5) Intiator receives the response

6) Initiator ends the conversation

7) target receives EndDialog message

8) target ends the conversation

One way stream of messages

1) Initiator begins conversation

2) Initiator sends the one message

2') Initiator sends the one message ...

3) Target receives message(s)

... conversation continues for while with initiator sending messages

4) Initiator decides to intrerupt the stream and sends a special application message (EndOfStream)

5) Target receives the EndOfSream message

6) Target ends the conversations

7) Initiator receives EndDialog message

8) Initiator ends the conversation

One pattern that is actually incorrect is fire-and-forget: initiator begins a conversation, then sends one or more messages, then ends the conversation. This way the initiator never gets any feedback if the messages we actually sent or not. I have a blog entry on this subject: http://blogs.msdn.com/remusrusanu/archive/2006/04/06/570578.aspx

It is important to mention the conversation lifetime role in these patterns. If a conversation is not ended by both sides before it's lifetime expires, the conversation is errored and an Error message is sent to any endpoint still open (not ended). This is why endpoints that still care about delivery of the last message sent cannot issue an END CONVERSATION. They are supposed to send the message and the if they get an EndDialog message is a confrmation of succesfull delivery, while an Error message is an indication of a problem.

As about the endpoint states, a 'Conversing' endpoint is an endpoint that did not receive nor sent an EndDialog message. All of the patterns I mention above clean up the endpoints after issuing the END CONVERSATION. The first endpoint that issues the END CONVERSATION will be kept in the system until the EndDialog message is acknowledged by the peer (in an DISCONNECTED_OUTBOUND state), then it will be closed. An endpoint that has received an EndDialog message will stay in DISCONNECTED_INBOUND state until is explictly ended with END CONVERSATION, then it will be closed.

When initiator endpoint is closed, the endpoint is immedeately deleted.

When target endpoint is closed, the endpoint might be kept around for up to 30 minutes to prevent a replay attack, then it will be deleted.

Another negative side effect of the fire-and-forget pattern is that the target endpoint is not kept for 30 minutes in that case, but until the original conversation lifetime expires. Since most application do not specify a lifetime, that mens the target is scheduled to be deleted 74 years from now, thus being leaked for all practical means.

HTH,

~ Remus

|||Thanks again Remus, this is perfect. I was confused about the dialogs getting cleaned up. I noticed that the WITH CLEANUP cleaned the dialog up, and that is what I wanted at the time. I have since taken this out of all of my code. I didn't realize that the dialogs got cleaned up after 30 minutes to prevent a replay attack. Thanks again for your help...I love this new feature of 2005.
Timsql

end conversation : security context could not be retrieved

HI

I have a service broker setup between 2 remote server. The message send does get sent to the target, but I am having a problem where the end conversation message from the target is failing. I did a trace on both the target and the source server. here's what I found

On the Target Server:

on Broker: Message undeliverable This message could not be delivered because it is a duplicate

On the Source Server

on Broker: Message undeliverable This message could not be delivered because the security context could not be retrieved,

I do not understand why the message is delivered, but the end conversation message is not getting thru. On the Target transmission_queue. I have millions of messages like this

conversation_handle to_service_name is_end_of_dialog message_body transmission_status

E0C69E8F-37E9-DB11-AB7A-00145E7A209C source 1 NULL

I reinstalled the broker several times, but always get this problem.

thanks

Paul

Each Broker: Message undeliverable This message could not be delivered because the security context could not be retrieved event should also be accompanied by an event of type Security Audit/Audit Broker Conversation. That info should explain why the 'security context could not be retrieved'.|||

Hi

I did trace with audit broker conversation, there is this event after it, but there are not error message? I recently ungraded to sp3, could this be a problem

thanks

Paul

|||

HI

I was reading the other thread about no security header and check the time in the enqueue time, which was ahead of the server time

the last enqueue_time on the target was

2007-04-13 22:27:16

but when I did a select getdate()

I get 2007-04-13 20:24:03

how can the enqueue time be in the future?

thanks

Paul

|||what is the event subclass?|||Because of the distributed nature of messaging, all SSB times are UTC|||

it is : no security header. but I check the time on both machines, they are the same. If they were different, the send message would have the same error as the end dialog message?

Paul

|||Check if UTC time is the same, using getutcdate(). A problem could be if latest daylight savings patch was applied on one machine and not on other.|||

hum? I did a getutcdate() on both machines, they show the same time. If the time was the problem, wouldn't the sent message fail too? But I am unable to verify whether KB931836 was installed on one of the machines. I'll need to ask the SA on Monday. But the date change patch you bring up is an interesting point. If one of the machine does not have the patch, it would explain another problem we had last week regarding insert records from another machines where its was 1 hr late. thanks for the help. we'll see monday

Paul

|||

HI

I still have this problem, I was told that the servers where both patched with sp2 several weeks ago. I did more tracing on the sender and target. It seems the end dialog message from the target was successfully pocessed by the sender queue. Only after when the queue process the end dialog do I see "security context could not be retrieved" in the trace. Does Service Broker send another message to the the target after the sender ends the conversation?

Paul

|||

I met the same problem in our environment. our environment is:

Sender: SQL 2005 SP1, 64Bit CPU, windows 2003, 32G memory (currently only has SSB run on it, seems use more than 20g memory and about 40 % cpu resource)

Target: SQL 2005 SP1 ,32bit CPU, widnows 2003, 16G? memory.

the same situation, when the sender END CONVERSATION... i get the "security context could not be retrieved" from profiler90.

end conversation : security context could not be retrieved

HI

I have a service broker setup between 2 remote server. The message send does get sent to the target, but I am having a problem where the end conversation message from the target is failing. I did a trace on both the target and the source server. here's what I found

On the Target Server:

on Broker: Message undeliverable This message could not be delivered because it is a duplicate

On the Source Server

on Broker: Message undeliverable This message could not be delivered because the security context could not be retrieved,

I do not understand why the message is delivered, but the end conversation message is not getting thru. On the Target transmission_queue. I have millions of messages like this

conversation_handle to_service_name is_end_of_dialog message_body transmission_status

E0C69E8F-37E9-DB11-AB7A-00145E7A209C source 1 NULL

I reinstalled the broker several times, but always get this problem.

thanks

Paul

Each Broker: Message undeliverable This message could not be delivered because the security context could not be retrieved event should also be accompanied by an event of type Security Audit/Audit Broker Conversation. That info should explain why the 'security context could not be retrieved'.|||

Hi

I did trace with audit broker conversation, there is this event after it, but there are not error message? I recently ungraded to sp3, could this be a problem

thanks

Paul

|||

HI

I was reading the other thread about no security header and check the time in the enqueue time, which was ahead of the server time

the last enqueue_time on the target was

2007-04-13 22:27:16

but when I did a select getdate()

I get 2007-04-13 20:24:03

how can the enqueue time be in the future?

thanks

Paul

|||what is the event subclass?|||Because of the distributed nature of messaging, all SSB times are UTC|||

it is : no security header. but I check the time on both machines, they are the same. If they were different, the send message would have the same error as the end dialog message?

Paul

|||Check if UTC time is the same, using getutcdate(). A problem could be if latest daylight savings patch was applied on one machine and not on other.|||

hum? I did a getutcdate() on both machines, they show the same time. If the time was the problem, wouldn't the sent message fail too? But I am unable to verify whether KB931836 was installed on one of the machines. I'll need to ask the SA on Monday. But the date change patch you bring up is an interesting point. If one of the machine does not have the patch, it would explain another problem we had last week regarding insert records from another machines where its was 1 hr late. thanks for the help. we'll see monday

Paul

|||

HI

I still have this problem, I was told that the servers where both patched with sp2 several weeks ago. I did more tracing on the sender and target. It seems the end dialog message from the target was successfully pocessed by the sender queue. Only after when the queue process the end dialog do I see "security context could not be retrieved" in the trace. Does Service Broker send another message to the the target after the sender ends the conversation?

Paul

|||

I met the same problem in our environment. our environment is:

Sender: SQL 2005 SP1, 64Bit CPU, windows 2003, 32G memory (currently only has SSB run on it, seems use more than 20g memory and about 40 % cpu resource)

Target: SQL 2005 SP1 ,32bit CPU, widnows 2003, 16G? memory.

the same situation, when the sender END CONVERSATION... i get the "security context could not be retrieved" from profiler90.

end conversation : security context could not be retrieved

HI

I have a service broker setup between 2 remote server. The message send does get sent to the target, but I am having a problem where the end conversation message from the target is failing. I did a trace on both the target and the source server. here's what I found

On the Target Server:

on Broker: Message undeliverable This message could not be delivered because it is a duplicate

On the Source Server

on Broker: Message undeliverable This message could not be delivered because the security context could not be retrieved,

I do not understand why the message is delivered, but the end conversation message is not getting thru. On the Target transmission_queue. I have millions of messages like this

conversation_handle to_service_name is_end_of_dialog message_body transmission_status

E0C69E8F-37E9-DB11-AB7A-00145E7A209C source 1 NULL

I reinstalled the broker several times, but always get this problem.

thanks

Paul

Each Broker: Message undeliverable This message could not be delivered because the security context could not be retrieved event should also be accompanied by an event of type Security Audit/Audit Broker Conversation. That info should explain why the 'security context could not be retrieved'.|||

Hi

I did trace with audit broker conversation, there is this event after it, but there are not error message? I recently ungraded to sp3, could this be a problem

thanks

Paul

|||

HI

I was reading the other thread about no security header and check the time in the enqueue time, which was ahead of the server time

the last enqueue_time on the target was

2007-04-13 22:27:16

but when I did a select getdate()

I get 2007-04-13 20:24:03

how can the enqueue time be in the future?

thanks

Paul

|||what is the event subclass?|||Because of the distributed nature of messaging, all SSB times are UTC|||

it is : no security header. but I check the time on both machines, they are the same. If they were different, the send message would have the same error as the end dialog message?

Paul

|||Check if UTC time is the same, using getutcdate(). A problem could be if latest daylight savings patch was applied on one machine and not on other.|||

hum? I did a getutcdate() on both machines, they show the same time. If the time was the problem, wouldn't the sent message fail too? But I am unable to verify whether KB931836 was installed on one of the machines. I'll need to ask the SA on Monday. But the date change patch you bring up is an interesting point. If one of the machine does not have the patch, it would explain another problem we had last week regarding insert records from another machines where its was 1 hr late. thanks for the help. we'll see monday

Paul

|||

HI

I still have this problem, I was told that the servers where both patched with sp2 several weeks ago. I did more tracing on the sender and target. It seems the end dialog message from the target was successfully pocessed by the sender queue. Only after when the queue process the end dialog do I see "security context could not be retrieved" in the trace. Does Service Broker send another message to the the target after the sender ends the conversation?

Paul

|||

I met the same problem in our environment. our environment is:

Sender: SQL 2005 SP1, 64Bit CPU, windows 2003, 32G memory (currently only has SSB run on it, seems use more than 20g memory and about 40 % cpu resource)

Target: SQL 2005 SP1 ,32bit CPU, widnows 2003, 16G? memory.

the same situation, when the sender END CONVERSATION... i get the "security context could not be retrieved" from profiler90.

sql

Monday, March 26, 2012

Encryption not supported on SQL Server - Error Message

Hi,
When I click on the MSDB node, under Stored Packages (in Object Explorer | my local server's Integration Services), I get the following error message:
Client unable to establish connection
Encryption not supported on SQL Server. (Microsoft SQL Native Client)
I can, however successfully, enumerate File System packages.
I am running...
Microsoft SQL Server 2005 - 9.00.1187.07 (Intel X86)
May 24 2005 18:22:46
Copyright (c) 1988-2005 Microsoft Corporation
Standard Edition on Windows NT 5.2 (Build 3790: Service Pack 1)
...on Windows Server 2003 SP1
Does anyone know what is causing this, and how to fix it?
Thanks,
krog
Appears to be related to the following post:
http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=19019
...so I need to install a certificate on my computer.Idea Am now checking whether I can use the MakeCert utility to address this.
|||Did MakeCert resolve this - if so, would you please post the entire process - having same problem - thx|||If you installed your SQL Server 2005 as an named instance with a default SQL Server 2000 on the machine, you might need to change the SSIS configuration file to point the MSDB to the right instance. After changing the configuration file, you need to restart the SSIS service.|||To Add to Roro

Edit the config file MsDtsSrvr.ini.xml in C:\Program Files\Microsoft SQL Server\90\DTS\Binn as follwos:

=====================================
<?xml version="1.0" encoding="utf-8"?>
<DtsServiceConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<StopExecutingPackagesOnShutdown>true</StopExecutingPackagesOnShutdown>
<TopLevelFolders>
<Folder xsi:type="SqlServerFolder">
<Name>MSDB</Name>
<ServerName>SQL_2K5_SERVER_NAME</ServerName>
</Folder>
<Folder xsi:type="FileSystemFolder">
<Name>File System</Name>
<StorePath>..\Packages</StorePath>
</Folder>
</TopLevelFolders>
</DtsServiceConfiguration>
===============================

The original value for <ServerName> is just a dot (.)|||

Thanks a lot for your replies, people! I ran into the same problem and this thread helped me saved a bunch of time!! :)

|||

Yep, agree to that, thanks for the post. Restarted SSIS and it worked a treat.

Cheers - R.

|||What was resolution? Even I am also running into same problem as I have 2 SQL instances on same server

Encryption not supported on SQL Server - Error Message

Hi,
When I click on the MSDB node, under Stored Packages (in Object Explorer | my local server's Integration Services), I get the following error message:
Client unable to establish connection
Encryption not supported on SQL Server. (Microsoft SQL Native Client)
I can, however successfully, enumerate File System packages.
I am running...
Microsoft SQL Server 2005 - 9.00.1187.07 (Intel X86)
May 24 2005 18:22:46
Copyright (c) 1988-2005 Microsoft Corporation
Standard Edition on Windows NT 5.2 (Build 3790: Service Pack 1)
...on Windows Server 2003 SP1
Does anyone know what is causing this, and how to fix it?
Thanks,
krog
Appears to be related to the following post:
http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=19019
...so I need to install a certificate on my computer.Idea Am now checking whether I can use the MakeCert utility to address this.
|||Did MakeCert resolve this - if so, would you please post the entire process - having same problem - thx|||If you installed your SQL Server 2005 as an named instance with a default SQL Server 2000 on the machine, you might need to change the SSIS configuration file to point the MSDB to the right instance. After changing the configuration file, you need to restart the SSIS service.|||To Add to Roro

Edit the config file MsDtsSrvr.ini.xml in C:\Program Files\Microsoft SQL Server\90\DTS\Binn as follwos:

=====================================
<?xml version="1.0" encoding="utf-8"?>
<DtsServiceConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<StopExecutingPackagesOnShutdown>true</StopExecutingPackagesOnShutdown>
<TopLevelFolders>
<Folder xsi:type="SqlServerFolder">
<Name>MSDB</Name>
<ServerName>SQL_2K5_SERVER_NAME</ServerName>
</Folder>
<Folder xsi:type="FileSystemFolder">
<Name>File System</Name>
<StorePath>..\Packages</StorePath>
</Folder>
</TopLevelFolders>
</DtsServiceConfiguration>
===============================

The original value for <ServerName> is just a dot (.)|||

Thanks a lot for your replies, people! I ran into the same problem and this thread helped me saved a bunch of time!! :)

|||

Yep, agree to that, thanks for the post. Restarted SSIS and it worked a treat.

Cheers - R.

|||What was resolution? Even I am also running into same problem as I have 2 SQL instances on same server

Encryption not supported on SQL Server - Error Message

Hi,
When I click on the MSDB node, under Stored Packages (in Object Explorer | my local server's Integration Services), I get the following error message:
Client unable to establish connection
Encryption not supported on SQL Server. (Microsoft SQL Native Client)
I can, however successfully, enumerate File System packages.
I am running...
Microsoft SQL Server 2005 - 9.00.1187.07 (Intel X86)
May 24 2005 18:22:46
Copyright (c) 1988-2005 Microsoft Corporation
Standard Edition on Windows NT 5.2 (Build 3790: Service Pack 1)
...on Windows Server 2003 SP1
Does anyone know what is causing this, and how to fix it?
Thanks,
krog
Appears to be related to the following post:
http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=19019
...so I need to install a certificate on my computer.Idea Am now checking whether I can use the MakeCert utility to address this.
|||Did MakeCert resolve this - if so, would you please post the entire process - having same problem - thx|||If you installed your SQL Server 2005 as an named instance with a default SQL Server 2000 on the machine, you might need to change the SSIS configuration file to point the MSDB to the right instance. After changing the configuration file, you need to restart the SSIS service.|||To Add to Roro

Edit the config file MsDtsSrvr.ini.xml in C:\Program Files\Microsoft SQL Server\90\DTS\Binn as follwos:

=====================================
<?xml version="1.0" encoding="utf-8"?>
<DtsServiceConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<StopExecutingPackagesOnShutdown>true</StopExecutingPackagesOnShutdown>
<TopLevelFolders>
<Folder xsi:type="SqlServerFolder">
<Name>MSDB</Name>
<ServerName>SQL_2K5_SERVER_NAME</ServerName>
</Folder>
<Folder xsi:type="FileSystemFolder">
<Name>File System</Name>
<StorePath>..\Packages</StorePath>
</Folder>
</TopLevelFolders>
</DtsServiceConfiguration>
===============================

The original value for <ServerName> is just a dot (.)|||

Thanks a lot for your replies, people! I ran into the same problem and this thread helped me saved a bunch of time!! :)

|||

Yep, agree to that, thanks for the post. Restarted SSIS and it worked a treat.

Cheers - R.

|||What was resolution? Even I am also running into same problem as I have 2 SQL instances on same server

Encryption not supported on SQL Server - Error Message

Hi,
When I click on the MSDB node, under Stored Packages (in Object Explorer | my local server's Integration Services), I get the following error message:
Client unable to establish connection
Encryption not supported on SQL Server. (Microsoft SQL Native Client)
I can, however successfully, enumerate File System packages.
I am running...
Microsoft SQL Server 2005 - 9.00.1187.07 (Intel X86)
May 24 2005 18:22:46
Copyright (c) 1988-2005 Microsoft Corporation
Standard Edition on Windows NT 5.2 (Build 3790: Service Pack 1)
...on Windows Server 2003 SP1
Does anyone know what is causing this, and how to fix it?
Thanks,
krog
Appears to be related to the following post:
http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=19019
...so I need to install a certificate on my computer.Idea Am now checking whether I can use the MakeCert utility to address this.
|||Did MakeCert resolve this - if so, would you please post the entire process - having same problem - thx|||If you installed your SQL Server 2005 as an named instance with a default SQL Server 2000 on the machine, you might need to change the SSIS configuration file to point the MSDB to the right instance. After changing the configuration file, you need to restart the SSIS service.|||To Add to Roro

Edit the config file MsDtsSrvr.ini.xml in C:\Program Files\Microsoft SQL Server\90\DTS\Binn as follwos:

=====================================
<?xml version="1.0" encoding="utf-8"?>
<DtsServiceConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<StopExecutingPackagesOnShutdown>true</StopExecutingPackagesOnShutdown>
<TopLevelFolders>
<Folder xsi:type="SqlServerFolder">
<Name>MSDB</Name>
<ServerName>SQL_2K5_SERVER_NAME</ServerName>
</Folder>
<Folder xsi:type="FileSystemFolder">
<Name>File System</Name>
<StorePath>..\Packages</StorePath>
</Folder>
</TopLevelFolders>
</DtsServiceConfiguration>
===============================

The original value for <ServerName> is just a dot (.)|||

Thanks a lot for your replies, people! I ran into the same problem and this thread helped me saved a bunch of time!! :)

|||

Yep, agree to that, thanks for the post. Restarted SSIS and it worked a treat.

Cheers - R.

|||What was resolution? Even I am also running into same problem as I have 2 SQL instances on same serversql

Encryption not supported on SQL Server - Error Message

Hi,
When I click on the MSDB node, under Stored Packages (in Object Explorer | my local server's Integration Services), I get the following error message:
Client unable to establish connection
Encryption not supported on SQL Server. (Microsoft SQL Native Client)
I can, however successfully, enumerate File System packages.
I am running...
Microsoft SQL Server 2005 - 9.00.1187.07 (Intel X86)
May 24 2005 18:22:46
Copyright (c) 1988-2005 Microsoft Corporation
Standard Edition on Windows NT 5.2 (Build 3790: Service Pack 1)
...on Windows Server 2003 SP1
Does anyone know what is causing this, and how to fix it?
Thanks,
krog
Appears to be related to the following post:
http://forums.microsoft.com/msdn/ShowPost.aspx?PostID=19019
...so I need to install a certificate on my computer.Idea Am now checking whether I can use the MakeCert utility to address this.
|||Did MakeCert resolve this - if so, would you please post the entire process - having same problem - thx|||If you installed your SQL Server 2005 as an named instance with a default SQL Server 2000 on the machine, you might need to change the SSIS configuration file to point the MSDB to the right instance. After changing the configuration file, you need to restart the SSIS service.|||To Add to Roro

Edit the config file MsDtsSrvr.ini.xml in C:\Program Files\Microsoft SQL Server\90\DTS\Binn as follwos:

=====================================
<?xml version="1.0" encoding="utf-8"?>
<DtsServiceConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<StopExecutingPackagesOnShutdown>true</StopExecutingPackagesOnShutdown>
<TopLevelFolders>
<Folder xsi:type="SqlServerFolder">
<Name>MSDB</Name>
<ServerName>SQL_2K5_SERVER_NAME</ServerName>
</Folder>
<Folder xsi:type="FileSystemFolder">
<Name>File System</Name>
<StorePath>..\Packages</StorePath>
</Folder>
</TopLevelFolders>
</DtsServiceConfiguration>
===============================

The original value for <ServerName> is just a dot (.)|||

Thanks a lot for your replies, people! I ran into the same problem and this thread helped me saved a bunch of time!! :)

|||

Yep, agree to that, thanks for the post. Restarted SSIS and it worked a treat.

Cheers - R.

|||What was resolution? Even I am also running into same problem as I have 2 SQL instances on same server

Encryption in SQL Server 2005.

Can anyone tell me what is the best approach for Encyrption in SQLServer 200
5
? If there is any sample scripts that you link me to. Thanks,
Sam.
Message posted via http://www.droptable.comHow much of your data are you encrypting?
"SAM via droptable.com" <u33747@.uwe> wrote in message
news:7c011375421da@.uwe...
> Can anyone tell me what is the best approach for Encyrption in SQLServer
> 2005
> ? If there is any sample scripts that you link me to. Thanks,
> Sam.
> --
> Message posted via http://www.droptable.com
>|||I need to encrypt 2 colums in a table.Which contains the SQL login and the
password. The record count is around 100.
Decryption should be done by specific sql user /or role /or a Window Active
directory login. Any help would be appreciated. Thanks
Mike C# wrote:[vbcol=seagreen]
>How much of your data are you encrypting?
>
Message posted via http://www.droptable.com|||Check this out
Simple demo for how to encrypt and decrypt a table column in SQL Server 2005
http://blogs.msdn.com/lcris/archive.../09/427523.aspx
This uses the concept of keys in SQL Server 2005 with samples
"Prem via droptable.com" <u33747@.uwe> wrote in message
news:7c01762276e56@.uwe...
>I need to encrypt 2 colums in a table.Which contains the SQL login and the
> password. The record count is around 100.
> Decryption should be done by specific sql user /or role /or a Window
> Active
> directory login. Any help would be appreciated. Thanks
>
> Mike C# wrote:
> --
> Message posted via http://www.droptable.com
>

Sunday, March 11, 2012

EncryptByCert Problem

I posted this message to the wrong group (sqlserver.programming), so I'm
reposting here. Sorry for the repost... it's late... so here goes:
OK, so I'm testing EncryptByCert with some code like the following:
DECLARE @.v varchar(8000);
SELECT @.v = REPLICATE('A', 117);
SELECT @.v;
DECLARE @.e varbinary(8000);
SELECT @.e = EncryptByCert(Cert_ID(N'TestCertificate'
), @.v);
SELECT @.e;
The function encrypts fine and I'm able to use DecryptByCert to get the
result. Problem is if I change the line SELECT @.v = REPLICATE('A', 117) to:
SELECT @.v = REPLICATE('A', 118);
The EncryptByCert function returns NULL every time with 118 or higher. BOL
states that the result is returned as a varbinary with a max length of
8,000. I keep getting a varbinary with a max length of 128. Can anyone
else reproduce this, or am I doing something wrong?
ThanksYes, this is a restriction of asymmetric key encryption - the actual data
that you can encrypt with one call will depend on the size of the private
key that is used.
For example: 512 bit RSA key can encrypt up to 53 bytes, 1024 bit up to 117
bytes, and 2048 bit up to 245 bytes.
See http://blogs.msdn.com/yukondoit/arc.../24/496521.aspx for a
workaround, if you really want to encrypt more.
Certificates should only be used to protect other keys, not to encrypt data
directly, so this limit does not impact the intended use of certificates.
Thanks
Laurentiu Cristofor [MSFT]
Software Design Engineer
SQL Server Engine
http://blogs.msdn.com/lcris/
This posting is provided "AS IS" with no warranties, and confers no rights.
"Mike C#" <xyz@.xyz.com> wrote in message
news:fuaHg.586$k%3.406@.newsfe12.lga...
>I posted this message to the wrong group (sqlserver.programming), so I'm
>reposting here. Sorry for the repost... it's late... so here goes:
> OK, so I'm testing EncryptByCert with some code like the following:
> DECLARE @.v varchar(8000);
> SELECT @.v = REPLICATE('A', 117);
> SELECT @.v;
> DECLARE @.e varbinary(8000);
> SELECT @.e = EncryptByCert(Cert_ID(N'TestCertificate'
), @.v);
> SELECT @.e;
> The function encrypts fine and I'm able to use DecryptByCert to get the
> result. Problem is if I change the line SELECT @.v = REPLICATE('A', 117)
> to:
> SELECT @.v = REPLICATE('A', 118);
> The EncryptByCert function returns NULL every time with 118 or higher.
> BOL states that the result is returned as a varbinary with a max length of
> 8,000. I keep getting a varbinary with a max length of 128. Can anyone
> else reproduce this, or am I doing something wrong?
> Thanks
>|||Someone needs to tell the BOL writers to update the page on this then. It
currently indicates that EncryptByCert can return a varbinary up to 8,000
bytes in length, which is ludicrous if the input is really limited to 421
bytes and the output is limited to 432 bytes. I'm not advocating using
certificates and asymmetric keys to encrypt all data. I am advocating
accurate documentation of system limitations.
"Laurentiu Cristofor [MSFT]" <laur@.nospam.com> wrote in message
news:e2ASWY6xGHA.4336@.TK2MSFTNGP06.phx.gbl...
> Yes, this is a restriction of asymmetric key encryption - the actual data
> that you can encrypt with one call will depend on the size of the private
> key that is used.
> For example: 512 bit RSA key can encrypt up to 53 bytes, 1024 bit up to
> 117 bytes, and 2048 bit up to 245 bytes.
> See http://blogs.msdn.com/yukondoit/arc.../24/496521.aspx for a
> workaround, if you really want to encrypt more.
> Certificates should only be used to protect other keys, not to encrypt
> data directly, so this limit does not impact the intended use of
> certificates.
> Thanks
> --
> Laurentiu Cristofor [MSFT]
> Software Design Engineer
> SQL Server Engine
> http://blogs.msdn.com/lcris/
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
> "Mike C#" <xyz@.xyz.com> wrote in message
> news:fuaHg.586$k%3.406@.newsfe12.lga...
>|||I'll ask for an update of these BOL topics to mention the restrictions
related to the key lenghts. If you access BOL online, you can also rate the
articles and submit feedback directly. Here are the links for the topics we
discussed:
http://msdn2.microsoft.com/en-us/library/ms188061.aspx
http://msdn2.microsoft.com/en-us/library/ms186950.aspx
Thanks
Laurentiu Cristofor [MSFT]
Software Design Engineer
SQL Server Engine
http://blogs.msdn.com/lcris/
This posting is provided "AS IS" with no warranties, and confers no rights.
"Mike C#" <xyz@.xyz.com> wrote in message
news:%23vuAcc6xGHA.3500@.TK2MSFTNGP02.phx.gbl...
> Someone needs to tell the BOL writers to update the page on this then. It
> currently indicates that EncryptByCert can return a varbinary up to 8,000
> bytes in length, which is ludicrous if the input is really limited to 421
> bytes and the output is limited to 432 bytes. I'm not advocating using
> certificates and asymmetric keys to encrypt all data. I am advocating
> accurate documentation of system limitations.
> "Laurentiu Cristofor [MSFT]" <laur@.nospam.com> wrote in message
> news:e2ASWY6xGHA.4336@.TK2MSFTNGP06.phx.gbl...
>|||Thanks. I wanted to get verification and make sure it wasn't a problem with
my installation or how I was using the functions before I claimed errors in
either the application or the documentation.
"Laurentiu Cristofor [MSFT]" <laur@.nospam.com> wrote in message
news:Ovyex47xGHA.1288@.TK2MSFTNGP03.phx.gbl...
> I'll ask for an update of these BOL topics to mention the restrictions
> related to the key lenghts. If you access BOL online, you can also rate
> the articles and submit feedback directly. Here are the links for the
> topics we discussed:
> http://msdn2.microsoft.com/en-us/library/ms188061.aspx
> http://msdn2.microsoft.com/en-us/library/ms186950.aspx
> Thanks
> --
> Laurentiu Cristofor [MSFT]
> Software Design Engineer
> SQL Server Engine
> http://blogs.msdn.com/lcris/
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
> "Mike C#" <xyz@.xyz.com> wrote in message
> news:%23vuAcc6xGHA.3500@.TK2MSFTNGP02.phx.gbl...
>|||Also, in the meantime, you may want to use the following reference:
http://msdn.microsoft.com/library/d...ryptencrypt.asp
The relevant paragraph extracted from above is:
The Microsoft Enhanced Cryptographic Provider supports direct encryption
with RSA public keys and decryption with RSA private keys. The encryption
uses PKCS #1 padding. On decryption, this padding is verified. The length of
plaintext data that can be encrypted with a call to CryptEncrypt with an RSA
key is the length of the key modulus minus eleven bytes. The eleven bytes is
the chosen minimum for PKCS #1 padding. The ciphertext is returned in
little-endian format.
Thanks
Laurentiu Cristofor [MSFT]
Software Design Engineer
SQL Server Engine
http://blogs.msdn.com/lcris/
This posting is provided "AS IS" with no warranties, and confers no rights.
"Laurentiu Cristofor [MSFT]" <laur@.nospam.com> wrote in message
news:Ovyex47xGHA.1288@.TK2MSFTNGP03.phx.gbl...
> I'll ask for an update of these BOL topics to mention the restrictions
> related to the key lenghts. If you access BOL online, you can also rate
> the articles and submit feedback directly. Here are the links for the
> topics we discussed:
> http://msdn2.microsoft.com/en-us/library/ms188061.aspx
> http://msdn2.microsoft.com/en-us/library/ms186950.aspx
> Thanks
> --
> Laurentiu Cristofor [MSFT]
> Software Design Engineer
> SQL Server Engine
> http://blogs.msdn.com/lcris/
> This posting is provided "AS IS" with no warranties, and confers no
> rights.
> "Mike C#" <xyz@.xyz.com> wrote in message
> news:%23vuAcc6xGHA.3500@.TK2MSFTNGP02.phx.gbl...
>

Friday, March 9, 2012

encrypt database --

Hi,
Sorry for the message in spanish I confused the group.
Is there a way to encrypt a database (tables, columns, etc.) ? I want that
nobody can see the data model of my application
Probably it's impossible to deny access to the database, but at least if
someone is trying to copy my design he/she will see the name of objects,
columns, and others encrypted. (For example instead of see the table
ARTICLE, see symbols ="!!$%&/- )
I'll appreciate your comments.
Edmundo J. DavilaYou can assign certificates and encryption keys under the security
folder of a database in SQL Server Management Studio, however, these
only encrypt the data stream that is sent from a SQL Server instance
to any SQL Server Agents.
If you install SQL Server to run from inside of Microsoft Virtual
Server, then the entire database file will be stacker compressed which
would be unreadable to human eyes. But, with any kind of encryption,
SQL Server will have to spend time decrypting fields as it walks any
kind of search and this will cause a significant performance hit.

Wednesday, March 7, 2012

Enabling MSSQLServerADHelper

I was installing application software that was trying to install SQL Server 2005 and received the following error message.

"Setup failed because Service MSSQLServerADHelper is disabled for the current hardware profile. Services must be set with the current Hardware Profile logon property profile enabled."

Simple fix for most but I do not know how to do what it asks.

Thanks, Bruce

Check this out as a good place to start:

http://support.microsoft.com/default.aspx?scid=kb;EN-US;q313939

Buck Woody

http://www.buckwoody.com

Sunday, February 26, 2012

Enabling MSSQLServerADHelper

I was installing application software that was trying to install SQL Server 2005 and received the following error message.

"Setup failed because Service MSSQLServerADHelper is disabled for the current hardware profile. Services must be set with the current Hardware Profile logon property profile enabled."

Simple fix for most but I do not know how to do what it asks.

Thanks, Bruce

Check this out as a good place to start:

http://support.microsoft.com/default.aspx?scid=kb;EN-US;q313939

Buck Woody

http://www.buckwoody.com

Enabling Diagram Support in SQL 2005

I get the message I must Alter Authorization. I have not been able to get
this to work. If you have successfully done this, please let me know what
you did.
Note: These are databases which have been restored from SQL 2000 backups,
if that is of any consequence.
Thanks
Migrating to SQL 2005
Since SQL 2005 is still in beta, you'll want to post this in the Community
Newsgroups:
http://communities.microsoft.com/new...r2005&slcid=us
--Brian
(Please reply to the newsgroups only.)
"Allan" <Allan@.discussions.microsoft.com> wrote in message
news:1E015795-FB82-41E7-8A39-C8B347860D35@.microsoft.com...
>I get the message I must Alter Authorization. I have not been able to get
> this to work. If you have successfully done this, please let me know what
> you did.
> Note: These are databases which have been restored from SQL 2000 backups,
> if that is of any consequence.
> Thanks
> --
> Migrating to SQL 2005

Enabling Diagram Support in SQL 2005

I get the message I must Alter Authorization. I have not been able to get
this to work. If you have successfully done this, please let me know what
you did.
Note: These are databases which have been restored from SQL 2000 backups,
if that is of any consequence.
Thanks
--
Migrating to SQL 2005Since SQL 2005 is still in beta, you'll want to post this in the Community
Newsgroups:
http://communities.microsoft.com/ne...lcid=us

--Brian
(Please reply to the newsgroups only.)
"Allan" <Allan@.discussions.microsoft.com> wrote in message
news:1E015795-FB82-41E7-8A39-C8B347860D35@.microsoft.com...
>I get the message I must Alter Authorization. I have not been able to get
> this to work. If you have successfully done this, please let me know what
> you did.
> Note: These are databases which have been restored from SQL 2000 backups,
> if that is of any consequence.
> Thanks
> --
> Migrating to SQL 2005

Enabling Diagram Support in SQL 2005

I get the message I must Alter Authorization. I have not been able to get
this to work. If you have successfully done this, please let me know what
you did.
Note: These are databases which have been restored from SQL 2000 backups,
if that is of any consequence.
Thanks
--
Migrating to SQL 2005Since SQL 2005 is still in beta, you'll want to post this in the Community
Newsgroups:
http://communities.microsoft.com/newsgroups/default.asp?icp=sqlserver2005&slcid=us
--
--Brian
(Please reply to the newsgroups only.)
"Allan" <Allan@.discussions.microsoft.com> wrote in message
news:1E015795-FB82-41E7-8A39-C8B347860D35@.microsoft.com...
>I get the message I must Alter Authorization. I have not been able to get
> this to work. If you have successfully done this, please let me know what
> you did.
> Note: These are databases which have been restored from SQL 2000 backups,
> if that is of any consequence.
> Thanks
> --
> Migrating to SQL 2005

Friday, February 17, 2012

Empty reports

In my ASP.Net application, I need to give the user an error message when
a report is empty. Sometimes there is an exception that gets thrown and
sometimes there is not. How can I tell if the stream coming back from
RS contains an empty report?In most cases even if the report contains no data the stream isn´t empty
(PDF,ect). Did you try to get a stream back that based on the CSV format ?
It don´t now whether there will be a zero byte stream returned back by the
report server, but that should be the stream with the least overhead. If you
know how many bytes an empty report contains, you could also check the size
of the stream to evaluate the minimun for it and then throw an exception if
it is below o equeals that minimun level.
(If you got your own Data service provider, but I think that isn´t in your
case you could check for the rows in the tabes of the dataset you are
apssing to the report)
--
HTH, Jens Suessmeyer.
--
http://www.sqlserver2005.de
--
"No One" <aintnoway@.blahblahblah.com> schrieb im Newsbeitrag
news:hlmnl2-ii3.ln1@.gandalf.grey-net.com...
> In my ASP.Net application, I need to give the user an error message when a
> report is empty. Sometimes there is an exception that gets thrown and
> sometimes there is not. How can I tell if the stream coming back from RS
> contains an empty report?|||There is a "No Rows" property on the table which allows the developer to
specify a string to display if no rows of data are available.
"No One" <aintnoway@.blahblahblah.com> wrote in message
news:hlmnl2-ii3.ln1@.gandalf.grey-net.com...
> In my ASP.Net application, I need to give the user an error message when
> a report is empty. Sometimes there is an exception that gets thrown and
> sometimes there is not. How can I tell if the stream coming back from
> RS contains an empty report?|||I don't want to return a "No Rows" file. I want to display that on the
browser without trying to send the user a file at all.
Jason wrote:
> There is a "No Rows" property on the table which allows the developer to
> specify a string to display if no rows of data are available.
> "No One" <aintnoway@.blahblahblah.com> wrote in message
> news:hlmnl2-ii3.ln1@.gandalf.grey-net.com...
>>In my ASP.Net application, I need to give the user an error message when
>>a report is empty. Sometimes there is an exception that gets thrown and
>>sometimes there is not. How can I tell if the stream coming back from
>>RS contains an empty report?
>
>

Wednesday, February 15, 2012

Empty Messagebox

Hi


When I start the MSQL Server Management Studio Express I get a Message Box with a yellow exclamation icon and NO message, just an OK button. Which when I press it goes away allowing me to logon to the Management Studiio.

All seems to be working fine (although I have not used it much since getting this strange behaviour).

I have re-installed Win XP Pro SP2, applied all patches from MS website, install is clean and no errors. Also downloaded latest SQLExpress Edition and as well as latest Server Management Studio.

Any ideas?

Thanks, any help will be appreciated.

I'm moving this to the Tools group where the management studio folks hang out.

Mike

|||

I recently installed Windows Live Local Add-in for Microsoft Office Outlook which also installed .Net 1.1 (although it was already installed on my PC along with .Net 2.0). I then started to get the same empty message box when Management Studio started. I did a repair on .Net 2.0 and the empty message box has stopped.

|||

Hi Steve

Thanks, that worked for me as well.

Had me worried!!

Regards.

Larry.

|||

This also occured after the install of SP2 for 2005 Developers Edition. (Blank message box with exclamation icon)

Repairing .Net 2.0 corrected the message.

I think it was caused by an update to the .Net 1.1 Framework that happened immediately following the install of SP2.

Thanks for the tip...

Empty Messagebox

Hi


When I start the MSQL Server Management Studio Express I get a Message Box with a yellow exclamation icon and NO message, just an OK button. Which when I press it goes away allowing me to logon to the Management Studiio.

All seems to be working fine (although I have not used it much since getting this strange behaviour).

I have re-installed Win XP Pro SP2, applied all patches from MS website, install is clean and no errors. Also downloaded latest SQLExpress Edition and as well as latest Server Management Studio.

Any ideas?

Thanks, any help will be appreciated.

I'm moving this to the Tools group where the management studio folks hang out.

Mike

|||

I recently installed Windows Live Local Add-in for Microsoft Office Outlook which also installed .Net 1.1 (although it was already installed on my PC along with .Net 2.0). I then started to get the same empty message box when Management Studio started. I did a repair on .Net 2.0 and the empty message box has stopped.

|||

Hi Steve

Thanks, that worked for me as well.

Had me worried!!

Regards.

Larry.

|||

This also occured after the install of SP2 for 2005 Developers Edition. (Blank message box with exclamation icon)

Repairing .Net 2.0 corrected the message.

I think it was caused by an update to the .Net 1.1 Framework that happened immediately following the install of SP2.

Thanks for the tip...