-
How to automatically set password for user knoppix.
Hello, I have a bash script named newpw I got from another forum:
it executes as newpw knoppix 123456 where 123456 is the new password
#!/bin/bash
# \
exec expect -f "$0" ${1+"$@"}
set password [lindex $argv 1]
spawn passwd [lindex $argv 0]
expect "assword:"
send "$password\r"
expect "assword:"
send "$password\r"
expect eof
It seems to execute OK when I chmod to 777 newpw. However the new password is not taking. When I try to ftp into the machine the only password that works is one I set up by executing passwd knoppix at the command line directly. Any ideas on how to get this to work? Thanks
Similar Threads
-
By polhen in forum General Support
Replies: 1
Last Post: 01-10-2009, 02:30 PM
-
By pau in forum General Support
Replies: 2
Last Post: 05-09-2004, 01:28 PM
-
By cocojumbo in forum Hdd Install / Debian / Apt
Replies: 2
Last Post: 11-07-2003, 09:40 AM
-
By ian in forum Customising & Remastering
Replies: 2
Last Post: 08-21-2003, 08:54 AM
-
By ktheking in forum Customising & Remastering
Replies: 3
Last Post: 06-15-2003, 09:32 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules

5 Port Gigabit Unmanaged Ethernet Switch, Home Network Hub, Office Ethernet S...
$9.64

NETGEAR GS308EP Essential Series 8-Port Gigabit PoE+ Unmanaged Switch
$49.99

Cisco Catalyst 2960-48TT-L 48-Port Fast Ethernet Managed Rackmount Switch
$46.99

5Ports Gigabit Network Switch w/ 4 PoE+ Ports Total 52W each port 30W Plug&Play
$31.99

TP-Link TL-SG105 5-Port Gigabit Ethernet Unmanaged Metal Desktop Network Switch
$19.99

10-Port Gigabit PoE Network Switch with 8 PoE+ Ports with 2 Combo SFP Slots 125W
$39.99

TP-Link TL-SG105, 5 Port Gigabit Unmanaged Ethernet Switch, Network Hub, Ethern
$15.25

Arista DCS-7010T-48-R 48P 1GbE 4P 10GbE SFP+ RA Switch with rack mounts
$69.00

D-Link DGS-1210-28P 28-Port PoE Gigabit Web Smart Switch With Cord
$49.99

Linksys LGS328MPC 24-Port Managed Gigabit PoE+ Switch with 4 10G SFP+ Uplinks
$224.95