your problem is one missing :
and .
In your command where you specifiy the display -i 0:0
avconv -f x11grab -s hd720 -r 30 -i 0:0 sample.mov
It should be -i :0.0
avconv -f x11grab -s hd720 -r 30 -i :0.0 sample.mov
You can always double check by looking at your environmental variable for display in your terminal.
echo $DISPLAY
:0.0
To understand what the display variable means have look at this post.
https://pangea.stanford.edu/computing/unix/xterminal/xclients.php
-display hostname:n.m
Where hostname is the network hostname, qualified with domain name as
needed (or use the IP address directly); n is the display number on
that host (usually 0); and m is the screen number on that host
(usually 0). For example, if you am logged into the console on the
workstation eluard and want to run the xload client on pangea with the
output window coming back to eluard, you could start this program on
pangea with the option:
xload -display eluard:0.0
localhost is assumed if the hostname is omitted localhost:0.0
is the same as :0.0
echo $DISPLAY
give you? – gertvdijk Apr 02 '13 at 20:04