0

I'm using Lubunu 20.04 on a Lenovo X201 laptop. Suppose I do the following:

  1. Log in (to a GUI desktop session).
  2. Connect an external monitor via VGA
  3. Used lxrandr to only use the external monitor
  4. Physically disconnect the VGA connector

At this point, the laptop's monitor is dark. Now, Lubuntu - as installed - does not recognize Fn+Monitor Switch keys / does not do anything useful with them. So, I switch to another VT with Ctrl+Alt+Fn (say F2).

I now want to use xrandr to have the laptop display come back on when I switch VT's.

  1. Is that possible?
  2. When I try to make this work - and I'm no xrandr expert - I fail :-(

Specifically, I tried:

xrandr -d :0 --output LVDS-1 --primary

and it does nothing, and

xrandr -d :0 --output LVDS-1 --auto

gets me aBadMatch (invalid parameter attributes) error. But I don't understand what that means exactly.

Related:

einpoklum
  • 871
  • 3
  • 10
  • 28
  • I used an x201 (lenovo thinkpad x201 (i5-m520, 4gb, i915)) in my testing of Lubuntu (and some other flavors) and had no issues like you describe, however I would not have used lxrandr (it's a LXDE tool where Lubuntu has used LXQt for 5 releases now). In my own play I never had issues with the Fn keys not allowing me to switch between internal & external (my testing was QA only, which isn't the same as using it longer-term though) – guiverc Oct 30 '20 at 01:00
  • @guiverc: I actually just upgraded my Lubuntu version to a one using LXQt. What's the equivalent of lxrandr now? Also, lxrandr does work; what's the problem with it? – einpoklum Oct 30 '20 at 13:48
  • Lubuntu does not support the upgrade from 18.04 to 20.04, except through install. Refer to the release notes (https://lubuntu.me/focal-1-released/) where you'll read "Note, due to the extensive changes required for the shift in desktop environments, the Lubuntu team does not support upgrading from 18.04 or below to any greater release. Doing so will result in a broken system. If you are on 18.04 or below and would like to upgrade, please do a fresh install." – guiverc Oct 30 '20 at 21:06
  • lxrandr is no longer a Lubuntu tool (not in releases post 18.04; it was ours till that release) so we don't test with it. The modern Lubuntu way is via LXQt tools, ie. the intended method is shown in the manual https://manual.lubuntu.me/stable/3/3.2/3.2.10/monitor_settings.html – guiverc Oct 30 '20 at 21:07
  • @guiverc: Ok, fair enough, but are you saying that if I had used the lxqt tool, this would not have happened? – einpoklum Oct 30 '20 at 21:13
  • I don't know, as it was a LXDE tool, no testing was done & I don't recall what lxrandr writes; looking at https://packages.ubuntu.com/focal/lxrandr I see no problem with install. I don't know sorry. Most testing on the x201 was without external monitor, but it was tested with it & I used fn keys as I recall like other thinkpads (testing concentrates on provided tools, esp. LXQt tools as per manual etc) – guiverc Oct 30 '20 at 21:27
  • @guiverc: The Fn keys never worked for me - neither with LXDE nor with LXQt. I wasn't even asking about those... – einpoklum Oct 30 '20 at 21:45
  • FYI: I booted Lubuntu 20.04.1 up on the x201 (live) and yeah the fn-monitor no longer works :( not sure when that happened (possibly between 20.04 & 20.04.1; as stated most laptop testing is only laptop monitor). Also you do realize xrandr assumes X is active, ie. there is no X in text terminals (outside of virtual terms opened within X) – guiverc Oct 31 '20 at 01:11
  • @guiverc: X is active regardless of the terminal. There's no problem - generally - running X programs from terminals on other VTs or other machines. You just tell them which display to use with DISPLAY in the environment. xrandr also takes a -d switch. – einpoklum Oct 31 '20 at 07:55

0 Answers0