Dual monitor extended desktop in Lubuntu

After researching it thoroughly, here are the steps to achieve this (terminal commands in grey):

  1. xrandr -q (to display info about displays, including the names. Mine are VGA-1 and DVI-I-1, used below)
  2. xrandr –-output VGA-1 –-left-of DVI-I-1
  3. Right click on the taskbar (panel) and choose panel settings
  4. Enter the horizontal resolution of the left monitor in pixels in the margin box (this will move the taskbar to the right screen), and make sure the bottom edges of the two monitors are lined up so the taskbar is visible on the right monitor.
  5. cd ~/
  6. cat > .xsessionrc (creates a text file named .xsessionrc that will persist your settings through restarts)
  7. Hit ctrl-D to exit text entry
  8. arandr (If not installed, sudo apt-get install arandr)
  9. Adjust monitors position, apply and save layout
  10. Open the layout file and copy the contents, then close
  11. gedit .xsessionrc
  12. xrandr –-output VGA-1 –-left-of DVI-I-1
  13. Paste contents previously copied
  14. Save and close
  15. Restart machine!

I follow the steps in Lubuntu help wiki. https://help.ubuntu.com/community/Lubuntu/MultiDisplay

1.Install Arandr using command line sudo apt-get install arandror using software center.

  1. Lubuntu menu > Preferences > Arandr (You have to plug second monitor before start the application)

  2. Go to Output menu and activate second monitor

  3. Apply settings


I found Nate's solution only works for that user's session.

This seems to work for all users. YMMV

Having derived a working xrandr from using the arandr utility

sudo apt-get install arandr

I hacked this bit of advice here on the forum :-)

sudo vi /usr/share/lightdm/lightdm.conf.d/20-lubuntu.conf

[Seat:*]
user-session=Lubuntu
# for your login screen, e.g. LightDM (Ubuntu 11.10) or GDM (11.04 or earlier)
display-setup-script=/home/mark/.screenlayout/asus.sh
# for your desktop session
session-setup-script=/home/mark/.screenlayout/asus.sh

chmod a+x /home/mark/.screenlayout/asus.sh

The /home/$USER/.screenlayout/ was the default save location for "arandr" which I recycled :-)


lubuntu 14.04.5

mark@asus-work:~$ lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 16.04.1 LTS Release: 16.04 Codename: xenial