SQL shutdown

How can i tell if sql shutdown last night.....i cannot remember the command of up time of sql
LVL 7
TRACEYMARYAsked:
Who is Participating?
 
Guy Hengel [angelIII / a3]Connect With a Mentor Billing EngineerCommented:
check out the ERRORLOG file, in the beginning it shows you when it started
0
 
TRACEYMARYAuthor Commented:
im on sql server logs i could not see anything in there.....i thought there was a command in query i could run..

Im getting all kinds of commands in sp_who2 like
sp_sqlagent_get_perf_counter
set noexec off set parse only off
set transaction isolation level read committed ....never seen these before
0
 
TRACEYMARYAuthor Commented:
checkpoint is 1783110 cpu
0
Cloud Class® Course: Microsoft Office 2010

This course will introduce you to the interfaces and features of Microsoft Office 2010 Word, Excel, PowerPoint, Outlook, and Access. You will learn about the features that are shared between all products in the Office suite, as well as the new features that are product specific.

 
Aneesh RetnakaranConnect With a Mentor Database AdministratorCommented:
SELECT crdate from master..sysdatabases where name ='tempdb'
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
In the Enterprise manager -> management -> SQL Server logs.
the log named "Current - <datetime>" has the <datetime> of when the server last started.

not sure if there is a short command that shows this info
0
 
Aneesh RetnakaranDatabase AdministratorCommented:
remember ' tempdb' database will be re-created every time SQL Server starts.
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
interesting query, aneesh.
here some other:
select min(login_time) from master.dbo.sysprocesses
0
 
TRACEYMARYAuthor Commented:
so looks like did not shutdown then 2006-03-15 17:53:37.277
current log shows   current 07/06/2006 ...
0
 
Aneesh RetnakaranDatabase AdministratorCommented:
Yes Angel, I think we  are almost there .. right ?
0
 
TRACEYMARYAuthor Commented:
2006-03-15 17:54:14.770 for the cdate on temp
0
 
Aneesh RetnakaranDatabase AdministratorCommented:
So, your server was restarted on 2006-03-15 17:54
0
 
Eugene ZCommented:
you can find the info  in the server event viewer (Application Log)
Example:
search for:
================================
Event Type:      Information
Event Source:      MSSQLSERVER
Event Category:      (2)
Event ID:      17055
Date:            7/6/2006
Time:            2:08:18 PM
User:            N/A
Computer:      yourserver
Description:
17148 :
SQL Server is terminating due to 'stop' request from Service Control Manager.
 
Data:
0
 
TRACEYMARYAuthor Commented:
yeah ....network guy was looking at events on the server and said i think it shutdown so i wanted to check
but i have all the other things above going on ..
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
>current log shows   current 07/06/2006 ...
Actually, that information is indeed not accurate, as by
DBCC ERRORLOG

the errorlog gets rolled (to avoid it grows too big)

the queries shown by aneeshattingal and me will be accurate, the difference of +- 1 second is the time needed to create the tempdb
0
 
TRACEYMARYAuthor Commented:
That makes sense the tempdb gets created and the date...so i no know that it did not shutdown..
0
 
TRACEYMARYAuthor Commented:
Does the checkpoint of 1784700
seem high
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
>Does the checkpoint of 1784700
no, looks fine
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.