|
|
|
|
|
|
|
|
|
|
xen-users
[Xen-users] Programatically checking if we're in a domU or dom0
Lutrin Jean wrote:
> - what would be a simple way from a shell script
> to detect wether we're inside a domU or a dom0?
The mere existence of /proc/xen is enough to infer that you're in a
paravirtualized Xen domain (as opposed to running under a regular Linux
kernel, for example).
Personally, I use the following command in a startup script to check if
we're in a privileged domain:
grep -qsE '^control_d$' /proc/xen/capabilities
Cheers
Andrew
signature.asc
Description: OpenPGP digital signature
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
|
|
|
|
|