So, here are examples of more modern ways to do things that once would have been best with Expect:
- The Tcl ftp package - Sarnold Isn't wget a better solution ? See also Download Accelerator, tclcurl
- mail without smtp and smtp with attachments
- IMAP automation, pop3 example [1]
- the tcl telnet client
- SNMP, snmpget, ...: Scotty is such a wonderful thing
- usermod instead of passwd [What is usermod?]
- automating rsync tasks with using ssh as remote shell and configure passwordless public keys
- ...
"Others have given you answers to your immediate problem. I would suggest you look at cfengine as a longer term solution. The problem you described could have been trivially solved by adding a few lines to the cfengine master files at the policy server. On the next scheduled run, all the servers would have downloaded the new config file, seen the new instructions and implemented them." [Rework, explain what relevance cfengine has to tcl, expect, etc ...]
This page doesn't yet explain anything; it only alludes to ideas that those who already understand will recognize. Also, it should be noted that, while Expect isn't the preferred way in 2007 to automate FTP (for example), there are rare circumstances in which an expert might choose to use it.
Expect is still useful even with the above mentioned programs. If you want to automate the tasks these programs perform then Expect is still needed here.
