Sponsored Content
Top Forums UNIX for Advanced & Expert Users how to display pid and other parameters of current process through kernel module ? Post 302515196 by Corona688 on Tuesday 19th of April 2011 11:04:35 AM
Old 04-19-2011
The concept of "current process" doesn't exist inside the kernel. What you're asking doesn't make a ton of sense.
 

10 More Discussions You Might Find Interesting

1. HP-UX

Display Kernel Parameters

Good Day Please couls somebody tell me how to display Configurable Kernel parameters from the command line. I am able to do it from SAM,but would like to dump the command line output to a text file so I can email it off to HP. Kind Regards Shawn (1 Reply)
Discussion started by: shawnbishop
1 Replies

2. SuSE

max number of slabs per kernel module (kernel 2.6.17, suse)

Hi All, Is there a max number of slabs that can be used per kernel module? I'm having a tough time finding out that kind of information, but the array 'node_zonelists' (mmzone.h) has a size of 5. I just want to avoid buffer overruns and other bad stuff. Cheers, Brendan (4 Replies)
Discussion started by: Brendan Kennedy
4 Replies

3. UNIX for Dummies Questions & Answers

Comparing CRON PID w/Current PPID

All, I've got a script that needs to check if it was started by cron. The code seems to be right, but it's not running correctly if cron starts it. Am I getting the pid's correctly? I'm not having any luck figuring it out. :confused: Any help is appreciated! CRON_ID=$(ps -aef | grep... (1 Reply)
Discussion started by: GregWold
1 Replies

4. UNIX for Dummies Questions & Answers

Need to get pid of a process and have to store the pid in a variable

Hi, I need to get the pid of a process and have to store the pid in a variable and i want to use this value(pid) of the variable for some process. Please can anyone tell me how to get the pid of a process and store it in a variable. please help me on this. Thanks in advance, Amudha (7 Replies)
Discussion started by: samudha
7 Replies

5. UNIX for Dummies Questions & Answers

Linux kernel module parameters

Hi, Does anyone know if it is possible to know the current value of a kernel module parameters after the module is loaded. Are the values of the parameters advertised at some /proc or /sys location ? The only thing I know is modinfo, that actually looks a the module .ko and gives a... (3 Replies)
Discussion started by: macL
3 Replies

6. Linux

How to convert Linux Kernel built-in module into a loadable module

Hi all, I am working on USB data monitoring on Fedora Core 9. Kernel 2.6.25 has a built-in module (the one that isn't loadable, but compiles and links statically with the kernel during compilation) to snoop USB data. It is in <kernel_source_code>/drivers/usb/mon/. I need to know if I can... (0 Replies)
Discussion started by: anitemp
0 Replies

7. Solaris

Which file is read by kernel to set its default system kernel parameters values?

Hi gurus Could anybody tell me which file is read by kernel to set its default system kernal parameters values in solaris. Here I am not taking about /etc/system file which is used to load kernal modules or to change any default system kernal parameter value Is it /dev/kmem file or something... (1 Reply)
Discussion started by: girish.batra
1 Replies

8. Linux

kernel module parameters

Hi, if I install a module with specific parameter, will this parameters applied next time system boots? for exampe, I want to disable InterruptThrottleRate modprobe e1000e InterruptThrottleRate=0 Is this parameter apllied only for this run, or this module will always use this parameter when... (2 Replies)
Discussion started by: Shedon
2 Replies

9. Linux

Unload kernel module at boot time (Debian Wheezy 7.2, 3.2.0-4-686-pae kernel)

Hi everyone, I am trying to prevent the ehci_hcd kernel module to load at boot time. Here's what I've tried so far: 1) Add the following line to /etc/modprobe.d/blacklist.conf (as suggested here): 2) Blacklisted the module by adding the following string to 3) Tried to blacklist the module... (0 Replies)
Discussion started by: gacanepa
0 Replies

10. Shell Programming and Scripting

Display current directory for a running process for script

I'm trying to create a ksh script to do the following: 1) Ask the user what process they want to search for. 2) Have the script read the input as a variable and use it to search for the process. 3) Display the current time & date, the working directory of the process, and finally display the... (6 Replies)
Discussion started by: seekryts15
6 Replies
SCHED_SETPARAM(2)					     Linux Programmer's Manual						 SCHED_SETPARAM(2)

NAME
sched_setparam, sched_getparam - set and get scheduling parameters SYNOPSIS
#include <sched.h> int sched_setparam(pid_t pid, const struct sched_param *param); int sched_getparam(pid_t pid, struct sched_param *param); struct sched_param { ... int sched_priority; ... }; DESCRIPTION
sched_setparam() sets the scheduling parameters associated with the scheduling policy for the process identified by pid. If pid is zero, then the parameters of the calling process are set. The interpretation of the argument param depends on the scheduling policy of the process identified by pid. See sched_setscheduler(2) for a description of the scheduling policies supported under Linux. sched_getparam() retrieves the scheduling parameters for the process identified by pid. If pid is zero, then the parameters of the calling process are retrieved. sched_setparam() checks the validity of param for the scheduling policy of the process. The value param->sched_priority must lie within the range given by sched_get_priority_min(2) and sched_get_priority_max(2). For a discussion of the privileges and resource limits related to scheduling priority and policy, see sched_setscheduler(2). POSIX systems on which sched_setparam() and sched_getparam() are available define _POSIX_PRIORITY_SCHEDULING in <unistd.h>. RETURN VALUE
On success, sched_setparam() and sched_getparam() return 0. On error, -1 is returned, and errno is set appropriately. ERRORS
EINVAL The argument param does not make sense for the current scheduling policy. EPERM The calling process does not have appropriate privileges (Linux: does not have the CAP_SYS_NICE capability). ESRCH The process whose ID is pid could not be found. CONFORMING TO
POSIX.1-2001. SEE ALSO
getpriority(2), nice(2), sched_get_priority_max(2), sched_get_priority_min(2), sched_getaffinity(2), sched_getscheduler(2), sched_setaffinity(2), sched_setscheduler(2), setpriority(2), capabilities(7) Programming for the real world - POSIX.4 by Bill O. Gallmeister, O'Reilly & Associates, Inc., ISBN 1-56592-074-0. COLOPHON
This page is part of release 3.44 of the Linux man-pages project. A description of the project, and information about reporting bugs, can be found at http://www.kernel.org/doc/man-pages/. Linux 2006-03-23 SCHED_SETPARAM(2)
All times are GMT -4. The time now is 10:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy