Exit to xm console in xen?

Is there a way so that I can write the output of the xm console to some file?

Can I install something in a domain configuration file that automatically does this for me when I issue xm create?

I tried:

xm console | tee domU-console.log 

... but that doesn't suit me. I want to log output in the background asynchronously.

+4
source share
2 answers

If this works, you should be able to:

 nohup xm console | tee domU-console.log & 

I don't know if xm console uses stderr at all, but if you want to be sure that snag tht output too:

 nohup xm console 2>&1 tee domU-console.log & 

Drop tee if you plan to log out.

0
source

You can try xenconsoled as

xenconsoled --log = guest --log-dir = / var / log / xen / guest /

And Redhat will also save the output of the guest console to / var / log / xen / console if you set / etc / sysconfig / xend with XENCONSOLED_LOG_GUESTS = yes.

+3
source

All Articles