Skip to content

Commit ee85085

Browse files
authored
CA-410965: Modify default ref of console (#6553)
The `ref` parameter within the `location` attribute of the console can refer to either the VM's ref or the console's own ref. Currently, the console's location uses the VM's ref by default. This causes an issue: when executing xe console, the requested location contains the VM's ref. If the ref points to the VM, xapi will attempt to use the RFB console (which is graphical) by default, rather than the VT100 console (which is text-based). As a result, the xs console command fails to open the console and hangs. **Solution:** Update the default ref in the console's `location` to the console's own ref. With this change, whether accessing the RFB or the VT100 console, the ref in the `location` will always point to the respective console itself.
2 parents 1a68634 + 0728527 commit ee85085

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ocaml/xapi/create_misc.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ and create_domain_zero_console_record_with_protocol ~__context ~domain_zero_ref
307307
let location =
308308
Uri.(
309309
make ~scheme:"https" ~host:address ~path:Constants.console_uri
310-
~query:[("ref", [Ref.string_of domain_zero_ref])]
310+
~query:[("ref", [Ref.string_of console_ref])]
311311
()
312312
|> to_string
313313
)

0 commit comments

Comments
 (0)