[pve-devel] [PATCH] vncproxy: wait max 10s for the socket if it does not exist
Stefan Priebe - Profihost AG
s.priebe at profihost.ag
Thu Feb 28 14:07:53 CET 2013
sorry sent new fix.
Stefan
Am 28.02.2013 12:53, schrieb Dietmar Maurer:
> I will revert that patch. This only works if the VM is on local machine. Else it breaks the console.
>
> I guess you should add the code into 'qm vncproxy' instead (file 'qm').
>
>> -----Original Message-----
>> From: pve-devel-bounces at pve.proxmox.com [mailto:pve-devel-
>> bounces at pve.proxmox.com] On Behalf Of Stefan Priebe
>> Sent: Montag, 25. Februar 2013 21:57
>> To: pve-devel at pve.proxmox.com
>> Subject: [pve-devel] [PATCH] vncproxy: wait max 10s for the socket if it does not
>> exist
>>
>>
>> Signed-off-by: Stefan Priebe <s.priebe at profihost.ag>
>> ---
>> PVE/API2/Qemu.pm | 3 +++
>> 1 file changed, 3 insertions(+)
>>
>> diff --git a/PVE/API2/Qemu.pm b/PVE/API2/Qemu.pm index bed2f4c..32bacaf
>> 100644
>> --- a/PVE/API2/Qemu.pm
>> +++ b/PVE/API2/Qemu.pm
>> @@ -1123,6 +1123,9 @@ __PACKAGE__->register_method({
>> my $realcmd = sub {
>> my $upid = shift;
>>
>> + my $c = 0;
>> + while ( ++$c < 10 && !-e "/var/run/qemu-server/$vmid.vnc" ) {
>> +sleep(1); }
>> +
>> syslog('info', "starting vnc proxy $upid\n");
>>
>> my $qmcmd = [@$remcmd, "/usr/sbin/qm", 'vncproxy', $vmid];
>> --
>> 1.7.10.4
>>
>> _______________________________________________
>> pve-devel mailing list
>> pve-devel at pve.proxmox.com
>> http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
>
>
More information about the pve-devel
mailing list