Memory: % processor time using T-SQL?

Hello,

 I am trying to get info about a performance counter, % Processor Time using T-sql.

I am in my local SQL server which is connected to a few different remote severs. Each window server has a sql server installed.
The linked servers are already created and working fine.

Is there any way to retrieve this information from my local server? any dmv?
I know that I can get some information from sys.dm_os_sys_memory, but what I need is Memory: % processor time

Thanks!
IzzyTwinklyAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

DcpKingCommented:
You say that you can connect to each of the other SQL Servers, and that you can obtain the information that you seek using a T-SQL query.

Therefore you should be able to create an SSIS job that connects to each of the other servers and queries that server for the data required. You can pull the data into a variable (a string, for example, or an object), and then in the next SSIS task write it into a table before moving to the next server ...

hth

Mike
IzzyTwinklyAuthor Commented:
Hi Mike,

yes, I can get all other information using tsql and save those to my local table.
The information I need is % Processor time.
I don't know how to get this information. Just wondering if there is any dmv or system stored procedure shows this information. Or even formula to get % Processor time would be fine. I just need to get it using tsql without opening performance monitor etc.
DcpKingCommented:
Try searching the definitions of sys.dm_os_ring_buffers and sys.dm_exec_query_stats and look at s-carpal-tunnel's answer here. I'm afraid I haven't ever had to automate the % cpu usage ever!

hth

Mike

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Bob LearnedCommented:
I have only ever used Performance Monitor, as described here:

How to find out how much CPU a SQL Server process is really using
http://www.mssqltips.com/sqlservertip/2454/how-to-find-out-how-much-cpu-a-sql-server-process-is-really-using/

I would be interested to learn of a different way...
Vitor MontalvãoMSSQL Senior EngineerCommented:
IzzyTwinkly, do you still need help on this question?
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server

From novice to tech pro — start learning today.