How to find How much RAM/CPU is used by a jail

fahadshery

Contributor
Joined
Sep 29, 2017
Messages
179
Hi,

I have MySQL running in jail. I want to know how much RAM/CPU is used by it?
Is there an easier way to do that?

Cheers
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
Code:
iocage console <jailname>
top
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
This is symmetric multiprocessing, all jails running on the same kernel. The processes will get as much memory as they ask for.
You can limit the maximum amount a jail will use, check the iocage documentation for that.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,700
Also you can do on the host:
top

Then press j to display the JID column, which corresponds to the number allocated to the jail which you can find with the jls command. Good for working out which jail is taking the CPU if you're not sure.
 
Top