just what does kserel mean?

2006-09-11 Thread Nestor Wheelock
I have searched all over the net for a good definition of what the top 
state, kserel means.  When I run mysql this is the state in which it 
runs.


  PID USERNAME  THR PRI NICE   SIZERES STATE  C   TIME   WCPU COMMAND
 2117 mysql  17  200   323M 59080K kserel 0   0:02  0.00% mysqld


I'm a newbie with freebsd and am concerned that this might be some sort of 
problem since my installation of Mysql turned out to be rather 
challenging.


Thanks,
Nestor
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: just what does kserel mean?

2006-09-11 Thread Dan Nelson
In the last episode (Sep 11), Nestor Wheelock said:
 I have searched all over the net for a good definition of what the top 
 state, kserel means.  When I run mysql this is the state in which it 
 runs.
 
   PID USERNAME  THR PRI NICE   SIZERES STATE  C   TIME   WCPU COMMAND
  2117 mysql  17  200   323M 59080K kserel 0   0:02  0.00% mysqld

That's just a wait state used inside libkse threads meaning a thread is
waiting for something to do.  Note that for a threaded program, the
STATE seen by top is that of only one thread owned by the process. 
Press 'H' to see each thread on its own line.

-- 
Dan Nelson
[EMAIL PROTECTED]
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: just what does kserel mean?

2006-09-11 Thread Chuck Swiger

On Sep 11, 2006, at 3:14 PM, Nestor Wheelock wrote:
I have searched all over the net for a good definition of what the  
top state, kserel means.  When I run mysql this is the state in  
which it runs.


  PID USERNAME  THR PRI NICE   SIZERES STATE  C   TIME   WCPU  
COMMAND
 2117 mysql  17  200   323M 59080K kserel 0   0:02  0.00%  
mysqld


I'm a newbie with freebsd and am concerned that this might be some  
sort of problem since my installation of Mysql turned out to be  
rather challenging.


This state is set in the kse_release() call in sys/kern/kern_kse.c,  
and appears to mean that the process is waiting to be woken up by a  
signal or is otherwise blocked waiting for more work; this is handled  
by returning control to userspace via an upcall.


See man kse_release:

 In other words, as soon as there is a scheduling decision to be  
made, the
 KSE becomes unassigned, because the kernel does not presume to  
know how
 the process' other runnable threads should be scheduled.   
Unassigned KSEs
 always return to user space as soon as possible via the upcall  
mechanism
 (described below), allowing the user process to decide how that  
KSE
 should be utilized next.  KSEs always complete as much work as  
possible

 in the kernel before becoming unassigned.

[ ... ]

 The kse_release() system call is used to ``park'' the KSE  
assigned to the
 currently running thread when it is not needed, e.g., when  
there are more
 available KSEs than runnable user threads.  The thread converts  
to an
 upcall but does not get scheduled until there is a new reason  
to do so,

 e.g., a previously blocked thread becomes runnable, or the timeout
 expires.  If successful, kse_release() does not return to the  
caller.


--
-Chuck

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: just what does kserel mean?

2006-09-11 Thread Eric Schuele

On 09/11/06 17:14, Nestor Wheelock wrote:
I have searched all over the net for a good definition of what the top 
state, kserel means.  When I run mysql this is the state in which it 


I don't mean to be stating the obvious... but as a newbie you might not 
know that KSE == Kernel Schedulable Entity


You can do all sorts of googling on freebsd KSE and as Chuck mentioned 
browse sys/kern/kern_kse.c


HTH.


runs.

  PID USERNAME  THR PRI NICE   SIZERES STATE  C   TIME   WCPU COMMAND
 2117 mysql  17  200   323M 59080K kserel 0   0:02  0.00% mysqld


I'm a newbie with freebsd and am concerned that this might be some sort 
of problem since my installation of Mysql turned out to be rather 
challenging.


Thanks,
Nestor
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
[EMAIL PROTECTED]





--
Regards,
Eric
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]