MongoDB service autostart failed on Ubuntu 18.04

Hi All,

We have install mongodb in Ubuntu 18.04 LTS. The system was working fine. mongodb service was auto started during reboot.

We ran
sudo mongod --repair , After this the mongod service is not autostarting and

  1. sudo systemctl enable mongod
  2. sudo systemctl start mongod is not working
    But When I execute sudo mongod --config /etc/mongodb.conf, Mongo db works well.

We want to autostart mongodb using systemctl. Kindly guide me to fix the auto start issue.

Regards,
Bala