Announcement

Collapse
No announcement yet.

Menu bar disappears into disconnected external monitor never to be found again

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Menu bar disappears into disconnected external monitor never to be found again

    Hello everyone,

    I'm happily using Kubuntu since years. I'm currently using Kubuntu 22.04 on an old but robust Lenovo T460P.

    Recently, I purchased an external monitor (Gigabyte M28U) with the hope of using it both as external monitor for my laptop and occasionally to play video games. But the experience with my laptop has been a bit disappointing and today, I ran in more trouble than usual, so I decided to ask for advice because it seems that my naive expectation that I could simply plug and unplug this monitor to my laptop using the HDMI cable to use it or not use it, was wrong.
    First, there has been many instances where I would plug the external monitor to my laptop using the HDMI, and the screen of the external monitor, initially black, would display a message saying "HDMI2 No signal", which I find a bit funny because it obviously received a signal since it decides to talk to me, but not "enough signal" to decide to display something useful. So for a while, I gave up the idea of using it and I kept the HDMI cable unplugged. But this morning, I felt adventurous and I tried again. It seemed to work. I had to go in the "Settings > Display and Monitor > Display configuration" and using the mouse, drag the laptop screen such that the laptop screen would be below the external monitor like this:


    But then, I noticed that the menu bar (the horizontal black bar in the picture) had been moved from my laptop screen to the screen of the external monitor, which is inconvenient for me as the top of my laptop covers the lower part of my external screen. I tried to change this, by changing things in the setting, and I think that one of the thing I tried was to change the status of the "Primary" field in the above screen-shot. I don't remember if I put the external monitor as primary or if I made my laptop screen non-primary, but the surprising thing is that it worked. The menu bar was back were it belonged: on my laptop screen. I know that it seems counter-intuitive, as you would assume that the menu bar goes where the primary screen is, but I'm pretty sure that this is what happens. With hindsight, I realize that I shouldn't have done that as it gave the wrong impression to the OS that I wanted the external monitor to be the primary screen (I feel dumb writing this as, it's literally what I selected, but until this point, I had never thought too much about what is a primary screen and what happens if you disconnect the primary screen). And then a bit later, I went one step further in my idiotic experimentation and I disconnected the HDMI cable of the external monitor because I wanted to work on my sofa.
    And that's the moment things started to go really sideways. Subverting my expectations, the menu bar (standing on my laptop screen until this very moment) vanished. I tried to see what was happening in the settings, but now, there seemed to be only one screen, and there wasn't any option to set it as primary. It felt like the menu bar had stayed with the external monitor. This impression was reinforced when I reconnected my laptop to the screen and saw the menu bar come back. Then I tried to restart the computer and change settings again, but it just became worse. At some point, I restarted the computer and now the external monitor was mirroring the laptop screen but neither had the menu bar. I then disconnected it again, and (following one of ChatGPT's pieces of advice), I did a right-click on my desktop > "Add pannel" and I added a new menu bar. But it didn't have all the icons I had added before and its size was slightly different which makes me believe that it's not my good old menu bar back where it belonged but a new one. At that point, I wondered what would happen if I would connect again my external screen to the laptop. I plugged the HDMI cable, and nothing happened, but I saw that the monitor was again visible in the display settings, but not "Enabled". So I checked the "Enabled" box and for a few seconds, the external monitor seemed to work well except that it had my old menu bar attached to it, even if the new one was still on my laptop screen. And then after a few seconds, the external monitor turned black again and showed me its favorite message ("HDMI 2 No signal") before going completely black.

    I researched a bit this forum and I found this post from Schwarzer Kater:
    https://www.kubuntuforums.net/forum/...399#post678399
    but before trying out this
    "
    to additionally use the Kubuntu Backports and Kubuntu Backports PPAs for Kubuntu 22.04 LTS, because then you will get Plasma 5.27.x and in Plasma 5.27.x the multi monitor support has been vastly improved compared to Plasma 5.24.x
    If interested see e.g. KDE Plasma 5.27.11 available in Kubuntu Backports Extra.​
    "
    I wanted to ask it sounds reasonable and if people have advice, because I'm a bit afraid of doing more mess. All I want is an external screen that I can add and remove by plugging a cable. It doesn't seem like an unreachable goal. I know that it's possible because it's working like this in my office where I have Ubuntu 20.04 (I'm not allowed to have Kubuntu) and a different external monitor.

    Best,

    #2
    No attached images/pictures.
    Windows no longer obstructs my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment


      #3
      Originally posted by Snowhog View Post
      No attached images/pictures.
      Thanks for your reply Snowhow. I'm a bit confused, as I can see the screenshot in the middle of my message. Do you mean that I shouldn't post any picture (maybe it goes against some rules)? Or you cannot see the picture in my previous message? Or do you mean that I should post additional pictures?

      Comment


        #4
        No, no rules to go against. I meant that I don't see the images in your post. This is what I see:

        Click image for larger version

Name:	Screen Shot 2024-07-07 at 2.58.49 PM.png
Views:	73
Size:	304.6 KB
ID:	681058
        Last edited by Snowhog; Jul 07, 2024, 02:03 PM.
        Windows no longer obstructs my view.
        Using Kubuntu Linux since March 23, 2007.
        "It is a capital mistake to theorize before one has data." - Sherlock Holmes

        Comment


          #5
          Click image for larger version

Name:	Display_settings_07072024_1.png
Views:	71
Size:	179.4 KB
ID:	681062
          Very strange. Because I can still see it in my former message. So I post it again and we'll see if it's visible again this time. Like last time I clicked on the "Upload Attachments", then selected the image (.png file), then I selected Medium, and the image seemed to have been added to my message (it's there in the preview).

          Comment


            #6
            Your TV is set as primary, and it it doesn't have a panel

            So, when you disconnect it, the laptop becomes Primary. Which then wants to match what Settings or layout your previous Primary had. Thus, no panel.

            So, while both screens are connected, set laptop as primary. Then go into edit mode by right clicking on the panel or somewhere on the desktop.

            From there you can drag the panel to the desired monitor and location, though it might not be 100% obvious, and it can sort of stick when moving between screens.




            Comment


              #7
              Thank you for your reply claydoh.

              I tried:
              Click image for larger version

Name:	Display_settings_08072024_1.png
Views:	70
Size:	166.1 KB
ID:	681066
              and
              Click image for larger version

Name:	Display_settings_08072024_3.png
Views:	70
Size:	180.0 KB
ID:	681067
              and it looks like it's working for a few seconds:
              Click image for larger version

Name:	Display_settings_08072024_4.jpg
Views:	70
Size:	51.5 KB
ID:	681068
              but then after a few seconds, it produces an error and the external monitor is disabled again:
              Click image for larger version

Name:	Display_settings_08072024_2.png
Views:	68
Size:	293.7 KB
ID:	681069
              I think that it's because there are two sets of settings entering in conflict. Any chance I could use the terminal to fix this?

              Attached Files

              Comment


                #8
                Are you seeing the Keep or Revert dialog box pop up? The changes will revert automatically if not accepted after a number of seconds. Maybe it is underneath a window or something, if you are not.

                Click image for larger version

Name:	Screenshot_20240708_041206.png
Views:	79
Size:	27.1 KB
ID:	681071

                You might try disconnecting the TV, then deleting ~/.local/share/kscreen/ which is where the screen setups ans settings are saved. Log out, or reboot, and start from scratch. I can't explain the crash, other than maybe a corrupted config file or something.

                I am not sure if it matters here, but as you have a 30hz TV and a 60Hz laptop screen, you may benefit from trying a Wayland session, which is able to keep both screens at their native refresh rate -- the laptop is probably dropping down to 30 when the TV is connected, which is normal for xorg. Something to try, maybe, once your layout is all fixed.

                Do note that the pauses and blank screens when switching connections is fairly normal. The HDMI needs tio detect the cable, power on, find a signal, and then the correct resolution and refresh rates, on top of whatever layout was used for these. Even my relatively recent-ish i5 10th gen laptop takes a moment to wake up.
                Last edited by claydoh; Jul 08, 2024, 02:13 AM.

                Comment


                  #9
                  Thanks a lot for your reply claydoh and sorry for the delay of mine. I had guests yesterday and I didn't have time to turn on my laptop after work.

                  I don't remember seeing this Keep or Rever dialog box in this specific instance, but it might have been hidden somewhere. I unplugged the HDMI cable of the external monitor from my computer and I renamed the file you mentioned (~/.local/share/kscreen) to the same with _old appended. Then I turned off my computer, plugged the HDMI cable, and turned the laptop on again. The two screens were now working but the external monitor still had my old original menu bar (it has slightly different items). This time, the second screen didn't turn off and so far it is working. I removed the menu bar from the screen of the external monitor, and changed the way the screens are (virtually) positioned next to each other and it seems that it is working.

                  I will try this Wayland session that you suggest, next time I login (apparently it's a login parameter from what ChatGPT tells me).

                  By the way, do you think I should also follow the advice of Schwarzer Kater:
                  https://www.kubuntuforums.net/forum/...399#post678399
                  "
                  to additionally use the Kubuntu Backports and Kubuntu Backports PPAs for Kubuntu 22.04 LTS, because then you will get Plasma 5.27.x and in Plasma 5.27.x the multi monitor support has been vastly improved compared to Plasma 5.24.x
                  If interested see e.g. KDE Plasma 5.27.11 available in Kubuntu Backports Extra.​
                  "​
                  ?

                  Anyway, thank you very much for your help and responsiveness. This forum is amazing. Have a nice day.

                  Comment


                    #10
                    Originally posted by Robert24 View Post
                    from what ChatGPT tells me
                    Oh mylanta. LLM s have a hard time keeping up with the constant changes in Linux as well as user-supplied incorrect or non-working answers to things that clog search results.. Tread carefully.

                    If you want to add those PPAs to get Plasma 5.27, why not just upgrade to 24.04 LTS instead? Good support is more than an updated desktop GUI, much of it comes from the underhood updates.

                    it seems that your laptop wants to advertise the external as the primary, maybe. At least when it detects two screens during boot. I might have suggested not plugging it in until after logging in.
                    The use of the older panel layout and setting the larger screen as primary probably indicates that it did set things up from scratch.
                    Last edited by claydoh; Jul 10, 2024, 07:03 PM.

                    Comment


                      #11
                      Originally posted by claydoh View Post
                      If you want to add those PPAs to get Plasma 5.27, why not just upgrade to 22.04 LTS instead? Good support is more than an updated desktop GUI, much of it comes from the underhood updates.
                      I guess you mean 24.04, right? It's true, maybe I should do it indeed. I found this page by googling:
                      https://help.ubuntu.com/community/NobleUpgrades/Kubuntu

                      Comment

                      Working...
                      X