[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[cobalt-users] newbie SSH problem
Hi all
I bit the bullet and decided to install ssh onto my paq3. I did as was told
by cobalt this was:
tar -xzf ssh-1.2.27.tar.gz
cd ssh-1.2.27
./configure
make
make install
Copy the following contents into a file named /etc/rc.d/init.d/sshd
------------- Copy below this line ---------------
#!/bin/sh
# Source function library.
. /etc/rc.d/init.d/functions
# Source networking configuration.
. /etc/sysconfig/network
# Check that networking is up.
[ ${NETWORKING} = "no" ] && exit 0
[ -x /usr/local/sbin/sshd ] || exit 0
# See how we were called.
case "$1" in
start)
echo -n "Starting sshd: "
daemon sshd
echo
touch /var/lock/subsys/sshd
;;
stop)
echo -n "Shutting down sshd: "
killproc sshd
echo
rm -f /var/lock/subsys/sshd
;;
status)
status sshd
;;
restart)
$0 stop
$0 start
;;
*)
echo "Usage: sshd {start|stop|restart|status}"
exit 1
esac
exit 0
------------- Copy above this line ---------------
To start sshd automatically when the server is booted, run the following
commands:
chmod +x /etc/rc.d/init.d/sshd
ln -s /etc/rc.d/init.d/sshd /etc/rc.d/rc3.d/S85sshd (i have not done this
yet)
all seemed ok
but when i tried to run the script as root i got these messages
[root@dns init.d]# ./sshd test
Usage: sshd {start|stop|restart|status}
[root@dns init.d]# ./sshd status
sshd dead but subsys locked
[root@dns init.d]# ./sshd status
sshd dead but subsys locked
[root@dns init.d]# ./sshd start
Starting sshd: sshd./sshd: sshd: command not found
Where have i gone wrong?
Regards
Andy Wallace