Wednesday, March 28, 2012
killing SQLmail
restart the SQLMail using xp_stopmail and xp_startmail.
it stopped quickly, but when I ran xp_startmail, it
appeared to hang. I killed the process, now it's saying
that it's "Killed/Rollback". It's been like that for a
while now. Does anyone know a way to get rid of this?
Can this cause other headaches?
Rob,
Are you using Microsoft Exchange? Is the Exchange Server available? This
can happen when Exchange disappears, or you lose connectivity to it.
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Rob wrote:
> Our SQLMail stopped working, so I tried to stop and
> restart the SQLMail using xp_stopmail and xp_startmail.
> it stopped quickly, but when I ran xp_startmail, it
> appeared to hang. I killed the process, now it's saying
> that it's "Killed/Rollback". It's been like that for a
> while now. Does anyone know a way to get rid of this?
> Can this cause other headaches?
|||> This can happen when Exchange disappears
I'd question David Copperfield. ;-)
Oh, I can't wait for a more robust and independent mail platform in SQL
Server...
http://www.aspfaq.com/
(Reverse address to reply.)
|||I already tried that - that was also my first thought that is was because is
was doing it under wrong uder name, but that's not the case. I', logged in
to the server as the user that runs the SQLServer Agent service, and I can
open Outlook and get into the mailbox without any problems.
Regards
Steen
"Aaron [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> skrev i en meddelelse
news:OtVlLiCZEHA.2500@.TK2MSFTNGP09.phx.gbl...
> I'd question David Copperfield. ;-)
> Oh, I can't wait for a more robust and independent mail platform in SQL
> Server...
> --
> http://www.aspfaq.com/
> (Reverse address to reply.)
>
|||Steen,
Can you send mail from Outlook, logged on as the SQLAgent account?
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Steen Persson wrote:
> I already tried that - that was also my first thought that is was because is
> was doing it under wrong uder name, but that's not the case. I', logged in
> to the server as the user that runs the SQLServer Agent service, and I can
> open Outlook and get into the mailbox without any problems.
> Regards
> Steen
>
> "Aaron [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> skrev i en meddelelse
> news:OtVlLiCZEHA.2500@.TK2MSFTNGP09.phx.gbl...
>
>
|||...it seems like my previous reply to my problem has ended up in a wrong
thread - sorry 'bout that.
I have verified that I can send emails from Outlook. Everything seems to be
fine - I log on as the user that runs the SQL agent which is the same as the
user of the mailbox. The strange thing is that it worked fine the other day
when I installed Outlook on a few SQL servers, but now it fails with the
same error message on all of them. I'm wondering if there's something stupid
that I'm missing when I fire the xp_sendmail command.
The command I'm trying with just for the test is:
Use Master
EXEC xp_sendmail 'spe@.MyDomainName.dk', ' Test'
Shoudn't this be enough just to send an email or am I missing something?
Regards
Steen
"Mark Allison" <marka@.no.tinned.meat.mvps.org> skrev i en meddelelse
news:eFy9YYDZEHA.996@.TK2MSFTNGP12.phx.gbl...[vbcol=seagreen]
> Steen,
> Can you send mail from Outlook, logged on as the SQLAgent account?
> --
> Mark Allison, SQL Server MVP
> http://www.markallison.co.uk
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
>
> Steen Persson wrote:
because is[vbcol=seagreen]
in[vbcol=seagreen]
can[vbcol=seagreen]
killing SQLmail
restart the SQLMail using xp_stopmail and xp_startmail.
it stopped quickly, but when I ran xp_startmail, it
appeared to hang. I killed the process, now it's saying
that it's "Killed/Rollback". It's been like that for a
while now. Does anyone know a way to get rid of this?
Can this cause other headaches?Rob,
Are you using Microsoft Exchange? Is the Exchange Server available? This
can happen when Exchange disappears, or you lose connectivity to it.
--
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Rob wrote:
> Our SQLMail stopped working, so I tried to stop and
> restart the SQLMail using xp_stopmail and xp_startmail.
> it stopped quickly, but when I ran xp_startmail, it
> appeared to hang. I killed the process, now it's saying
> that it's "Killed/Rollback". It's been like that for a
> while now. Does anyone know a way to get rid of this?
> Can this cause other headaches?|||> This can happen when Exchange disappears
I'd question David Copperfield. ;-)
Oh, I can't wait for a more robust and independent mail platform in SQL
Server...
http://www.aspfaq.com/
(Reverse address to reply.)|||I already tried that - that was also my first thought that is was because is
was doing it under wrong uder name, but that's not the case. I', logged in
to the server as the user that runs the SQLServer Agent service, and I can
open Outlook and get into the mailbox without any problems.
Regards
Steen
"Aaron [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> skrev i en meddelelse
news:OtVlLiCZEHA.2500@.TK2MSFTNGP09.phx.gbl...
> I'd question David Copperfield. ;-)
> Oh, I can't wait for a more robust and independent mail platform in SQL
> Server...
> --
> http://www.aspfaq.com/
> (Reverse address to reply.)
>|||Steen,
Can you send mail from Outlook, logged on as the SQLAgent account?
--
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Steen Persson wrote:
> I already tried that - that was also my first thought that is was because
is
> was doing it under wrong uder name, but that's not the case. I', logged in
> to the server as the user that runs the SQLServer Agent service, and I can
> open Outlook and get into the mailbox without any problems.
> Regards
> Steen
>
> "Aaron [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> skrev i en meddelels
e
> news:OtVlLiCZEHA.2500@.TK2MSFTNGP09.phx.gbl...
>
>
>|||...it seems like my previous reply to my problem has ended up in a wrong
thread - sorry 'bout that.
I have verified that I can send emails from Outlook. Everything seems to be
fine - I log on as the user that runs the SQL agent which is the same as the
user of the mailbox. The strange thing is that it worked fine the other day
when I installed Outlook on a few SQL servers, but now it fails with the
same error message on all of them. I'm wondering if there's something stupid
that I'm missing when I fire the xp_sendmail command.
The command I'm trying with just for the test is:
Use Master
EXEC xp_sendmail 'spe@.MyDomainName.dk', ' Test'
Shoudn't this be enough just to send an email or am I missing something?
Regards
Steen
"Mark Allison" <marka@.no.tinned.meat.mvps.org> skrev i en meddelelse
news:eFy9YYDZEHA.996@.TK2MSFTNGP12.phx.gbl...[vbcol=seagreen]
> Steen,
> Can you send mail from Outlook, logged on as the SQLAgent account?
> --
> Mark Allison, SQL Server MVP
> http://www.markallison.co.uk
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
>
> Steen Persson wrote:
because is[vbcol=seagreen]
in[vbcol=seagreen]
can[vbcol=seagreen]sql
killing SQLmail
restart the SQLMail using xp_stopmail and xp_startmail.
it stopped quickly, but when I ran xp_startmail, it
appeared to hang. I killed the process, now it's saying
that it's "Killed/Rollback". It's been like that for a
while now. Does anyone know a way to get rid of this?
Can this cause other headaches?Rob,
Are you using Microsoft Exchange? Is the Exchange Server available? This
can happen when Exchange disappears, or you lose connectivity to it.
--
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Rob wrote:
> Our SQLMail stopped working, so I tried to stop and
> restart the SQLMail using xp_stopmail and xp_startmail.
> it stopped quickly, but when I ran xp_startmail, it
> appeared to hang. I killed the process, now it's saying
> that it's "Killed/Rollback". It's been like that for a
> while now. Does anyone know a way to get rid of this?
> Can this cause other headaches?|||> This can happen when Exchange disappears
I'd question David Copperfield. ;-)
Oh, I can't wait for a more robust and independent mail platform in SQL
Server...
--
http://www.aspfaq.com/
(Reverse address to reply.)|||I already tried that - that was also my first thought that is was because is
was doing it under wrong uder name, but that's not the case. I', logged in
to the server as the user that runs the SQLServer Agent service, and I can
open Outlook and get into the mailbox without any problems.
Regards
Steen
"Aaron [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> skrev i en meddelelse
news:OtVlLiCZEHA.2500@.TK2MSFTNGP09.phx.gbl...
> > This can happen when Exchange disappears
> I'd question David Copperfield. ;-)
> Oh, I can't wait for a more robust and independent mail platform in SQL
> Server...
> --
> http://www.aspfaq.com/
> (Reverse address to reply.)
>|||Steen,
Can you send mail from Outlook, logged on as the SQLAgent account?
--
Mark Allison, SQL Server MVP
http://www.markallison.co.uk
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Steen Persson wrote:
> I already tried that - that was also my first thought that is was because is
> was doing it under wrong uder name, but that's not the case. I', logged in
> to the server as the user that runs the SQLServer Agent service, and I can
> open Outlook and get into the mailbox without any problems.
> Regards
> Steen
>
> "Aaron [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> skrev i en meddelelse
> news:OtVlLiCZEHA.2500@.TK2MSFTNGP09.phx.gbl...
>>This can happen when Exchange disappears
>>I'd question David Copperfield. ;-)
>>Oh, I can't wait for a more robust and independent mail platform in SQL
>>Server...
>>--
>>http://www.aspfaq.com/
>>(Reverse address to reply.)
>>
>
>|||...it seems like my previous reply to my problem has ended up in a wrong
thread - sorry 'bout that.
I have verified that I can send emails from Outlook. Everything seems to be
fine - I log on as the user that runs the SQL agent which is the same as the
user of the mailbox. The strange thing is that it worked fine the other day
when I installed Outlook on a few SQL servers, but now it fails with the
same error message on all of them. I'm wondering if there's something stupid
that I'm missing when I fire the xp_sendmail command.
The command I'm trying with just for the test is:
Use Master
EXEC xp_sendmail 'spe@.MyDomainName.dk', ' Test'
Shoudn't this be enough just to send an email or am I missing something?
Regards
Steen
"Mark Allison" <marka@.no.tinned.meat.mvps.org> skrev i en meddelelse
news:eFy9YYDZEHA.996@.TK2MSFTNGP12.phx.gbl...
> Steen,
> Can you send mail from Outlook, logged on as the SQLAgent account?
> --
> Mark Allison, SQL Server MVP
> http://www.markallison.co.uk
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
>
> Steen Persson wrote:
> > I already tried that - that was also my first thought that is was
because is
> > was doing it under wrong uder name, but that's not the case. I', logged
in
> > to the server as the user that runs the SQLServer Agent service, and I
can
> > open Outlook and get into the mailbox without any problems.
> >
> > Regards
> > Steen
> >
> >
> > "Aaron [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> skrev i en meddelelse
> > news:OtVlLiCZEHA.2500@.TK2MSFTNGP09.phx.gbl...
> >
> >>This can happen when Exchange disappears
> >>
> >>I'd question David Copperfield. ;-)
> >>
> >>Oh, I can't wait for a more robust and independent mail platform in SQL
> >>Server...
> >>
> >>--
> >>http://www.aspfaq.com/
> >>(Reverse address to reply.)
> >>
> >>
> >
> >
> >
Monday, March 26, 2012
kill unnecessary connections
i just ran the sp_who sp and heres the results i got...now how can i know unwanted connections form this list..
10background sa0 NULLLAZY WRITER
20sleeping sa0 NULLLOG WRITER
30background sa0 masterSIGNAL HANDLER
40background sa0 NULLLOCK MONITOR
50background sa0 masterTASK MANAGER
60background sa0 masterTASK MANAGER
70sleeping sa0 NULLCHECKPOINT SLEEP
80background sa0 masterTASK MANAGER
90background sa0 masterTASK MANAGER
100background sa0 masterTASK MANAGER
110background sa0 masterTASK MANAGER
120background sa0 masterTASK MANAGER
130background sa0 masterTASK MANAGER
510sleeping NT AUTHORITY\SYSTEM 0 ReportServerAWAITING COMMAND
520runnable CENTCOM\Dinakar 0 BBMiniSELECT
550sleeping CENTCOM\ASPNET 0 BBMiniAWAITING COMMAND
560sleeping CENTCOM\ASPNET 0 BBMiniAWAITING COMMAND
thanksDon't know what you mean by "unwanted connections", but this script will kill all users:
CREATE PROCEDURE usp_KillUsers @.dbname varchar(50) as
SET NOCOUNT ON
DECLARE @.strSQL varchar(255)
PRINT 'Killing Users'
PRINT '------'
CREATE table #tmpUsers(
spid int,
eid int,
status varchar(30),
loginname varchar(50),
hostname varchar(50),
blk int,
dbname varchar(50),
cmd varchar(30))
INSERT INTO #tmpUsers EXEC SP_WHO
DECLARE LoginCursor CURSOR
READ_ONLY
FOR SELECT spid, dbname FROM #tmpUsers WHERE dbname = @.dbname
DECLARE @.spid varchar(10)
DECLARE @.dbname2 varchar(40)
OPEN LoginCursor
FETCH NEXT FROM LoginCursor INTO @.spid, @.dbname2
WHILE (@.@.fetch_status <> -1)
BEGIN
IF (@.@.fetch_status <> -2)
BEGIN
PRINT 'Killing ' + @.spid
SET @.strSQL = 'KILL ' + @.spid
EXEC (@.strSQL)
END
FETCH NEXT FROM LoginCursor INTO @.spid, @.dbname2
END
CLOSE LoginCursor
DEALLOCATE LoginCursor
DROP table #tmpUsers
go|||no i dont want to kill all the connections...from the list above i'd like to know how many connections are genuine ones how many are system connections and how many are user created (by asp.net etc) ...is it ok to kill the connections with loginname ="sa".. since there are too many connections with that name...
thanks|||there seem to be a lot of connections to the master db...and am not using the db at all...so can i kill all those connections...how did they get activated in the first place...or is this normal..anyone has any idea...
thanks
Monday, March 12, 2012
Key not valid for use in specified state?
I just ran into the same old problem that I got a few months back.
Reporting Server stops working and logs the message "Key not valid for use
in specified state".
I did never manage to solve the problem when it occured before but at that
time it happened on a development server, this time it is worse as it is
on one of our production servers.
I know that there was several people suffering from the same problem after
applying .Net Framework 1.1 SP1.
Did anyone find a solution?
Best regards,
Per SalmiHello Per,
Based on my research, I recommend you perform the following steps to
resolve the issue:
Step 1: Deleting the files which represent Microsoft SQL Server Reporting
Services Key Container
===============================================================
Search for files with the pattern "1aedd7b5699f3d6a88e354100b596aae_*".
These files represent the Microsoft SQL Server Reporting Services Key
Container.
Backup these files first. Then delete the original files.
You may find the file in the folder "\documents and settings\<machine
name>\aspnet\application data\microsoft\crypto\rsa\<user
sid>\1aedd7b5699f3d6a88e354100b596aae_*".
Try to start Reporting Server.
If you receive "The report server cannot decrypt the symmetric key used to
access sensitive or encrypted data in a report server database. You must
either restore a backup key or delete all encrypted content and then
restart the service. Check the documentation", please continue with the
following steps:
Step 2: Back up Reportserver and ReportserverTempDB databases
===========================================
Step 3: Reapplying the symmetric keys
==================================
1. Run Rskeymgmt -e to extract the keys
2. Run Rskeymgmt -d to delete the keys
3. Run rskeymgmt -a to reapply the keys and restart the windows service.
4. Run Rsactivate -c to activate the service
For detailed information about the RsKeyMgmt utility, please access the
following web site:
http://www.msdn.microsoft.com/library/default.asp?url=/library/en-us/rsuiref
/htm/cpu_rsconfig_v1_29ly.asp
I hope above information is helpful.
Sophie Guo
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
=====================================================When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================This posting is provided "AS IS" with no warranties, and confers no rights.