Is there a shell command in Linux to get the time in milliseconds?
Nano is 10−9 and milli 10−3. Hence, we can use the three first characters of nanoseconds to get the milliseconds:
date +%s%3N
From man date:
%N nanoseconds (000000000..999999999)
%s seconds since 1970-01-01 00:00:00 UTC
Source: Server Fault's How do I get the current Unix time in milliseconds in Bash?.