Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
single passwd command
Name: John Date: August 4, 2002 at 14:48:54 Pacific
Comment:
is it possible to do a single password command in linux like in unix
echo password | passwd username --stdin
I tried compiling expect but it didn't like that to much. does anyone know of a way to do this
Name: junky_toof Date: August 5, 2002 at 01:25:03 Pacific
Reply:
Hi John.
You can get the latest version of expect and tcl/tk in a ready to install package at www.activestate.com. Very simple. Just uninstall your old tcl/tk/expect junk first to save yourself some hassle.
#!/usr/bin/expect
set pprpmt ".*asswor.*" set user [lindex $argv 0]
proc newpass {} { puts -nonewline stdout "New Password: " flush stdout stty -echo if {![catch {set p [gets stdin]}]} { stty echo return $p } return 1 }
Summary: reboot your machine and during start up when grub bootloader options appear select linux and prees "e" . Now select line containing kernel options and append "single" at end of line. i.e you are going...
Summary: All you need to do is bootup the system in single user mode and then use the passwd command to change the root (or any other) password. The method to boot into single user mode varies depending on th...
Summary: At Lilo prompt type linux single (if linux is the name for your linux boot image). The system will boot without asking for password. change password using passwd command. Reboot in normal mode and u...