How To Take Screenshot Ubuntu Login Screen

Опубликовано: 30 Май 2026
на канале: Fosslicious
257
7

1. Install imagemagick
2. Make file with the name screenshot.sh on Home directory
3. Copy this script:
chvt 7; sleep 5s; DISPLAY=:0 XAUTHORITY=/var/run/lightdm/root/:0 xwd -root -out ~/screenshot.xwd; convert ~/screenshot.xwd ~/screenshot.png; rm ~/screenshot.xwd
4. Change permission of screenshot.sh to "Allow Exceute as Program
5. Logout, and go to tty1 Command Line Interface(ctrl+alt=f1)
6. Login with your account, and type sudo ./screenshot.sh
Ussually after execute this script, you will back on GUI mode.
7. Finally, back to GUI mode(ctrl+alt+f7, maybe each computer has a different shortcut) and See the result image on Home directory.

Tutorial based on https://www.fosslicious.com/2018/05/t...