dpkg: error when installing mongodb on Ubuntu 18.04





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}







0















I am trying to install the newest version of mongodb in Ubuntu 18.04. When running the command sudo apt install -y mongodb I get the following errors. I think my question is similar to https://serverfault.com/questions/809925/dpkg-error-processing-package and How to debug dpkg configure error in subprocess post-installation?. However, I do not understand the solution since I am new to Ubuntu. What are the steps to solve this issue?




Error




See system logs and 'systemctl status mongodb.service' for details.
invoke-rc.d: initscript mongodb, action "start" failed.
● mongodb.service
Loaded: error (Reason: Invalid argument)
Active: failed (Result: exit-code) since Thu 2019-03-21 17:09:18 +0530; 26min ago
Main PID: 14453 (code=exited, status=1/FAILURE)

Mar 21 17:20:59 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:21:10 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:21:11 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:21:22 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:21:23 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:29:57 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:35:27 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:35:43 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:35:46 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
Mar 21 17:35:47 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
dpkg: error processing package mongodb-server (--configure):
installed mongodb-server package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of mongodb:
mongodb depends on mongodb-server (>= 1:2.4.1-2); however:
Package mongodb-server is not configured yet.

dpkg: error processing package mongodb (--configure):
dependency problems - leaving unconfigured
Processing triggers for libc-bin (2.27-3ubuntu1) ...
No apport report written because the error message indicates its a followup error from a previous failure.
Processing triggers for systemd (237-3ubuntu10.13) ...
Processing triggers for ureadahead (0.100.0-20) ...
Errors were encountered while processing:
mongodb-server
mongodb
E: Sub-process /usr/bin/dpkg returned an error code (1)



find /etc -name "mongod"




/etc/rc0.d/K01mongodb
/etc/rc2.d/S01mongodb
/etc/init/mongod.conf
/etc/mongodb.conf
/etc/mongod.conf
/etc/apt/sources.list.d/mongodb-org-4.0.list.save
/etc/apt/sources.list.d/mongodb-org-3.6.list.save
/etc/apt/sources.list.d/mongodb-org-3.6.list
/etc/apt/sources.list.d/mongodb-org-4.0.list
/etc/logrotate.d/mongodb-server
find: ‘/etc/ssl/private’: Permission denied
/etc/rc4.d/S01mongodb
/etc/systemd/system/mongodb.service
/etc/rc3.d/S01mongodb
/etc/rc1.d/K01mongodb
/etc/rc5.d/S01mongodb
find: ‘/etc/polkit-1/localauthority’: Permission denied
/etc/init.d/mongodb
find: ‘/etc/cups/ssl’: Permission denied
/etc/rc6.d/K01mongodb









share|improve this question





























    0















    I am trying to install the newest version of mongodb in Ubuntu 18.04. When running the command sudo apt install -y mongodb I get the following errors. I think my question is similar to https://serverfault.com/questions/809925/dpkg-error-processing-package and How to debug dpkg configure error in subprocess post-installation?. However, I do not understand the solution since I am new to Ubuntu. What are the steps to solve this issue?




    Error




    See system logs and 'systemctl status mongodb.service' for details.
    invoke-rc.d: initscript mongodb, action "start" failed.
    ● mongodb.service
    Loaded: error (Reason: Invalid argument)
    Active: failed (Result: exit-code) since Thu 2019-03-21 17:09:18 +0530; 26min ago
    Main PID: 14453 (code=exited, status=1/FAILURE)

    Mar 21 17:20:59 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:21:10 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:21:11 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:21:22 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:21:23 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:29:57 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:35:27 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:35:43 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:35:46 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    Mar 21 17:35:47 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
    dpkg: error processing package mongodb-server (--configure):
    installed mongodb-server package post-installation script subprocess returned error exit status 1
    dpkg: dependency problems prevent configuration of mongodb:
    mongodb depends on mongodb-server (>= 1:2.4.1-2); however:
    Package mongodb-server is not configured yet.

    dpkg: error processing package mongodb (--configure):
    dependency problems - leaving unconfigured
    Processing triggers for libc-bin (2.27-3ubuntu1) ...
    No apport report written because the error message indicates its a followup error from a previous failure.
    Processing triggers for systemd (237-3ubuntu10.13) ...
    Processing triggers for ureadahead (0.100.0-20) ...
    Errors were encountered while processing:
    mongodb-server
    mongodb
    E: Sub-process /usr/bin/dpkg returned an error code (1)



    find /etc -name "mongod"




    /etc/rc0.d/K01mongodb
    /etc/rc2.d/S01mongodb
    /etc/init/mongod.conf
    /etc/mongodb.conf
    /etc/mongod.conf
    /etc/apt/sources.list.d/mongodb-org-4.0.list.save
    /etc/apt/sources.list.d/mongodb-org-3.6.list.save
    /etc/apt/sources.list.d/mongodb-org-3.6.list
    /etc/apt/sources.list.d/mongodb-org-4.0.list
    /etc/logrotate.d/mongodb-server
    find: ‘/etc/ssl/private’: Permission denied
    /etc/rc4.d/S01mongodb
    /etc/systemd/system/mongodb.service
    /etc/rc3.d/S01mongodb
    /etc/rc1.d/K01mongodb
    /etc/rc5.d/S01mongodb
    find: ‘/etc/polkit-1/localauthority’: Permission denied
    /etc/init.d/mongodb
    find: ‘/etc/cups/ssl’: Permission denied
    /etc/rc6.d/K01mongodb









    share|improve this question

























      0












      0








      0








      I am trying to install the newest version of mongodb in Ubuntu 18.04. When running the command sudo apt install -y mongodb I get the following errors. I think my question is similar to https://serverfault.com/questions/809925/dpkg-error-processing-package and How to debug dpkg configure error in subprocess post-installation?. However, I do not understand the solution since I am new to Ubuntu. What are the steps to solve this issue?




      Error




      See system logs and 'systemctl status mongodb.service' for details.
      invoke-rc.d: initscript mongodb, action "start" failed.
      ● mongodb.service
      Loaded: error (Reason: Invalid argument)
      Active: failed (Result: exit-code) since Thu 2019-03-21 17:09:18 +0530; 26min ago
      Main PID: 14453 (code=exited, status=1/FAILURE)

      Mar 21 17:20:59 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:10 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:11 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:22 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:23 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:29:57 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:27 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:43 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:46 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:47 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      dpkg: error processing package mongodb-server (--configure):
      installed mongodb-server package post-installation script subprocess returned error exit status 1
      dpkg: dependency problems prevent configuration of mongodb:
      mongodb depends on mongodb-server (>= 1:2.4.1-2); however:
      Package mongodb-server is not configured yet.

      dpkg: error processing package mongodb (--configure):
      dependency problems - leaving unconfigured
      Processing triggers for libc-bin (2.27-3ubuntu1) ...
      No apport report written because the error message indicates its a followup error from a previous failure.
      Processing triggers for systemd (237-3ubuntu10.13) ...
      Processing triggers for ureadahead (0.100.0-20) ...
      Errors were encountered while processing:
      mongodb-server
      mongodb
      E: Sub-process /usr/bin/dpkg returned an error code (1)



      find /etc -name "mongod"




      /etc/rc0.d/K01mongodb
      /etc/rc2.d/S01mongodb
      /etc/init/mongod.conf
      /etc/mongodb.conf
      /etc/mongod.conf
      /etc/apt/sources.list.d/mongodb-org-4.0.list.save
      /etc/apt/sources.list.d/mongodb-org-3.6.list.save
      /etc/apt/sources.list.d/mongodb-org-3.6.list
      /etc/apt/sources.list.d/mongodb-org-4.0.list
      /etc/logrotate.d/mongodb-server
      find: ‘/etc/ssl/private’: Permission denied
      /etc/rc4.d/S01mongodb
      /etc/systemd/system/mongodb.service
      /etc/rc3.d/S01mongodb
      /etc/rc1.d/K01mongodb
      /etc/rc5.d/S01mongodb
      find: ‘/etc/polkit-1/localauthority’: Permission denied
      /etc/init.d/mongodb
      find: ‘/etc/cups/ssl’: Permission denied
      /etc/rc6.d/K01mongodb









      share|improve this question














      I am trying to install the newest version of mongodb in Ubuntu 18.04. When running the command sudo apt install -y mongodb I get the following errors. I think my question is similar to https://serverfault.com/questions/809925/dpkg-error-processing-package and How to debug dpkg configure error in subprocess post-installation?. However, I do not understand the solution since I am new to Ubuntu. What are the steps to solve this issue?




      Error




      See system logs and 'systemctl status mongodb.service' for details.
      invoke-rc.d: initscript mongodb, action "start" failed.
      ● mongodb.service
      Loaded: error (Reason: Invalid argument)
      Active: failed (Result: exit-code) since Thu 2019-03-21 17:09:18 +0530; 26min ago
      Main PID: 14453 (code=exited, status=1/FAILURE)

      Mar 21 17:20:59 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:10 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:11 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:22 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:21:23 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:29:57 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:27 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:43 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:46 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      Mar 21 17:35:47 kabilesh-Latitude-E6540 systemd[1]: mongodb.service: Service lacks both ExecStart= and ExecStop= setting. Refusing.
      dpkg: error processing package mongodb-server (--configure):
      installed mongodb-server package post-installation script subprocess returned error exit status 1
      dpkg: dependency problems prevent configuration of mongodb:
      mongodb depends on mongodb-server (>= 1:2.4.1-2); however:
      Package mongodb-server is not configured yet.

      dpkg: error processing package mongodb (--configure):
      dependency problems - leaving unconfigured
      Processing triggers for libc-bin (2.27-3ubuntu1) ...
      No apport report written because the error message indicates its a followup error from a previous failure.
      Processing triggers for systemd (237-3ubuntu10.13) ...
      Processing triggers for ureadahead (0.100.0-20) ...
      Errors were encountered while processing:
      mongodb-server
      mongodb
      E: Sub-process /usr/bin/dpkg returned an error code (1)



      find /etc -name "mongod"




      /etc/rc0.d/K01mongodb
      /etc/rc2.d/S01mongodb
      /etc/init/mongod.conf
      /etc/mongodb.conf
      /etc/mongod.conf
      /etc/apt/sources.list.d/mongodb-org-4.0.list.save
      /etc/apt/sources.list.d/mongodb-org-3.6.list.save
      /etc/apt/sources.list.d/mongodb-org-3.6.list
      /etc/apt/sources.list.d/mongodb-org-4.0.list
      /etc/logrotate.d/mongodb-server
      find: ‘/etc/ssl/private’: Permission denied
      /etc/rc4.d/S01mongodb
      /etc/systemd/system/mongodb.service
      /etc/rc3.d/S01mongodb
      /etc/rc1.d/K01mongodb
      /etc/rc5.d/S01mongodb
      find: ‘/etc/polkit-1/localauthority’: Permission denied
      /etc/init.d/mongodb
      find: ‘/etc/cups/ssl’: Permission denied
      /etc/rc6.d/K01mongodb






      apt 18.04 package-management dpkg mongodb






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 21 at 6:57









      KabileshKabilesh

      1031




      1031






















          1 Answer
          1






          active

          oldest

          votes


















          0














          Try removing that mongodb



          sudo apt-get purge mongodb


          then try installing it like this:



          sudo apt-get install mongodb-org





          share|improve this answer
























            Your Answer








            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "89"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1127440%2fdpkg-error-when-installing-mongodb-on-ubuntu-18-04%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            Try removing that mongodb



            sudo apt-get purge mongodb


            then try installing it like this:



            sudo apt-get install mongodb-org





            share|improve this answer




























              0














              Try removing that mongodb



              sudo apt-get purge mongodb


              then try installing it like this:



              sudo apt-get install mongodb-org





              share|improve this answer


























                0












                0








                0







                Try removing that mongodb



                sudo apt-get purge mongodb


                then try installing it like this:



                sudo apt-get install mongodb-org





                share|improve this answer













                Try removing that mongodb



                sudo apt-get purge mongodb


                then try installing it like this:



                sudo apt-get install mongodb-org






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Mar 21 at 8:18









                ognjenognjen

                38416




                38416






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Ask Ubuntu!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1127440%2fdpkg-error-when-installing-mongodb-on-ubuntu-18-04%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    數位音樂下載

                    When can things happen in Etherscan, such as the picture below?

                    格利澤436b