1virt-log(1)                 Virtualization Support                 virt-log(1)
2
3
4

NAME

6       virt-log - Display log files from a virtual machine
7

SYNOPSIS

9        virt-log [--options] -d domname
10
11        virt-log [--options] -a disk.img [-a disk.img ...]
12

DESCRIPTION

14       "virt-log" is a command line tool to display the log files from the
15       named virtual machine (or disk image).
16
17       This tool understands and displays both plain text log files (eg.
18       /var/log/messages) and binary formats such as the systemd journal.
19
20       To display other types of files, use virt-cat(1).  To follow (tail)
21       text log files, use virt-tail(1).  To copy files out of a virtual
22       machine, use virt-copy-out(1).  To display the contents of the Windows
23       Registry, use virt-win-reg(1).
24

EXAMPLES

26       Display the complete logs from a guest:
27
28        virt-log -d mydomain | less
29
30       Find out what DHCP IP address a VM acquired:
31
32        virt-log -d mydomain | grep 'dhclient.*bound to'
33

OPTIONS

35       --help
36           Display brief help.
37
38       -a file
39       --add file
40           Add file which should be a disk image from a virtual machine.  If
41           the virtual machine has multiple block devices, you must supply all
42           of them with separate -a options.
43
44           The format of the disk image is auto-detected.  To override this
45           and force a particular format use the --format=.. option.
46
47       -a URI
48       --add URI
49           Add a remote disk.  See "ADDING REMOTE STORAGE" in guestfish(1).
50
51       -c URI
52       --connect URI
53           If using libvirt, connect to the given URI.  If omitted, then we
54           connect to the default libvirt hypervisor.
55
56           If you specify guest block devices directly (-a), then libvirt is
57           not used at all.
58
59       -d guest
60       --domain guest
61           Add all the disks from the named libvirt guest.  Domain UUIDs can
62           be used instead of names.
63
64       --echo-keys
65           When prompting for keys and passphrases, virt-log normally turns
66           echoing off so you cannot see what you are typing.  If you are not
67           worried about Tempest attacks and there is no one else in the room
68           you can specify this flag to see what you are typing.
69
70       --format=raw|qcow2|..
71       --format
72           The default for the -a option is to auto-detect the format of the
73           disk image.  Using this forces the disk format for -a options which
74           follow on the command line.  Using --format with no argument
75           switches back to auto-detection for subsequent -a options.
76
77           For example:
78
79            virt-log --format=raw -a disk.img
80
81           forces raw format (no auto-detection) for disk.img.
82
83            virt-log --format=raw -a disk.img --format -a another.img
84
85           forces raw format (no auto-detection) for disk.img and reverts to
86           auto-detection for another.img.
87
88           If you have untrusted raw-format guest disk images, you should use
89           this option to specify the disk format.  This avoids a possible
90           security problem with malicious guests (CVE-2010-3851).
91
92       --key SELECTOR
93           Specify a key for LUKS, to automatically open a LUKS device when
94           using the inspection.  "SELECTOR" can be in one of the following
95           formats:
96
97           --key "DEVICE":key:KEY_STRING
98               Use the specified "KEY_STRING" as passphrase.
99
100           --key "DEVICE":file:FILENAME
101               Read the passphrase from FILENAME.
102
103       --keys-from-stdin
104           Read key or passphrase parameters from stdin.  The default is to
105           try to read passphrases from the user by opening /dev/tty.
106
107       -v
108       --verbose
109           Enable verbose messages for debugging.
110
111       -V
112       --version
113           Display version number and exit.
114
115       -x  Enable tracing of libguestfs API calls.
116

EXIT STATUS

118       This program returns 0 if successful, or non-zero if there was an
119       error.
120

SEE ALSO

122       guestfs(3), guestfish(1), virt-cat(1), virt-copy-out(1), virt-tail(1),
123       virt-tar-out(1), virt-win-reg(1), http://libguestfs.org/.
124

AUTHOR

126       Richard W.M. Jones http://people.redhat.com/~rjones/
127
129       Copyright (C) 2010-2019 Red Hat Inc.
130

LICENSE

132       This program is free software; you can redistribute it and/or modify it
133       under the terms of the GNU General Public License as published by the
134       Free Software Foundation; either version 2 of the License, or (at your
135       option) any later version.
136
137       This program is distributed in the hope that it will be useful, but
138       WITHOUT ANY WARRANTY; without even the implied warranty of
139       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
140       General Public License for more details.
141
142       You should have received a copy of the GNU General Public License along
143       with this program; if not, write to the Free Software Foundation, Inc.,
144       51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
145

BUGS

147       To get a list of bugs against libguestfs, use this link:
148       https://bugzilla.redhat.com/buglist.cgi?component=libguestfs&product=Virtualization+Tools
149
150       To report a new bug against libguestfs, use this link:
151       https://bugzilla.redhat.com/enter_bug.cgi?component=libguestfs&product=Virtualization+Tools
152
153       When reporting a bug, please supply:
154
155       ·   The version of libguestfs.
156
157       ·   Where you got libguestfs (eg. which Linux distro, compiled from
158           source, etc)
159
160       ·   Describe the bug accurately and give a way to reproduce it.
161
162       ·   Run libguestfs-test-tool(1) and paste the complete, unedited output
163           into the bug report.
164
165
166
167libguestfs-1.40.2                 2019-02-07                       virt-log(1)
Impressum