On Wed, 2006-04-26 at 14:58 -0700, Steve Lamb wrote:
> Steve Lamb wrote:
> > Joey Hess wrote:
> >> Many embedded systems don't have swap. ssh in inetd worked ok last time
> >> I used it as long as speed was not important.
>
> > Thanks, Joey, I'll give it a whirl later on and let everyone know. Was
> > just hoping that it was a question on dpkg-reconfigure that I was missing.
>
> Ok, the directions that Greg gave were spot on with the exception of the
> missed -i at the end of the inetd.conf line. Also I needed to get rid of the
> rc.d symlinks with a quick:
> cd /etc
> rm rc*.d/*ssh
update-rc.d -f ssh remove
has the same effect, please remember that *IF* you upgrade you ssh
installation those links will com back with either method.
But you see, if the file "/etc/ssh/sshd_not_to_be_run" exists the init.d
script should just exit. It is why I didn't mention doing that removal.
Here is the start portion of the init.d script:
case "$1" in
start)
check_for_no_start
check_privsep_dir
echo -n "Starting OpenBSD Secure Shell server: sshd"
start-stop-daemon --start --quiet --pidfile /var/run/sshd.pid --exec /usr/sbin/sshd -- $SSHD_OPTS
echo "."
;;
The Function check_for_no_start
check_for_no_start() {
# forget it if we're trying to start, and /etc/ssh/sshd_not_to_be_run exists
if [ -e /etc/ssh/sshd_not_to_be_run ]; then
echo "OpenBSD Secure Shell server not in use (/etc/ssh/sshd_not_to_be_run)"
exit 0
fi
}
> Also somehow flubbed stopping sshd and restarting inetd and locked myself
> out. The funny part is that it reminded me I have ssh access to my machine's
> console so if it weren't for scp I could always just ssh to the console and
> take up no RAM regardless.
Never logout of said machine completely until you can login back in
Even if you stop ssh as a daemon you won't kill you current session.
--
greg, greg@gregfolkert.net
The technology that is
Stronger, better, faster: Linux
Attachment:
signature.asc
Description: This is a digitally signed message part