Get the startup time of your Linux machine with systemd.

Posted: January 4, 2016. At: 3:20 PM. This was 2 years ago. Post ID: 8624
Page permalink.
WordPress uses cookies, or tiny pieces of information stored on your computer, to verify who you are. There are cookies for logged in users and for commenters. These cookies expire two weeks after they are set.

The systemd-analyze command will print the time taken for the system to boot up. This separates the time for the kernel and the userspace environment.

[email protected]:~# systemd-analyze 
Startup finished in 4.728s (kernel) + 28.339s (userspace) = 33.068s

This command will get the date and time from the Google website using curl.

[email protected]:~$ curl -s --head | grep ^Date: | sed 's/Date: //g'
Sat, 26 Dec 2015 04:46:13 GMT

To take a screenshot of the desktop, use this command.

[email protected]:~$ import +repage -window root scrot_$(date +%Y%m%d%H%M%S).png

Now we can list the directory and see the screenshots we took.

[email protected]:~$ ls scrot*
scrot_20151231111137.png  scrot_20151231111149.png

No comments have been made. Use this form to start the conversation :)

Leave a Reply