aboutsummaryrefslogtreecommitdiff
path: root/kvmx-create
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2017-12-30 16:15:14 -0200
committerSilvio Rhatto <rhatto@riseup.net>2017-12-30 16:15:14 -0200
commit4882bc0e6d31e804e4456656c629806eb59eca0a (patch)
treebbcc7e14c68fb76062265c20c6c371c6ea6460cc /kvmx-create
parentcf9577525e94ff7972edf2b03979b41abdedb95b (diff)
downloadkvmx-4882bc0e6d31e804e4456656c629806eb59eca0a.tar.gz
kvmx-4882bc0e6d31e804e4456656c629806eb59eca0a.tar.bz2
Serial console support thanks to kvm-manager
Diffstat (limited to 'kvmx-create')
-rwxr-xr-xkvmx-create8
1 files changed, 8 insertions, 0 deletions
diff --git a/kvmx-create b/kvmx-create
index 8b30e83..cdf3278 100755
--- a/kvmx-create
+++ b/kvmx-create
@@ -286,6 +286,14 @@ function kvmx_create_custom {
if [ "$bootloader" == "grub" ]; then
$APT_INSTALL grub-pc
+
+ # Serial console support
+ echo '' >> $WORK/etc/default/grub
+ echo '# Custom configuration' >> $WORK/etc/default/grub
+ echo 'GRUB_TERMINAL=serial' >> $WORK/etc/default/grub
+ echo 'GRUB_SERIAL_COMMAND="serial --speed=115200"' >> $WORK/etc/default/grub
+ echo 'GRUB_CMDLINE_LINUX="console=ttyS0,115200n8"' >> $WORK/etc/default/grub
+
kvmx_sudo_run chroot $WORK/ update-grub
kvmx_sudo_run chroot $WORK/ grub-install $device
# Possible alternatives: