Bug 706859 - [REF] Add file lock to xenconsole
Summary: [REF] Add file lock to xenconsole
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: xen
Version: 5.7
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: rc
: ---
Assignee: Xen Maintainance List
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks: 699611
TreeView+ depends on / blocked
 
Reported: 2011-05-23 09:35 UTC by Yufang Zhang
Modified: 2012-02-21 05:55 UTC (History)
8 users (show)

Fixed In Version: xen-3.0.3-133.el5
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-02-21 05:55:10 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0160 normal SHIPPED_LIVE xen bug fix and enhancement update 2012-02-20 14:53:33 UTC

Description Yufang Zhang 2011-05-23 09:35:21 UTC
Description of problem:
Attach console to a guest which already has console attached would cause race contention, so that both consoles of the guest would get stuck. It would make sense to add a file lock to prevent access to console of a guest when the guest already has a console attached, either in xend or in xenconsole. 

Version-Release number of selected component (if applicable):
xen-3.0.3-131.el5

How reproducible:
Always.

Steps to Reproduce:
1. Start a pv guest and attach console to the guest via xm console.
2. In another terminal, attach the console to the same guest via xm console.
3.
  
Actual results:
The both consoles get stuck, and print strange outputs.

Expected results:
xend or xenconsole should prevent attaching console to a guest which already has a console attached. A warning should be printed so that customers could know that it is not a supported behaviour.

Additional info:
Upstream also have such issues, although they support multiple consoles for pv guest. When you attach the same console(with the same console id) more than once, the consoles would get stuck.

Comment 5 Yuyu Zhou 2011-11-30 06:41:41 UTC
reproduce the bug on xen-3.0.3-132.el5 and verify the bug on xen-3.0.3-135.el5.

Steps:
1. Start a pv guest and attach console to the guest via xm console.
2. In another terminal, attach the console to the same guest via xm console.

On xen-3.0.3-132.el5, the both consoles get stuck, and print strange outputs.

On xen-3.0.3-135.el5, the second console can not be attached, and proper message show in second termimal:
# xm con 11
Another console has already been attached to guest
The first console still works fine.

So change this bug to VERIFIED.

Comment 6 errata-xmlrpc 2012-02-21 05:55:10 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2012-0160.html


Note You need to log in before you can comment on or make changes to this bug.