Ask Your Question

Why still getting "Could not find init script or upstart conf file for 'sshd'

asked 2013-01-17 16:40:08 -0600

whiterabbit23 gravatar image

I did the Tutorial with the puppet book "Pro Puppet" and no trying to complete the ssh module section.

Unfortunately I still getting the error " Could not find init script or upstart conf file for 'sshd'" but did everything like in the book.

What does this error mean ?

My sshd_config file is under modules/ssh/files

My Configs are:

class ssh::config {
file { $ssh::params::ssh_service_config:
    ensure => present,
    owner => 'root',
    group => 'root',
    mode => 0440,
    source => "puppet:///modules/ssh/sshd_config",
    require => Class["ssh::install"],
    notify => Class["ssh::service"],


class ssh {
include ssh::params, ssh::install, ssh::config, ssh::service


class ssh ...
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2013-01-17 16:51:10 -0600

My suspicion is that the problem lies with your service resource.

service { $ssh::params::ssh_service_name:
    ensure => running,
    hasstatus => true,
    hasrestart => true,
    enable => true,
    require => Class["ssh::config"], 

You appear to be running Ubuntu but here you resolve your service variable to sshd

/(Ubuntu|Debian)/: {
    $ssh_package_name = 'openssh-server'
    $ssh_service_config = "/etc/ssh/sshd_config"
    $ssh_service_name = 'sshd'

If I'm not mistaken, the service name for the ssh daemon on Ubuntu is ssh. Check /etc/init.d for a script named ssh and change your conditional logic to match if that's the case.

edit flag offensive delete link more

answered 2013-01-17 17:45:33 -0600

whiterabbit23 gravatar image

WOW , thanks a lot !!!!!! You did solve my problem I'm working on since 5 Hours of pain.


I also have to say, that the Book "Pro Puppet", is the worse teaching book I ever used, cause of this ( where they say sshd ) I spend so much time on this ...

And this is not the first error in the book ...

edit flag offensive delete link more


You're welcome. I'm sorry that Pro Puppet led to that frustration. It's gotten a bit out of date, as paper tends to do. If you're looking ...(more)

ryanycoleman gravatar imageryanycoleman ( 2013-01-17 18:35:20 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2013-01-17 16:40:08 -0600

Seen: 7,011 times

Last updated: Jan 17 '13