amd64 vncconfig crashes

Bug #119982 reported by Roger Binns
70
This bug affects 9 people
Affects Status Importance Assigned to Milestone
vnc4 (Debian)
Fix Released
Unknown
vnc4 (Fedora)
Fix Released
Medium
vnc4 (Ubuntu)
Incomplete
Undecided
Unassigned
Nominated for Hardy by Glenn Ramsey
Declined for Intrepid by Dave Walker
Declined for Jaunty by Dave Walker
Nominated for Lucid by Mark Weaver
Nominated for Maverick by Mark Weaver

Bug Description

I am using vnc4server and presume vncconfig came from that. dpkg refuses to tell me which package contains vncconfig.

$ dpkg -S vncconfig
dpkg: *vncconfig* not found.

Running vncconfig results in an X error:

$ vncconfig -nowin
X Error of failed request: BadLength (poly request too large or internal Xlib length error)
  Major opcode of failed request: 134 (VNC-EXTENSION)
  Minor opcode of failed request: 1 ()
  Serial number of failed request: 63
  Current serial number in output stream: 63

This happens on amd64 and the folks at Redhat have figured out the cause and have a patch.

http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=179635

Tags: bitesize patch
Revision history for this message
Jörn Dreyer (j.dreyer) wrote :

Happens here too:
$ uname -a
Linux shaun 2.6.15-29-amd64-server #1 SMP Wed Aug 29 14:03:12 UTC 2007 x86_64 GNU/Linux
$ dpkg -s vnc4server
Maintainer: Ola Lundqvist <email address hidden>
Architecture: amd64
Source: vnc4
Version: 4.1.1+xorg1.0.2-0ubuntu1.6.06

Changed in vnc4:
status: New → Confirmed
Revision history for this message
Jörn Dreyer (j.dreyer) wrote :

upstream has released a new version. is there a package availiable somewhere?

Changed in vnc4:
assignee: nobody → ubuntu-server
Revision history for this message
Soren Hansen (soren) wrote : Re: [Bug 119982] amd64 vncconfig crashes

On Tue, Oct 16, 2007 at 04:35:13PM -0000, Launchpad Bug Tracker wrote:
> I am using vnc4server and presume vncconfig came from that.

Which version of vnc4server and Ubuntu are you using?

 status incomplete

--
Soren Hansen
Ubuntu Server Team
http://www.ubuntu.com/

Changed in vnc4:
status: Confirmed → Incomplete
Revision history for this message
Jörn Dreyer (j.dreyer) wrote :

~$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=6.06
DISTRIB_CODENAME=dapper
DISTRIB_DESCRIPTION="Ubuntu 6.06.1 LTS"

neither feisty nor gutsy contains a newer version of vnc. as far as google took me it seems like there are problems with the amd64 build.

Revision history for this message
Soren Hansen (soren) wrote : Re: [Bug 119982] Re: amd64 vncconfig crashes

On Thu, Oct 18, 2007 at 03:05:51PM -0000, Jörn Dreyer wrote:
> ~$ cat /etc/lsb-release
> DISTRIB_ID=Ubuntu
> DISTRIB_RELEASE=6.06
> DISTRIB_CODENAME=dapper
> DISTRIB_DESCRIPTION="Ubuntu 6.06.1 LTS"

Thanks for that.

> neither feisty nor gutsy contains a newer version of vnc. as far as
> google took me it seems like there are problems with the amd64 build.

No, no upstream version changes, but there has been minor changes in
each release as can be seen on
https://edge.launchpad.net/ubuntu/+source/vnc4/

Anyhow, thanks for pointing out the patch!

--
Soren Hansen
Ubuntu Server Team
http://www.ubuntu.com/

Revision history for this message
Jörn Dreyer (j.dreyer) wrote :

hm, ok ... so what am I to do to stop my users from complaining?

simply installing a newer package won't work:

dpkg: dependency problems prevent configuration of vnc4server:
 vnc4server depends on libc6 (>= 2.6-1); however:
  Version of libc6 on system is 2.3.6-0ubuntu20.5.
 vnc4server depends on libgcc1 (>= 1:4.2.1); however:
  Version of libgcc1 on system is 1:4.0.3-1ubuntu5.
 vnc4server depends on libstdc++6 (>= 4.2.1); however:
  Version of libstdc++6 on system is 4.0.3-1ubuntu5.
 vnc4server depends on zlib1g (>= 1:1.2.3.3.dfsg-1); however:
  Version of zlib1g on system is 1:1.2.3-6ubuntu4.

Will there be a backport for dapper?

Mathias Gug (mathiaz)
Changed in vnc4:
assignee: ubuntu-server → nobody
Revision history for this message
Roger Binns (ubuntu-rogerbinns) wrote :

This problem still exists in Gutsy 64 bit. I linked to the two line fix in the description (move a #include to earlier in the file). I'll try to update the metadata for this ticket. For importance, the program doesn't even run. And it is very confirmed - just try running it!

Changed in vnc4:
status: Incomplete → Confirmed
Revision history for this message
Dossy Shiobara (dossy) wrote :

I just applied the patch on Gutsy amd64, and I'm happy to say that after restarting vnc4server, vnc4config now works as expected. Thanks for linking to the patch!

Revision history for this message
Roger Binns (ubuntu-rogerbinns) wrote :

It would be nice if the Ubuntu folks actually applied the fix. The program is obviously broken, enough people have seen it, and Redhat have confirmed it and the fix. The issue has been present in 3 Ubuntu releases and now looks like it will also be present in Hardy. Sadly this isn't an isolated incident - another bug I reported has a 5 character fix, program always crashes etc and looks like it won't be fixed for Hardy either.

Revision history for this message
Mario Limonciello (superm1) wrote :

The vnc4 package no longer builds on Hardy. See bug 184225. That's why this won't be fixed unless that bug gets fixed.

Revision history for this message
Dossy Shiobara (dossy) wrote :

For folks who at least want this fix on Gutsy, I'm uploading a patch. To apply, follow these steps:

$ apt-get source vnc4server
$ dpkg-source -x vnc4_4.1.1+xorg1.0.2-0ubuntu6.dsc
$ apt-get build-dep vnc4server
$ patch -p0 < /path/to/vnc4-amd64-vncconfig-bug-119982.patch
$ cd vnc4-4.1.1+xorg1.0.2
$ debian/rules binary
$ dpkg -i vnc4server_4.1.1+xorg1.0.2-0ubuntu6_*.deb

Revision history for this message
Karam (kduhra) wrote :

Is there a patch for this failure (vncconfig) for amd64 Hardy?
> ~$ cat /etc/lsb-release
> DISTRIB_ID=Ubuntu
> DISTRIB_RELEASE=8.04
> DISTRIB_CODENAME=hardy
> DISTRIB_DESCRIPTION="Ubuntu 8.04"

I'm still seeing this problem with all the updates applied.

Revision history for this message
Patrick J. LoPresti (lopresti) wrote :

Ditto. This is (still!) broken on amd64 Hardy. Even though the bug was diganosed and fixed in Fedora in Oct 2006 and on this ticket Oct 2007.

Does Ubuntu have a VNC maintainer?

Revision history for this message
Roger Binns (ubuntu-rogerbinns) wrote :

It was actually reported on June 12, 2007 (ie a year and a day ago). I don't know how you actually get bugs like this fixed where the program crashes so any changes won't make things worse. (I have another bug in another package again with a one line fix otherwise the program crashes and it too has been in 3 consecutive Ubuntu releases with no update in sight.)

Revision history for this message
Patrick J. LoPresti (lopresti) wrote :

Thankfully, since nothing has changed in vnc4server, Dossy Shiobara's Gutsy patch (above) also works just fine for Hardy. I followed a slightly different procedure:

- Download Dossy's vnc4-amd64-vncconfig-bug-119982.patch above
- Become root
- Make sure /etc/apt/sources.list has a "deb-src" line to match its "deb" line for the main Ubuntu archive, including the "universe" label. For example:
deb-src http://us.archive.ubuntu.com/ubuntu/ hardy universe main restricted
$ apt-get update # (necessary if you modified sources.list)
$ apt-get build-dep vnc4server
$ apt-get source vnc4server # (runs "dpkg-source -x" automagically)
$ patch -p0 < /path/to/vnc4-amd64-vncconfig-bug-119982.patch
$ cd vnc4-4.1.1+xorg1.0.2
$ debian/rules binary
$ dpkg -i ../vnc4server_4.1.1+xorg1.0.2-0ubuntu7_amd64.deb

Revision history for this message
David Clarke (daclarke) wrote :

Thanks Patrick, we followed your instructions for the Dossy patch and it's working fine now.

Revision history for this message
Karam (kduhra) wrote :

Thanks Patrick. That fixed the problem. Still cannot understand why we're waiting for an official fix given the fact a solution has existed since April 2008!!

Revision history for this message
Mirar (launchpad-sort) wrote :

The problem is still there in Intrepid. The version hasn't changed, so I guess that would explain it. :p

This bug renders the vnc4server package useless.

Thanks for the patch though, Patrick. It allows me to run vnc4server anyway. (However, 8-bit characters in the clipboard - åäö - doesn't seem to work...)

Revision history for this message
Paul Mattes (paul-mattes) wrote :

I applied the Fedora patch, built from source, and installed, and now everything works -- many, many thanks.

However, now the Update Manager is convinced that I need to update vnc4server. Is there a way to convice it that vnc4server is up-to-date?

Revision history for this message
Lerxst (stig-bull) wrote :

I'm unable to build the vnc4server source on Intrepid, following Patrick's procedure (the Hardy procedure should not be that different from Intrepid).
I get the following error:
ccess.c: In function 'LocalClientCredAndGroups':
access.c:1459: error: storage size of 'peercred' isn't known
access.c:1471: warning: implicit declaration of function '_XSERVTransIsLocal'
access.c:1471: warning: nested extern declaration of '_XSERVTransIsLocal'
access.c:1481: warning: implicit declaration of function '_XSERVTransGetConnectionNumber'
access.c:1481: warning: nested extern declaration of '_XSERVTransGetConnectionNumber'
access.c:1459: warning: unused variable 'peercred'
make[2]: *** [access.lo] Error 1
make[2]: Leaving directory `/home/stig/build/vnc4-4.1.1+xorg1.0.2/xorg-server-1.0.2/os'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/stig/build/vnc4-4.1.1+xorg1.0.2/xorg-server-1.0.2'
make: *** [build-server-stamp] Error 2

I'm building with gcc 4.3, but I've tried with 4.2, 4.1 and 3.4 with the exact same error.

Can't Google anything with peercred related to vnc4server, so can somebody please help, or even better, point me to a .deb vnc4server file with the patch included? :-)

Lerxst

Revision history for this message
tomer t (tomer-linqmap) wrote :

On my system
$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=8.10
DISTRIB_CODENAME=intrepid
DISTRIB_DESCRIPTION="Ubuntu 8.10"
Here's a modified procedure based on the above that successfully created the package
The build-dep command aborted complaining about unmet dependency of package
E mesa-swx11-source
I installed this package manually from here
https://launchpad.net/ubuntu/intrepid/+package/mesa-swx11-source
And then run build-dep again
$ apt-get build-dep vnc4server
$ cd vnc4-4.1.1+xorg1.0.2
I got the same access.c:1459 compilation error which was due to missing compilation flag.
This missing compilation flag is set in env. var of the configure script of xorg-server_1.0.2
$ export XSERVERCFLAGS_CFLAGS=-D_GNU_SOURCE
$ debian/rules binary

Tomer

Revision history for this message
Lerxst (stig-bull) wrote :

Thank you, Tomer!

Jorge Castro (jorge)
tags: added: bitesize patch
Changed in vnc4 (Fedora):
status: Unknown → Fix Released
Revision history for this message
Zoide (andresodio) wrote :

Does anyone have the fix/workaround for Ubuntu 9.04? tomer t's procedure for involves downloading mesa-swx11-source for 8.10, but there is no mesa-swx11-source for 9.04.

Revision history for this message
David Stansby (dstansby-deactivatedaccount) wrote :

It seems that even debian hasn't had a newer version of vnc4 for a while, thus a sync request from debian is currently not possible. I'll forward this bug to debian and see what happens.

Revision history for this message
Omer Mano (mermerico-gmail) wrote :

Ok so in the mean time, I have a debdiff based on the patch that Dossy Shiobara upleaded. Hopefully it can be included for Karmic. It needs to be tested on AMD64 (the original patch works, so it should be fine, but this was my first packaging job so who knows?) and approved by the Ubuntu Sponsors.

Revision history for this message
Omer Mano (mermerico-gmail) wrote :

Ok so in the mean time, I have a debdiff based on the patch that Dossy Shiobara uploaded. Hopefully it can be included for Karmic. It needs to be tested on AMD64 (the original patch works, so it should be fine, but this was my first packaging job so who knows?) and approved by the Ubuntu Sponsors.

Revision history for this message
Iain Lane (laney) wrote :

Doesn't build for me. Can you have a look?

Checking for source dependency conflicts...
E: Couldn't find package mesa-swx11-source
Installing positive dependencies: debhelper zlib1g-dev automake1.9 autoconf xserver-xorg-dev xutils pkg-config x11proto-bigreqs-dev x11proto-composite-dev x11proto-core-dev x11proto-damage-dev x11proto-evie-dev x11proto-fixes-dev x11proto-kb-dev x11proto-xinerama-dev x11proto-randr-dev x11proto-record-dev x11proto-render-dev x11proto-resource-dev x11proto-scrnsaver-dev x11proto-trap-dev x11proto-video-dev x11proto-xcmisc-dev x11proto-xext-dev x11proto-xf86bigfont-dev x11proto-xf86dga-dev x11proto-xf86misc-dev x11proto-xf86vidmode-dev xtrans-dev libxau-dev libxdmcp-dev libxfont-dev libfontenc-dev libxkbfile-dev x11proto-xf86dri-dev libdrm-dev mesa-swx11-source x11proto-gl-dev libgl1-mesa-dev libxmuu-dev libxext-dev libx11-dev libxrender-dev libxi-dev x11proto-dmx-dev dpatch libdmx-dev libxpm-dev libxaw7-dev libxt-dev libxmu-dev libxtst-dev libxres-dev libfreetype6-dev flex
Reading package lists...
Building dependency tree...
Reading state information...
E: Couldn't find package mesa-swx11-source
apt-get failed.
Package installation failed
Trying to reinstall removed packages:
Trying to uninstall newly installed packages:
Source-dependencies not satisfied; skipping vnc4

Changed in vnc4 (Ubuntu):
status: Confirmed → In Progress
status: In Progress → Incomplete
Revision history for this message
Dossy Shiobara (dossy) wrote :

Iain: See Tomer's comment above (#21) on how to handle the mesa-swx11-source dependency issue.

Revision history for this message
Lerxst (stig-bull) wrote :

On Sun, 2009-08-16 at 10:52 +0000, Iain Lane wrote:
> Doesn't build for me. Can you have a look?
>
> Checking for source dependency conflicts...
> E: Couldn't find package mesa-swx11-source
> Installing positive dependencies: debhelper zlib1g-dev automake1.9 autoconf xserver-xorg-dev xutils pkg-config x11proto-bigreqs-dev x11proto-composite-dev x11proto-core-dev x11proto-damage-dev x11proto-evie-dev x11proto-fixes-dev x11proto-kb-dev x11proto-xinerama-dev x11proto-randr-dev x11proto-record-dev x11proto-render-dev x11proto-resource-dev x11proto-scrnsaver-dev x11proto-trap-dev x11proto-video-dev x11proto-xcmisc-dev x11proto-xext-dev x11proto-xf86bigfont-dev x11proto-xf86dga-dev x11proto-xf86misc-dev x11proto-xf86vidmode-dev xtrans-dev libxau-dev libxdmcp-dev libxfont-dev libfontenc-dev libxkbfile-dev x11proto-xf86dri-dev libdrm-dev mesa-swx11-source x11proto-gl-dev libgl1-mesa-dev libxmuu-dev libxext-dev libx11-dev libxrender-dev libxi-dev x11proto-dmx-dev dpatch libdmx-dev libxpm-dev libxaw7-dev libxt-dev libxmu-dev libxtst-dev libxres-dev libfreetype6-dev flex
> Reading package lists...
> Building dependency tree...
> Reading state information...
> E: Couldn't find package mesa-swx11-source
> apt-get failed.
> Package installation failed
> Trying to reinstall removed packages:
> Trying to uninstall newly installed packages:
> Source-dependencies not satisfied; skipping vnc4
>
> ** Changed in: vnc4 (Ubuntu)
> Status: Confirmed => In Progress
>
> ** Changed in: vnc4 (Ubuntu)
> Status: In Progress => Incomplete

Did you do this:

$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=8.10
DISTRIB_CODENAME=intrepid
DISTRIB_DESCRIPTION="Ubuntu 8.10"
Here's a modified procedure based on the above that successfully created
the package
The build-dep command aborted complaining about unmet dependency of
package
E mesa-swx11-source
I installed this package manually from here
https://launchpad.net/ubuntu/intrepid/+package/mesa-swx11-source
And then run build-dep again
$ apt-get build-dep vnc4server
$ cd vnc4-4.1.1+xorg1.0.2
I got the same access.c:1459 compilation error which was due to missing
compilation flag.
This missing compilation flag is set in env. var of the configure script
of xorg-server_1.0.2
$ export XSERVERCFLAGS_CFLAGS=-D_GNU_SOURCE
$ debian/rules binary

Sounds like it's the missing mesa-swx11 it's complaining about

Revision history for this message
jcarlyle (jccarlyle) wrote :

Has anyone been able to build this package on Jaunty? How did a package that doesn't even build end up in the distribution? This should be embarrassing for Canonical.

Revision history for this message
jcarlyle (jccarlyle) wrote :

After walking away last night angry and disgusted about the state of vnc4 support in Ubuntu, it occurred to me that I could the regular Debian version of the package.

I obtained the Debian source package for vnc4 for lenny from: http://packages.debian.org/source/lenny/vnc4

I then manually patched unix/xc/programs/Xserver/vnc/vncExtInit.cc. (I moved the include of XserverDesktop.h to immediately after the include of stdio.h.)

Finally, I built the package in the usual manner: debuild -us uc

There are only two binary packages built from the Debian version of vnc4: vnc4server and xvnc4viewer. I uninstalled the Ubuntu vnc4server and vnc4-common binary packages (using apt-get purge), and then used dpkg to install the binary packages that I had just built.

I am happy to report that everything appears to be working fine. The vnc4config tool no longer crashes on startup, and I can now happily cut-and-paste from my vnc session.

Miguel Ruiz (mruiz)
Changed in vnc4 (Ubuntu):
assignee: nobody → Miguel Ruiz (mruiz)
Changed in vnc4 (Debian):
status: Unknown → Fix Released
Revision history for this message
Michael Terry (mterry) wrote :

OK, here's the story. At one point, Debian's maintainer decided to embed XFree86 into the package because it didn't quite work with xorg. But when that version percolated to Ubuntu, we decided we'd rather use xorg, so we rebased vnc4 on xorg. (the particulars are not clear to me -- I'm scraping this together from bug reports and changelogs)

Since then, the Debian packaging has changed a lot to keep up with the times. The Ubuntu packaging not so much. Nowadays, there are several issues when building our package (it embeds xorg 1.0.2, while Karmic is on 1.6; its xorg uses obsolete automake scripts which causes errors; it references very old packages in the Build-Depends line (including one that no longer exists)).

David's report to Debian got summarily closed because he was using our Ubuntu version. I've opened a new bug about this patch, noting again that Red Hat had the same problem. Hopefully it won't be closed. Will update the Debian bug task when their bts assigns my bug a number.

So ideally, our packaging would be updated to the new xorg and fix the various build issues. Realistically, that's not happening before Karmic (we're too close to release and it would not just be a bug fix at that point). It may be possible to get the package into shape, but only on a superficial level (would still use ancient xorg).

Omer, thanks for the patch. One tip is that you should use patch tags rather than prose (https://wiki.ubuntu.com/UbuntuDevelopment/PatchTaggingGuidelines). But I was delighted to see any description of the patch at all. :) Also, rather than apply a patch that doesn't unapply itself when running 'clean', it's just as fine to apply the patch directly if the package doesn't have a patch system.

So, I'm not applying anything yet. To fix this for Karmic, we'd have to have a patch that removed the mesa-swx11-source Build-Depend (I think it's a safe removal?) and that added a patch to the embedded xorg configure.ac (the current package has an example patch to xorg already -- just copy that pattern) to fix use of AC_SUBST (ala http://lists.freedesktop.org/archives/xorg-commit/2008-April/015845.html). There may be more issues lurking.

And that's the story of why this bug has managed to stuck around over several major releases.

Michael Terry (mterry)
Changed in vnc4 (Debian):
status: Fix Released → Unknown
Changed in vnc4 (Debian):
status: Unknown → New
Changed in vnc4 (Debian):
status: New → Fix Released
Miguel Ruiz (mruiz)
Changed in vnc4 (Ubuntu):
assignee: Miguel Ruiz (mruiz) → nobody
Revision history for this message
gwydion.dot (gwydion-dot) wrote :

Bug is still present.

Revision history for this message
Ryan Daly (daly-ctcnet) wrote :

I can confirm this bug is still present in 9.10:

daly@linux13 <193#> uname -m
x86_64

daly@linux13 <194#> lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 9.10
Release: 9.10
Codename: karmic

daly@linux13 <195#> cat .vnc/linux13:1.log

Xvnc Free Edition 4.1.1
Copyright (C) 2002-2005 RealVNC Ltd.
See http://www.realvnc.com for information on VNC.
Underlying X server release 70000000, The X.Org Foundation

Tue Dec 29 16:25:09 2009
 vncext: VNC extension running!
 vncext: Listening for VNC connections on port 5901
 vncext: created VNC server for screen 0
error opening security policy file /etc/X11/xserver/SecurityPolicy
Xlib: extension "Generic Event Extension" missing on display ":1.0".
Xlib: extension "Generic Event Extension" missing on display ":1.0".
X Error of failed request: BadLength (poly request too large or internal Xlib length error)
  Major opcode of failed request: 134 (VNC-EXTENSION)
  Minor opcode of failed request: 1 ()
  Serial number of failed request: 63
  Current serial number in output stream: 63

Revision history for this message
Benjamin Drung (bdrung) wrote :

I unsubscribe ubuntu-universe-sponsors for now. Please resubscribe them, when there is a debdiff that builds and works (see comment #32).

Revision history for this message
wind (pipilu8) wrote :

On Linux nihao 2.6.31-17-server #54-Ubuntu SMP Thu Dec 10 18:06:56 UTC 2009 x86_64 GNU/Linux

From the log

X Error of failed request: BadLength (poly request too large or internal Xlib length error)
Major opcode of failed request: 134 (VNC-EXTENSION)
Minor opcode of failed request: 1 ( )
Serial number of failed request: 65
Current serial number in output stream: 65

Only happens on AMD64 Vnc4server

Revision history for this message
wind (pipilu8) wrote :

workaround on Ubuntu 9.10

apt-get remove vnc4server
rm -rf ~/.vnc
wget http://ftp.us.debian.org/debian/pool/main/v/vnc4/vnc4server_4.1.1+X4.3.0-31_amd64.deb
dpkg -i vnc4server_4.1.1+X4.3.0-31_amd64.deb

Every works

Revision history for this message
Zoide (andresodio) wrote :

Many thanks to "wind"!!!

His workaround works perfectly and is the easiest solution so far.

For the record, I used a more recent version of the Debian package (http://ftp.us.debian.org/debian/pool/main/v/vnc4/vnc4server_4.1.1%2bX4.3.0-37_amd64.deb) and it worked.

Revision history for this message
Matt Fischer (mfisch) wrote :

In precise, the version is 4.1.1+xorg4.3.0-37ubuntu4, so the fix that Zoide and wind mention is in Ubuntu. I cannot reproduce it with this version on amd64. Can someone confirm that this is fixed for them?

Changed in vnc4 (Fedora):
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.