ssh init should only output one line if not to be run

Bug #34265 reported by hackel
10
Affects Status Importance Assigned to Milestone
openssh (Ubuntu)
Fix Released
Wishlist
Colin Watson

Bug Description

/etc/init.d/ssh should not output two lines if ssh is not supposed to load (/etc/ssh/sshd_not_to_be_run exists).

Trivial patch is below. It occurs to me, however, that this should be set in /etc/default/ssh like most other packages do, instead of using the sshd_not_to_be_run file. Should forward this idea to debian upstream.

Also, is it really necessary to issue the warning message when ssh is configured not to run? I don't think so.

--- ssh-orig 2006-03-09 20:04:26.000000000 -0600
+++ ssh 2006-03-09 20:17:22.000000000 -0600
@@ -17,3 +17,2 @@
     if [ -e /etc/ssh/sshd_not_to_be_run ]; then
- log_end_msg 0
        log_warning_msg "OpenBSD Secure Shell server not in use (/etc/ssh/sshd_not_to_be_run)"
@@ -41,4 +40,4 @@
   start)
- log_begin_msg "Starting OpenBSD Secure Shell server..."
        check_for_no_start
+ log_begin_msg "Starting OpenBSD Secure Shell server..."
        check_privsep_dir

Revision history for this message
Björn Torkelsson (torkel) wrote :

With the split of client and server in different packages sshd_not_to_be_run shouldn't be necessary anymore. If you don't want the server to be running, just don't install the server package.

Revision history for this message
hackel (hackel) wrote :

Unless you want to run it selectively or from inetd.

Revision history for this message
Björn Torkelsson (torkel) wrote :

Well, then you can just as well use update-rc.d, or as it suggests sysv-rc-conf or bum, or any other runlevel editor, to remove the rc*.d links.

Revision history for this message
Colin Watson (cjwatson) wrote :

Notwithstanding the various sensible comments that have been made about removing openssh-server or using a runlevel editor instead, I did a better job at converting to LSB init script functions in openssh 1:4.6p1-1 which no longer has this output bug; that's now on its way into Gutsy.

Changed in openssh:
assignee: nobody → kamion
status: Unconfirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.