Démarrage de trois daemons mongodb impossible

Linux bannord 3.16.0-4-amd64 #1 SMP Debian 3.16.36-1+deb8u1 (2016-09-03) x86_64 GNU/Linux
8.6

Bonjour,

J’ai installé mongodb et je dois démarrer trois daemons ( 3 serveurs ayant chacun un fichier de configuration différent) pour automatiser le lancement au démarrage sans aucune intervention.

La mise en place du daemon pour la première instance fonctionne.

script /etc/init.d/mongod1
curl -L https://raw.githubusercontent.com/mongodb/mongo/master/debian/init.d -o mongod1

chmod a+x mongod1
cp  mongod1 mongod2
cp  mongod1 mongod3 

for i in mongod1 mongod2 mongod3
do
sed -i -e "s/usr\/bin\/mongod/opt\/mongodb\/bin\/mongod/g" $i
sed -i -e "s/NAME=mongod/NAME=$i/g" $i
sed -i -e "s/etc\/mongod.conf/etc\/$i.conf/g" $i
done

systemctl daemon-reload

for i in mongod1 mongod2 mongod3
do
update-rc.d $i defaults
update-rc.d $i enable
service $i start
done

seul mongod1 se lance automatiquement au démarrage.
les deux autres services restent inactives et nécessitent un démarrage manuel pour se lancer.

d’ailleurs : update-rc.d mongod2 defaults affiche le message :

insserv: script mongod2 : service mongod already provided!
insserv: exiting now!
update-rc.d: error: insserv rejected the script header

Pourriez-vous m’aider à démarrer les 3 daemons au démarrage du serveur ?

Merci d’avance.