ubuntu-bug fails when run via remote SSH login

Bug #1989545 reported by Ian! D. Allen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apport (Ubuntu)
New
Undecided
Unassigned

Bug Description

I'm running Ubuntu 20.04 on my desktop. I SSH into my laptop running 22.04:

    desktop$ ssh laptop
    laptop$ sudo -sE
    laptop#

If I now run most any X11 client applications (e.g. xload, xterm)
using this laptop SSH command line, they correctly open windows on my
desktop X11 display, not on my laptop, using the DISPLAY variable set
to localhost:10.0. But ubuntu-bug does not do this when I run it on
the laptop:

    laptop# ubuntu-bug /etc/network/if-up.d/resolved

At this point, the laptop display incorrectly has the apport X11 window
open. The apport window does not open on my desktop, like any other
X11 application would. It appears to ignore my DISPLAY variable.

If I go over to the laptop and try to continue with the bug report,
everything falls apart when it tries to start up a web browser. I get
all these error messages on my SSH terminal screen:

    update.go:85: cannot change mount namespace according to change mount (/var/lib/snapd/hostfs/usr/local/share/fonts /usr/local/share/fonts none bind,ro 0 0): not a directory
    update.go:85: cannot change mount namespace according to change mount (/var/lib/snapd/hostfs/usr/share/libreoffice/help /usr/share/libreoffice/help none bind,ro 0 0): cannot create directory "/usr/share/libreoffice/help": permission denied
    update.go:85: cannot change mount namespace according to change mount (/var/lib/snapd/hostfs/usr/share/xubuntu-docs /usr/share/xubuntu-docs none bind,ro 0 0): cannot open directory "/var/lib": permission denied
    /home/username/Music was removed, reassigning MUSIC to homedir
    X11 connection rejected because of wrong authentication.
    X11 connection rejected because of wrong authentication.
    Error: cannot open display: localhost:10.0
    X11 connection rejected because of wrong authentication.
    X11 connection rejected because of wrong authentication.
    X11 connection rejected because of wrong authentication.
    X11 connection rejected because of wrong authentication.

If ubuntu-bug cannot work over SSH with DISPLAY=localhost:10.0, it should
detect this and not even try.

ProblemType: Bug
DistroRelease: Ubuntu 22.04
Package: apport 2.20.11-0ubuntu82.1
ProcVersionSignature: Ubuntu 5.15.0-48.54-generic 5.15.53
Uname: Linux 5.15.0-48-generic x86_64
ApportLog:

ApportVersion: 2.20.11-0ubuntu82.1
Architecture: amd64
CasperMD5CheckResult: unknown
CurrentDesktop: ubuntu:GNOME
Date: Wed Sep 14 02:33:18 2022
InstallationDate: Installed on 2020-09-08 (735 days ago)
InstallationMedia: Ubuntu 20.04.1 LTS "Focal Fossa" - Release amd64 (20200731)
PackageArchitecture: all
SourcePackage: apport
UpgradeStatus: Upgraded to jammy on 2022-04-04 (162 days ago)

Revision history for this message
Ian! D. Allen (idallen) wrote :
Revision history for this message
Benjamin Drung (bdrung) wrote :

ubuntu-bug should work with DISPLAY set to an remote display. I checked the code: It does not fiddle around with the DISPLAY environment variable.

Can you check if X11 is used instead of wayland? Have you tried calling /usr/share/apport/apport-gtk directly? Is /usr/share/apport/apport-kde affected as well?

Revision history for this message
Ian! D. Allen (idallen) wrote :

The laptop is logged in and running Wayland: /usr/bin/Xwayland :0
My desktop is running X11: /usr/lib/xorg/Xorg -nolisten tcp :0
When I SSH into the laptop from the desktop, my DISPLAY is set to "localhost:10".
When I start an xterm in the SSH session (running xterm on the laptop),
the xterm window opens correctly on the desktop X11, not on the laptop.
Inside that xterm, when I type "ubuntu-bug" (running ubuntu-bug on the laptop),
ubuntu-bug incorrectly opens a window on the laptop, not on the desktop.
Typing "/usr/share/apport/apport-gtk alskdjflkj" also incorrectly opens a window
on the laptop, not the desktop.
I don't have /usr/share/apport/apport-kde installed, but I could install it
and see what happens if that would be helpful.

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.