Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

web-greeter sometimes shows wrong screen on widget. #69

Closed
jgao1025 opened this issue Aug 21, 2023 · 2 comments
Closed

web-greeter sometimes shows wrong screen on widget. #69

jgao1025 opened this issue Aug 21, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@jgao1025
Copy link

jgao1025 commented Aug 21, 2023

Environment

  • OS:
NAME="Linux Mint"
VERSION="21.1 (Vera)"
ID=linuxmint
ID_LIKE="ubuntu debian"
PRETTY_NAME="Linux Mint 21.1"
VERSION_ID="21.1"
HOME_URL="https://www.linuxmint.com/"
SUPPORT_URL="https://forums.linuxmint.com/"
BUG_REPORT_URL="http://linuxmint-troubleshooting-guide.readthedocs.io/en/latest/"
PRIVACY_POLICY_URL="https://www.linuxmint.com/"
VERSION_CODENAME=vera
UBUNTU_CODENAME=jammy

  • web-greeter version: output of web-greeter --version
web-greeter --version
3.5.2

Bug description

I have met a werid problem and so far I can't isolate the problem of where the root cause might be.

background

I have a OptiPlex 7450 All-In-One machine, and the Graphics info is like below.

Graphics:
  Device-1: Intel HD Graphics 630 driver: i915 v: kernel
  Display: server: X.org v: 1.21.1.4 with: Xwayland v: 22.1.1 driver: X: loaded: modesetting
    unloaded: fbdev,vesa gpu: i915 tty: 176x49 resolution: 1: 1920x1080 2: 3840x2160
  Message: GL data unavailable in console for root.

This machine is running Linux Mint 21.1 and lightdm as display manager. I changed to use web-greeter as the new fancy greeter.

I have used dracula theme, and it uses two different html pages in the index.yml file.

primary_html: "index.html"
secondary_html: "secondary.html"

Usually, the primary monitor will show index.html and secondary monitor will show secondar.html. If there is only one monitor, it will just show index.html.

issue

In some of our environment, we need to connect Dell All-In-One machine 7450 to an external monitor. It is a samsung 4k monitor. Everytime when I connect the Dell All-In-One machine to this external monitor, both of the monitors (the Dell All-In-One in-built monitor and samgsung 4k external monitor) shows the same screen which is "secondary.html".

what I have tried so far

  1. check xrandr info
$ sudo -u lightdm DISPLAY=:0 xrandr
Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 16384 x 16384
DP-1 disconnected primary (normal left inverted right x axis y axis)
HDMI-1 disconnected (normal left inverted right x axis y axis)
HDMI-2 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 510mm x 287mm
   1920x1080     60.00*+  60.00    50.00    50.00    59.94  
   1680x1050     59.88  
   1280x1024     60.02  
   1440x900      59.90  
   1360x768      60.02  
   1280x720      60.00    50.00    59.94  
   1024x768      60.00  
   800x600       60.32  
   720x576       50.00  
   720x480       60.00    59.94  
   640x480       60.00    59.94  
HDMI-3 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 1872mm x 1053mm
   1920x1080     60.00    50.00    59.94    30.00    25.00    24.00    29.97    23.98* 
   1920x1080i    60.00    50.00    59.94  
   1680x1050     59.88  
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1440x900      59.90  
   1280x800      59.91  
   1152x864      75.00  
   1280x720      60.00    50.00    59.94  
   1024x768      75.03    70.07    60.00  
   832x624       74.55  
   800x600       72.19    75.00    60.32  
   720x576       50.00  
   720x576i      50.00  
   720x480       60.00    59.94  
   720x480i      60.00    59.94  
   640x480       75.00    72.81    66.67    60.00    59.94  
   720x400       70.08  
sudo -u lightdm DISPLAY=:0 xrandr --listactivemonitors
Monitors: 2
 0: +HDMI-2 1920/510x1080/287+0+0  HDMI-2
 1: +HDMI-3 1920/1872x1080/1053+0+0  HDMI-3

from what xrandr gave me, there are two monitors, one is HDMI-2 which is Dell machine, and the other is HDMI-3, which is external monitor.

I also debug in /usr/lib/web-greeter/browser/browser.py

263         for win in self.windows:
264             if win.is_primary:
265                 logger.debug("check primary display name")
266                 logger.debug(win.display.name())
267                 win.window.win_page.setUrl(primary_url)
268             else:
269                 logger.debug("second loaded")
270                 logger.debug("check second display name")
271                 logger.debug(win.display.name())
272                 win.window.win_page.setUrl(secondary_url)

I can see the log as below

2023-08-21 13:32:49 [ DEBUG ] browser - browser.py:265 : load_theme | check primary display name
2023-08-21 13:32:49 [ DEBUG ] browser - browser.py:266 : load_theme | HDMI-2
2023-08-21 13:32:49 [ DEBUG ] browser - browser.py:269 : load_theme | second loaded
2023-08-21 13:32:49 [ DEBUG ] browser - browser.py:270 : load_theme | check second display name
2023-08-21 13:32:49 [ DEBUG ] browser - browser.py:271 : load_theme | HDMI-3
2023-08-21 13:32:49 [ DEBUG ] browser - browser.py:274 : load_theme | Theme loaded

This means web-greeter had found that two monitors and load the theme accordingly. However, it seems that this HDMI-2 didn't link to Dell machine, somehow it shares HDMI-3 with that external monitor. This is why both monitors show the same screen. I can't debug futher than this.

A few other tests I made so far

  1. I used an none 4k external monitor and connect it to Dell machine, it works okay.
  2. If I choosed to use Dell 7400 machine with that 4k external monitor, it also works fine.

Difficulties I met

So far I am not sure which part is in fault, and I just raise an issue to see if anyone encounter the similar problem. Are there any workaround with this? Thanks.

Steps to reproduce

  1. Use a Dell All-In-One machine and install linux mint 21, lightdm, and web-greeter. use HDMI cable to connect an external 4k monitor.
  2. in the theme selection, use dracula theme.
  3. restart lightdm and both monitors will show the secondary screen.

Expected behavior

The primary monitor will show index.html and secondary monitor will show secondar.html.

Screenshots

If applicable, add screenshots to help explain your problem.

@jgao1025 jgao1025 added the bug Something isn't working label Aug 21, 2023
@JezerM
Copy link
Owner

JezerM commented Mar 14, 2024

Hi, sorry for the very late response, I was busy on personal stuff.

So, this means that both monitors show the same screen, right? Are they being duplicated, such the mouse is seen in both monitors? If so, maybe this is an xrandr/X11 monitor setup issue, which I don't know a lot about.

@jgao1025
Copy link
Author

@JezerM Thanks for the reply. Yep, I guess there would be something wrong with the X11 monitor but I am unable to continue work on/debug that as I changed my job.

Thanks and I will close this ticket.

@jgao1025 jgao1025 closed this as not planned Won't fix, can't repro, duplicate, stale Jul 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants