mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-04-30 12:44:39 +00:00
virtcontainers: clh: Turn-off serial and virtio-console by default
We will need to have console output from the guest only for debugging purposes. As a result, we can turn-off both the serial and virtio-console devices by default for better boot time. Fixes: #2820 Signed-off-by: Bo Chen <chen.bo@intel.com>
This commit is contained in:
parent
88affdb7b7
commit
3e24e46c70
@ -285,11 +285,12 @@ func (clh *cloudHypervisor) createSandbox(ctx context.Context, id string, networ
|
|||||||
clh.vmconfig.Pmem = &[]chclient.PmemConfig{*pmem}
|
clh.vmconfig.Pmem = &[]chclient.PmemConfig{*pmem}
|
||||||
}
|
}
|
||||||
|
|
||||||
// set the serial console to the cloud hypervisor
|
// Use serial port as the guest console only in debug mode,
|
||||||
|
// so that we can gather early OS booting log
|
||||||
if clh.config.Debug {
|
if clh.config.Debug {
|
||||||
clh.vmconfig.Serial = chclient.NewConsoleConfig(cctTTY)
|
clh.vmconfig.Serial = chclient.NewConsoleConfig(cctTTY)
|
||||||
} else {
|
} else {
|
||||||
clh.vmconfig.Serial = chclient.NewConsoleConfig(cctNULL)
|
clh.vmconfig.Serial = chclient.NewConsoleConfig(cctOFF)
|
||||||
}
|
}
|
||||||
|
|
||||||
clh.vmconfig.Console = chclient.NewConsoleConfig(cctOFF)
|
clh.vmconfig.Console = chclient.NewConsoleConfig(cctOFF)
|
||||||
@ -989,7 +990,6 @@ func (clh *cloudHypervisor) launchClh() (int, error) {
|
|||||||
|
|
||||||
const (
|
const (
|
||||||
cctOFF string = "Off"
|
cctOFF string = "Off"
|
||||||
cctNULL string = "Null"
|
|
||||||
cctTTY string = "Tty"
|
cctTTY string = "Tty"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user