I'm using Ubuntu 12.04 . If more information is needed, please tell me. I Tried some guides to cature my login screen:
How can I take a screenshot of the login screen?
http://www.howtoforge.com/how-to-take-a-screenshot-of-your-login-screen
I tried the first one, but after running:
$ sudo bash /tmp/shot.sh >/tmp/shot.xwd
I'm getting this:
No protocol specified
No protocol specified
xwd unable to open display ':0'
and i'm getting an xwd file in my tmp folder. running the other commands giving errors.
tried the second one, after running:
chvt 8; sleep 5; XAUTHORITY=/var/gdm/:0.Xauth DISPLAY=:0.0 import -window root /tmp/gdm-login-shot.png
I got:
No protocol specified
No protocol specified
import: unable to open X server ':0.0' @ error/import.c/ImportImageCommand/366
Many Thanks for helping (:
EDIT to vine_user: here the output from the terminal-I cacked it from within the system while I'm looged in:
ubuntu@PrecisePangolin:~$ echo 'sleep 5; DISPLAY=:0 XAUTHORITY=/var/run/lightdm/root/$DISPLAYDISPLAY xwd -root' > /tmp/shot.sh
ubuntu@PrecisePangolin:~$ sudo bash /tmp/shot.sh >/tmp/shot.xwd
bash: /tmp/shot.xwd: Permission denied
ubuntu@PrecisePangolin:~$ sudo su
root@PrecisePangolin:/home/ubuntu# sudo bash /tmp/shot.sh >/tmp/shot.xwd
No protocol specified
No protocol specified
xwd: unable to open display ':0'
root@PrecisePangolin:/home/ubuntu#
EDIT 2!: HERE IT IS!:
just uploading-this uploadong site is better than other iuset to use (: :
Step1:
Make /tmp/shot.sh using this command:
You may change the seconds of
sleep
suitably.Step2:
Login to the text mode by pressing Ctrl+Alt+F1.
Step3:
Execute this command;
Step4:
Return to the GUI mode by pressing Ctrl+Alt+F7.
Step5:
Logout by normal way. While you can see login screen, wait for some seconds.
Step6:
Login by normal way. And execute this command in terminal;
(you need to install
imagemagick
, if you don't have installed it yet)So, you can check the picture using this command;
Reference: http://ptspts.blogspot.jp/2010/02/how-to-create-screen-shot-of-gdm-login.html
In 12.04, it differs in using lightdm.
The answer by vine_user gave me a Black image so I modified it as below and got it correctly
echo 'chvt 7; sleep 10; DISPLAY=:0 XAUTHORITY=/var/run/lightdm/root/$DISPLAY xwd -root' > /tmp/shot.sh
Logout and login to text mode (Ctrl+Alt+F1)
Execute
sudo bash /tmp/shot.sh >/tmp/shot.xwd
Return to GUI mode by pressing Ctrl+Alt+F7 (sometimes it is Ctrl+Alt+F8 - if it is your case then modify the fisrt command by replacing chvt 7 with chvt 8
Use the command
convert /tmp/shot.xwd ~/Desktop/shot.png
to convert the /tmp/shot.xwd to ~/Desktop/shot.png (imagemagick is required)Here is the screenshot of my login screen
Try running the following command...
... and taking a screenshot of that.
I have Written a small script to make it simple. I am sharing it here.
Install Step 1: Save this code into your home directory a file named loginsceenshot.sh
Install Step 2 Hit Ctrl + Alt + F1, login, and type this.
Use Step 1 Hit Ctrl + Alt + F1, login, and type this.
Use Step 2 Hit Ctrl + Alt + F7, goto Login page and wait for 15 sec.
Use Step 3 Open you home directory and look of ScreenShot.png