title: How to take "Screenshot Of Terminal Commands" on ubuntu server?
body: <p>I need to grab the screenshot of commands run on the Ubuntu Server 12.04, like</p>
  
  <pre><code>~$ id
  uid=0000(local) gid=0000(localo) groups=1000(local)
  ~$ uname -a
  Linux local 3.2.0-54-generic #82-Ubuntu SMP Tue Sep 10 20:08:42 UTC 2013  x86_64 GNU/Linux
  </code></pre>
  
  <p>and other few commands.</p>
  
  <p>I can't find anything which does this job. I tried different tools found at <a href="https://wiki.archlinux.org/index.php/taking_a_screenshot" rel="nofollow">ArchWiki</a> but all of them give black screenshot as output. Like,</p>
  
  <p>I'm tried using Xvfb <code>~$ Xvfb :1 -screen 0 1360x960x24 -extension RANDR &amp;</code> to create the display and import tool from imagick <code>~$ DISPLAY=:1 import -window root -quality 100 /var/www/html/output/screenshot.png</code>to capture screenshot but it didn't work. </p>
  
  <p>I understood after some time it'll not work as the display is empty and black image was correct output.</p>
  
  <p>Then I found <a href="https://github.com/mitotic/graphterm" rel="nofollow">GraphTerm</a> a way to access the terminal in the headless browser and capture the screenshot but it didn't allow to send commands from terminal to the browser but it does says that it creates websocket connection between terminal and browser instance. These are the commands I used to do this:</p>
  
  <pre><code>~$ sudo Xvfb :1 -screen 0 1360x960x24 -extension RANDR &amp;
  ~$ gtermserver --terminal --auth_type=none &amp; // Starts the graphical server in new browser
  ~$ DISPLAY=:1 chromium-browser http://localhost:8900/local/new/?cauth=1753c05fd738 &amp;
  ~$ DISPLAY=:1 import -window root -quality 100 /var/www/html/output/screenshot.png
  </code></pre>
  
  <p>Is there any other way to do this? Or I'm doing anything wrong in these steps.</p>