LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices

Reply
 
Search this Thread
Old 11-18-2009, 06:01 PM   #1
jumanix
LQ Newbie
 
Registered: Nov 2009
Posts: 8

Rep: Reputation: 0
Post How can the kernel notify which is the current running application ?


Hi,
i need to develop a daemon (user space) which needs to know which is current running application. How can i get notifications from the kernel?
Someone told me there are a thousand ways.
Who can suggest me a bunch of possibly solutions?

Thanks
 
Old 11-18-2009, 06:46 PM   #2
jtshaw
Senior Member
 
Registered: Nov 2000
Location: Seattle, WA USA
Distribution: Ubuntu @ Home, RHEL @ Work
Posts: 3,892
Blog Entries: 1

Rep: Reputation: 66
This stuff is available in /proc/<PID>/stat

You can also see what is in the running state using ps (ps aux for example).
 
Old 11-18-2009, 07:11 PM   #3
salasi
Senior Member
 
Registered: Jul 2007
Location: Directly above centre of the earth, UK
Distribution: SuSE, plus some hopping
Posts: 3,916

Rep: Reputation: 777Reputation: 777Reputation: 777Reputation: 777Reputation: 777Reputation: 777Reputation: 777
Quote:
Originally Posted by jumanix View Post
Hi,
i need to develop a daemon (user space) which needs to know which is current running application.
Your daemon will check which is the running application; when it does this, it will be running, so it will be the running application, no?
 
Old 11-19-2009, 05:52 AM   #4
jumanix
LQ Newbie
 
Registered: Nov 2009
Posts: 8

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by salasi View Post
Your daemon will check which is the running application; when it does this, it will be running, so it will be the running application, no?
Yeah, but i don't want to check it.
I want the kernel notify me everytime the current running one changes. Is it possible?
 
Old 11-22-2009, 02:25 PM   #5
sundialsvcs
Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 5,425

Rep: Reputation: 1159Reputation: 1159Reputation: 1159Reputation: 1159Reputation: 1159Reputation: 1159Reputation: 1159Reputation: 1159Reputation: 1159
Realistically, no. The computer would simply be spending all of its time sendng you notifications. (An you'd spend all of the computer's time processing them.)
 
  


Reply

Tags
application, current, kernel, running


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Is anyone running EvE online under a current kernel in any distro? linuxpokernut Linux - Games 2 08-04-2009 07:18 PM
notify user space application from the kernel space lordofring Linux - Software 2 06-22-2009 01:32 PM
Application to notify clients of systems maintenance? jeenam Linux - Enterprise 3 06-10-2009 04:45 PM
Running application in kernel mode as device driver! hank007 Linux - Newbie 1 05-29-2009 08:21 AM
cant enable i notify kernel daedalus12 Linux - General 2 03-29-2005 06:49 AM


All times are GMT -5. The time now is 06:16 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration