1

I followed this guide on how to take a screenshot for the login screen.

However in Ubuntu 20.04 it doesn't work, I get the following error:

xwd: unable to open open display ':0'

Below is the script I'm using (extracted from the guide with a modified chvt)

chvt 1;
sleep 5s;
DISPLAY=:0 XAUTHORITY=/var/lib/gdm/:0 xwd -root -out ~/screenshot.xwd;
convert ~/screenshot.xwd ~/screenshot.png;
rm ~/screenshot.xwd
5
  • I only have gdm in a 20.10 install but it would be login screen > vt3 > login > chvt 7 > goes back to login screen
    – doug
    Dec 17, 2020 at 17:52
  • Seems not. chvt 7 goes to some weird version of the command line login screen. I have to use chvt 1 and also Ctrl + Alt + F1 goes to the login screen and not Ctrl + Alt + F7 Dec 17, 2020 at 17:55
  • I'd just use a virtual machine if I needed a screenshot of the login screen. It's not fancy, but it works. There are also a ton of ways to try here.
    – KGIII
    Dec 17, 2020 at 18:03
  • My machine is not powerful enough to run a VM, it brings my computer to a halt. I already tried the suggestions in that post, but I can't find any that work for 20.04, even the one at the bottom that says it works on 20.04 Dec 17, 2020 at 18:11
  • Did you try this one?? askubuntu.com/a/1237166/739431
    – PRATAP
    Dec 18, 2020 at 8:35

0

You must log in to answer this question.

Browse other questions tagged .