Bug 18383 - Zugriff per Console auf virtuelle Instanzen
Zugriff per Console auf virtuelle Instanzen
Status: CLOSED WONTFIX
Product: UCS
Classification: Unclassified
Component: Virtualization - UVMM
UCS 4.3
Other Linux
: P2 enhancement (vote)
: ---
Assigned To: UCS maintainers
:
Depends on: 21758
Blocks:
  Show dependency treegraph
 
Reported: 2010-05-12 09:56 CEST by Andreas Büsching
Modified: 2023-06-28 10:46 CEST (History)
3 users (show)

See Also:
What kind of report is it?: Feature Request
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?: Yes
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number: 2017073121000411
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Büsching univentionstaff 2010-05-12 09:56:21 CEST
Sofern die virtuelle Maschine einen Zugriff per Console zulässt könnte eine entsprechende Console angezeigt werden
Comment 1 Philipp Hahn univentionstaff 2010-08-05 17:13:10 CEST
Bedingt durch Bug #19249 Comment 3:

> Da inzwischen PyGrub für Xen-PV-Maschinen benutzt wird, ist hier PyGrub in das
> innerhalb von /boot/grub/menu.cfg definierte Timeout von 60 Sekunden gelaufen,
> um das Image zu extrahieren. Das Xen-CLI-Tool "xm" implementiert deshalb extra
> eine Logik in <file:xen-3.4.3/tools/python/xen/xm/create.py>, die immer den
> interaktiven Modus von PyGrub per '-q' deaktiviert (außer es wird die
> Xen-Console direkt per "xm create -c ..." gefordert.)
>
> UVMMd erzeugt jetzt ebenfalls den Eintrag <bootloader_args>-q</bootloader_args>
> in der Konfigurationsdateien.

Wenn der Zugriff auf die Xen-Console implementiert wird, sollte dann analog zu "xm create" ebenfalls das "-q" unterdrückt werden, wenn die Console verwendet wird.
Comment 2 Philipp Hahn univentionstaff 2010-08-24 13:34:17 CEST
Siehe <http://fedoraproject.org/wiki/Features/VirtioSerial> für mögliche Hintergrundinformationen.
Comment 3 Philipp Hahn univentionstaff 2010-12-08 15:55:56 CET
Unsere Version von kvm ist zu alt und kann keine virtio-console; alternativ geht aber eine virtualisierte serielle Konsole:

Host:
# virsh edit $MY_DOM
  <console type='pty'>
    <target type='serial' port='0'/>
  </console>

Gast:
# echo 'T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100' >>/etc/inittab
# echo root >>/etc/securetty
# telinit Q

Host:
# virsh console $MY_DOM
bzw.
# socat - $(virsh dumpxml pmh93client32 | sed -ne "s,.*<console type='pty' tty='\(.*\)'>.*,\1,p")

Ein AJAX-Telnet gibt es z.B. hier:
<http://plugins.jquery.com/project/ajax_terminal>
<http://www.koikids.com/dashboard.htm>
Comment 4 Philipp Hahn univentionstaff 2011-08-10 19:34:30 CEST
"virsh console $VM" crasht bis einschließlich libvirt (<= 0.9.4) beim 2. Versuch, sich mit der Console zu verbinden, weil ein die getestete Variable nicht der freigegebenen Variable entspricht. Der folgender Patch korrigiert das: <http://www.redhat.com/archives/libvir-list/2011-August/msg00340.html>

Allerdings behält der libvirtd danach pro geöffneter Konsole das /dev/ptd/*-Device geöffnet und ein anschließendes "virsh list" bleibt hängen:

# lsof /dev/# tail -n 1 /var/log/libvirt/qemu/pmh_cachetest.log 
char device redirected to /dev/pts/3
pts/3
libvirtd 6129 root   17u   CHR              136,3                6 /dev/pts/3
libvirtd 6129 root   21u   CHR              136,3                6 /dev/pts/3
libvirtd 6129 root   22u   CHR              136,3                6 /dev/pts/3
libvirtd 6129 root   23u   CHR              136,3                6 /dev/pts/3
Comment 5 Philipp Hahn univentionstaff 2011-08-11 18:38:48 CEST
Der Patch aus comment 4 ist hier: <http://libvirt.org/git/?p=libvirt.git;a=commit;h=ed009313b166da9fd077758a21aa9a328209e7f1>

Zusätzlich ist noch <http://libvirt.org/git/?p=libvirt.git;a=commit;h=88416593e19d56433662b801d6e72ba182024fd9> anzuwenden, der besagte Endlosschleife korrigiert.
Comment 6 Philipp Hahn univentionstaff 2011-08-15 18:34:24 CEST
Die beiden Patches für libvirt gegen die SEGVs wurden eingespielt.

svn9563, libvirt_0.8.7-1.92.201108151823
Comment 7 Philipp Hahn univentionstaff 2011-12-13 09:54:32 CET
Korrekturen:
(In reply to comment #3)
Es reicht:
> # virsh edit $MY_DOM
>   <console type='pty'/>

> Gast:
> # echo 'T0:23:respawn:/sbin/getty -L ttyS0 9600 vt100' >>/etc/inittab
> # echo root >>/etc/securetty

Statt "root" muß es natürlich "ttyS0" lauten, was da eigentlich auch schon erhalten wäre, wenn es "/etc/univention/templates/files/etc/securetty" nicht wieder herauspatchen würde :-(

# echo ttyS0 >>/etc/univention/templates/files/etc/securetty
# ucr commit /etc/securetty
Comment 8 Philipp Hahn univentionstaff 2011-12-13 09:56:28 CET
(In reply to comment #7)
> Statt "root" muß es natürlich "ttyS0" lauten, was da eigentlich auch schon
> erhalten wäre, wenn es "/etc/univention/templates/files/etc/securetty" nicht
> wieder herauspatchen würde :-(

→ branches/ucs-3.0/ucs/desktop/univention-x-core/conffiles/etc/securetty
Comment 9 Stefan Gohmann univentionstaff 2014-02-18 21:37:58 CET
This issue has been filed against UCS 2.3.

UCS 2.3 is out of maintenance and many UCS components have vastly changed in
later releases. Thus, this issue is now being closed.

If this issue still occurs in newer UCS versions, please use "Clone this bug".
In this case please provide detailed information on how this issue is affecting
you.
Comment 10 Valentin Heidelberger univentionstaff 2018-09-12 16:22:31 CEST
The customer still has problems with this. They currently have to manually virsh edit every vm they want to use via virsh console to configure the serial console. This results in a lot of administrative overhead
Comment 11 Ingo Steuwer univentionstaff 2021-05-14 13:46:14 CEST
This issue has been filed against UCS 4.3.

UCS 4.3 is out of maintenance and many UCS components have changed in later releases. Thus, this issue is now being closed.

If this issue still occurs in newer UCS versions, please use "Clone this bug" or reopen it and update the UCS version. In this case please provide detailed information on how this issue is affecting you.