ALT Linux Distributions development
 help / color / mirror / Atom feed
From: "Антон Мидюков" <midyukov-anton@ya.ru>
To: devel-distro@lists.altlinux.org
Subject: Re: [devel-distro] Q: virt-install vs vm/builder qcow2
Date: Fri, 3 Dec 2021 21:21:56 +0700
Message-ID: <45ac498a-58c3-1ee2-c421-b9067fe23ebb@ya.ru> (raw)
In-Reply-To: <YaoWiIgypueZrJXm@lks.home>

03.12.2021 20:07, Konstantin Lepikhov пишет:
> Hi Konstantin!
> 
> On 12/03/2021, at 12:04:05 PM you wrote:
> 
> <skip>
>> (тут должна появиться текстовая консоль grub но ничего не происходит и
>> висит)
> Сам нашел, сам и исправил )
> 
> diff --git a/conf.d/vm.mk b/conf.d/vm.mk
> index 82c991e7..ef774f22 100644
> --- a/conf.d/vm.mk
> +++ b/conf.d/vm.mk
> @@ -24,12 +24,13 @@ vm/systemd-net: vm/systemd use/net-eth/networkd-dhcp use/net-ssh \
>  # vm/net or vm/systemd-net
>  vm/cloud-systemd: vm/systemd-net mixin/cloud-init use/vmguest/kvm use/tty/S0 \
>  	use/net/networkd/resolved
> +	@$(call set,KFLAVOURS,centos)
>  	@$(call add,THE_KMODULES,drm)
>  	@$(call add,VM_INITRDMODULES,sr_mod)
>  	@$(call add,BASE_PACKAGES,update-kernel)
>  	@$(call add,BASE_PACKAGES,apt-scripts)
>  	@$(call add,BASE_PACKAGES,systemd-settings-disable-kill-user-processes)
> -	@$(call add,DEFAULT_SERVICES_ENABLE,getty@tty1 getty@ttyS0)
> +	@$(call add,DEFAULT_SERVICES_ENABLE,getty@tty0 getty@ttyS0)
>  	@$(call add,DEFAULT_SERVICES_DISABLE,consolesaver)
>  
>  vm/cloud-sysv: vm/net mixin/cloud-init use/vmguest/kvm use/power/acpi/button; @:
> diff --git a/features.in/tty/config.mk b/features.in/tty/config.mk
> index adca3ae1..252e4174 100644
> --- a/features.in/tty/config.mk
> +++ b/features.in/tty/config.mk
> @@ -14,4 +14,4 @@ use/tty/S0 use/tty/SIF0 use/tty/AMA0: use/tty/%: use/tty
>  	@$(call add,TTY_DEV,tty$*)
>  	@$(call set,TTY_RATE,115200)
>  	@$(call add,SYSLINUX_CFG,tty$*)
> -	@$(call add,BASE_BOOTARGS,console=tty1 console=$$(TTY_DEV)$(comma)$$(TTY_RATE)n8)
> +	@$(call add,BASE_BOOTARGS,console=tty0 console=$$(TTY_DEV)$(comma)$$(TTY_RATE))
> diff --git a/features.in/tty/rootfs/image-scripts.d/50-serial b/features.in/tty/rootfs/image-scripts.d/50-serial
> index 411fbc18..320f93b6 100755
> --- a/features.in/tty/rootfs/image-scripts.d/50-serial
> +++ b/features.in/tty/rootfs/image-scripts.d/50-serial
> @@ -4,6 +4,7 @@
>  BIN=/sbin/agetty
>  CFG=/etc/inittab
>  SEC=/etc/securetty
> +GRUB=/etc/default/grub
>  
>  [ -n "$GLOBAL_TTY_DEV" -a -n "$GLOBAL_TTY_RATE" ] || exit 0
>  [ -s "$CFG" -a -x "$BIN" ] || exit 0
> @@ -16,3 +17,8 @@ if ! grep -q "$BIN" "$CFG"; then
>  		n=$(($n+1))
>  	done
>  fi
> +
> +if [ -s "$GRUB" ]; then
> +	echo 'GRUB_TERMINAL="serial console"' >> "$GRUB"
> +	echo "GRUB_SERIAL_COMMAND=\"serial --speed=$GLOBAL_TTY_RATE --unit=0 --word=8 --parity=no --stop=1\"" >> "$GRUB"
> +fi
> 
> ^ вот это исправление в features.in/tty/rootfs/image-scripts.d/50-serial
> для GRUB_TERMINAL и RUB_SERIAL_COMMAND помогло.
> 

Вот оно что. В qemu эта проблема решается передачей параметра -nographic. Вывод идёт в терминал.
Может и тут что-то подкрутить можно?

А tty0 действительно вместо tty1 нужен?


-- 
С уважением, Антон Мидюков <antohami@altlinux.org>


  reply	other threads:[~2021-12-03 14:21 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-02 20:19 Konstantin Lepikhov
2021-12-03  0:32 ` Антон Мидюков
2021-12-03  8:23   ` Konstantin Lepikhov
2021-12-03  9:22     ` Антон Мидюков
2021-12-03  9:48       ` Konstantin Lepikhov
2021-12-03  9:55         ` Антон Мидюков
2021-12-03 10:14           ` Konstantin Lepikhov
2021-12-03 10:32             ` Антон Мидюков
2021-12-03 10:41               ` Konstantin Lepikhov
2021-12-03 10:54                 ` Антон Мидюков
2021-12-03 11:04                   ` Konstantin Lepikhov
2021-12-03 13:07                     ` Konstantin Lepikhov
2021-12-03 14:21                       ` Антон Мидюков [this message]
2021-12-04 21:04                         ` Konstantin Lepikhov
2021-12-05  6:06                           ` Антон Мидюков
2021-12-05  8:48                             ` Konstantin Lepikhov
2021-12-05  8:54                               ` Антон Мидюков
2021-12-05 10:16                                 ` Konstantin Lepikhov
2021-12-05 10:41                                   ` Антон Мидюков
2021-12-05 14:33                                     ` Konstantin Lepikhov
2021-12-05 22:40                                       ` Антон Мидюков
2021-12-05 22:48                                         ` Антон Мидюков
2021-12-06 10:36                                         ` Konstantin Lepikhov
2021-12-06 10:43                                           ` Антон Мидюков
2021-12-06 12:05                                             ` Konstantin Lepikhov
2022-04-29 11:41                                         ` Konstantin Lepikhov
2022-04-29 12:16                                           ` Антон Мидюков
2022-04-29 16:18                                             ` Konstantin Lepikhov
2022-04-29 16:54                                               ` Антон Мидюков
2022-04-29 18:04                                                 ` Konstantin Lepikhov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=45ac498a-58c3-1ee2-c421-b9067fe23ebb@ya.ru \
    --to=midyukov-anton@ya.ru \
    --cc=devel-distro@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Distributions development

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/devel-distro/0 devel-distro/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 devel-distro devel-distro/ http://lore.altlinux.org/devel-distro \
		devel-distro@lists.altlinux.org devel-distro@lists.altlinux.ru devel-distro@lists.altlinux.com
	public-inbox-index devel-distro

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.devel-distro


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git