Using Expect script to automate SSH logins and do routine tasks accross multiple hosts

If you maintain several Linux hosts sometimes it is easier if you can automate logins and do routine tasks unattended. In this blog we will show you how to accomplish this using Expect scripts.