Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 11394

Summary: Expect password change fails
Product: [Retired] Red Hat Linux Reporter: Tim Jung <tjung>
Component: tcltkAssignee: Jens Petersen <petersen>
Status: CLOSED DUPLICATE QA Contact:
Severity: high Docs Contact:
Priority: medium    
Version: 6.1   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2000-05-15 13:52:35 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tim Jung 2000-05-12 21:54:44 UTC
I can not get Expect to do the example script from the O'Reilly "Exploring
Expect" book, where it changes the password. The example is on page #5.

It won't run reliable, and about 95% of the time it just hangs when you
run the script as root.

#!/usr/bin/expect -f
# wrapper to make passwd(1) be non-interactive
# Usage: chpassword user newpassword
spawn passwd [lindex $argv 0]
set password [lindex $argv 1]
expect "password:"
send "$password\r"
expect "password:"
send "$password\r"
expect eof

Comment 1 Jeff Johnson 2000-05-15 13:52:59 UTC
*** This bug has been marked as a duplicate of 1195 ***