How do I disable network manager permanently?










11














I'm using Ubuntu 18.04.1 LTS. I want to disable network manager on an Ubuntu machine, because (1) I don't need it, (2) I prefer having hardcoded configuration, and (3) network manager regularly causes issues by changing the DHCP configuration.



I tried to follow the official documentation:




Stop network manager



sudo systemctl stop NetworkManager.service


Disable network manager (permanently) to avoid it restarting after a reboot



sudo systemctl disable NetworkManager.service



Despite this, the network manager is back again every time I reboot the machine.



How can I make it go away?










share|improve this question

















  • 1




    Is there a reason you cannot simply uninstall NM?
    – user535733
    Nov 10 '18 at 11:40










  • What do you want to use instead of NetworkManager - netplan as in server?
    – N0rbert
    Nov 10 '18 at 11:48










  • @user535733: I didn't know network manager can be uninstalled. I'll check this one.
    – Arseni Mourzenko
    Nov 10 '18 at 11:49






  • 1




    @N0rbert: just hardcoded configuration in /etc/network/interfaces and in /etc/resolv.conf. Don't know if there is an official name for that.
    – Arseni Mourzenko
    Nov 10 '18 at 11:50










  • @ArseniMourzenko What is your desktop environment? If it is GNOME, then purging network-manager will remove gnome-control-center, which is essential part of GNOME.
    – N0rbert
    Nov 10 '18 at 11:59















11














I'm using Ubuntu 18.04.1 LTS. I want to disable network manager on an Ubuntu machine, because (1) I don't need it, (2) I prefer having hardcoded configuration, and (3) network manager regularly causes issues by changing the DHCP configuration.



I tried to follow the official documentation:




Stop network manager



sudo systemctl stop NetworkManager.service


Disable network manager (permanently) to avoid it restarting after a reboot



sudo systemctl disable NetworkManager.service



Despite this, the network manager is back again every time I reboot the machine.



How can I make it go away?










share|improve this question

















  • 1




    Is there a reason you cannot simply uninstall NM?
    – user535733
    Nov 10 '18 at 11:40










  • What do you want to use instead of NetworkManager - netplan as in server?
    – N0rbert
    Nov 10 '18 at 11:48










  • @user535733: I didn't know network manager can be uninstalled. I'll check this one.
    – Arseni Mourzenko
    Nov 10 '18 at 11:49






  • 1




    @N0rbert: just hardcoded configuration in /etc/network/interfaces and in /etc/resolv.conf. Don't know if there is an official name for that.
    – Arseni Mourzenko
    Nov 10 '18 at 11:50










  • @ArseniMourzenko What is your desktop environment? If it is GNOME, then purging network-manager will remove gnome-control-center, which is essential part of GNOME.
    – N0rbert
    Nov 10 '18 at 11:59













11












11








11


4





I'm using Ubuntu 18.04.1 LTS. I want to disable network manager on an Ubuntu machine, because (1) I don't need it, (2) I prefer having hardcoded configuration, and (3) network manager regularly causes issues by changing the DHCP configuration.



I tried to follow the official documentation:




Stop network manager



sudo systemctl stop NetworkManager.service


Disable network manager (permanently) to avoid it restarting after a reboot



sudo systemctl disable NetworkManager.service



Despite this, the network manager is back again every time I reboot the machine.



How can I make it go away?










share|improve this question













I'm using Ubuntu 18.04.1 LTS. I want to disable network manager on an Ubuntu machine, because (1) I don't need it, (2) I prefer having hardcoded configuration, and (3) network manager regularly causes issues by changing the DHCP configuration.



I tried to follow the official documentation:




Stop network manager



sudo systemctl stop NetworkManager.service


Disable network manager (permanently) to avoid it restarting after a reboot



sudo systemctl disable NetworkManager.service



Despite this, the network manager is back again every time I reboot the machine.



How can I make it go away?







network-manager






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 10 '18 at 11:34









Arseni MourzenkoArseni Mourzenko

1,86931229




1,86931229







  • 1




    Is there a reason you cannot simply uninstall NM?
    – user535733
    Nov 10 '18 at 11:40










  • What do you want to use instead of NetworkManager - netplan as in server?
    – N0rbert
    Nov 10 '18 at 11:48










  • @user535733: I didn't know network manager can be uninstalled. I'll check this one.
    – Arseni Mourzenko
    Nov 10 '18 at 11:49






  • 1




    @N0rbert: just hardcoded configuration in /etc/network/interfaces and in /etc/resolv.conf. Don't know if there is an official name for that.
    – Arseni Mourzenko
    Nov 10 '18 at 11:50










  • @ArseniMourzenko What is your desktop environment? If it is GNOME, then purging network-manager will remove gnome-control-center, which is essential part of GNOME.
    – N0rbert
    Nov 10 '18 at 11:59












  • 1




    Is there a reason you cannot simply uninstall NM?
    – user535733
    Nov 10 '18 at 11:40










  • What do you want to use instead of NetworkManager - netplan as in server?
    – N0rbert
    Nov 10 '18 at 11:48










  • @user535733: I didn't know network manager can be uninstalled. I'll check this one.
    – Arseni Mourzenko
    Nov 10 '18 at 11:49






  • 1




    @N0rbert: just hardcoded configuration in /etc/network/interfaces and in /etc/resolv.conf. Don't know if there is an official name for that.
    – Arseni Mourzenko
    Nov 10 '18 at 11:50










  • @ArseniMourzenko What is your desktop environment? If it is GNOME, then purging network-manager will remove gnome-control-center, which is essential part of GNOME.
    – N0rbert
    Nov 10 '18 at 11:59







1




1




Is there a reason you cannot simply uninstall NM?
– user535733
Nov 10 '18 at 11:40




Is there a reason you cannot simply uninstall NM?
– user535733
Nov 10 '18 at 11:40












What do you want to use instead of NetworkManager - netplan as in server?
– N0rbert
Nov 10 '18 at 11:48




What do you want to use instead of NetworkManager - netplan as in server?
– N0rbert
Nov 10 '18 at 11:48












@user535733: I didn't know network manager can be uninstalled. I'll check this one.
– Arseni Mourzenko
Nov 10 '18 at 11:49




@user535733: I didn't know network manager can be uninstalled. I'll check this one.
– Arseni Mourzenko
Nov 10 '18 at 11:49




1




1




@N0rbert: just hardcoded configuration in /etc/network/interfaces and in /etc/resolv.conf. Don't know if there is an official name for that.
– Arseni Mourzenko
Nov 10 '18 at 11:50




@N0rbert: just hardcoded configuration in /etc/network/interfaces and in /etc/resolv.conf. Don't know if there is an official name for that.
– Arseni Mourzenko
Nov 10 '18 at 11:50












@ArseniMourzenko What is your desktop environment? If it is GNOME, then purging network-manager will remove gnome-control-center, which is essential part of GNOME.
– N0rbert
Nov 10 '18 at 11:59




@ArseniMourzenko What is your desktop environment? If it is GNOME, then purging network-manager will remove gnome-control-center, which is essential part of GNOME.
– N0rbert
Nov 10 '18 at 11:59










2 Answers
2






active

oldest

votes


















13














The method depends on desktop environment:




  • For Ubuntu MATE 18.04.1 LTS purging network-manager package is safe. You can simply run:



    sudo apt-get purge network-manager



  • For Ubuntu 18.04.1 LTS with GNOME desktop purging network-manager package will also purge ubuntu-desktop and gnome-control-center (essential part of GNOME desktop). So it is not an option.



    Here you should disable NetworkManager service (as you have already done):



    sudo systemctl stop NetworkManager.service
    sudo systemctl disable NetworkManager.service


    and three more services:



    sudo systemctl stop NetworkManager-wait-online.service
    sudo systemctl disable NetworkManager-wait-online.service

    sudo systemctl stop NetworkManager-dispatcher.service
    sudo systemctl disable NetworkManager-dispatcher.service

    sudo systemctl stop network-manager.service
    sudo systemctl disable network-manager.service


    and then reboot.




Notes:

1. You can read more about network configuration with /etc/network/interfaces from Ubuntu 16.04 LTS Server Guide.

2. Modern Ubuntu 18.04 LTS server uses netplan, you can read about it in the Ubuntu 18.04 LTS Server Guide.






share|improve this answer






























    5














    Try the mask command:



    sudo systemctl stop NetworkManager.service
    sudo systemctl mask NetworkManager.service



    mask NAME...



    Mask one or more units, as specified on the command line. This will link these unit files to /dev/null, making it impossible to start them.

    This is a stronger version of disable, since it prohibits all kinds of activation of the unit, including enablement and manual activation. Use this option with care. This honors the --runtime option to only mask temporarily until the next reboot of the system.

    The --now option may be used to ensure that the units are also
    stopped. This command expects valid unit names only, it does not accept unit file paths.







    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%2f1091653%2fhow-do-i-disable-network-manager-permanently%23new-answer', 'question_page');

      );

      Post as a guest















      Required, but never shown

























      2 Answers
      2






      active

      oldest

      votes








      2 Answers
      2






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      13














      The method depends on desktop environment:




      • For Ubuntu MATE 18.04.1 LTS purging network-manager package is safe. You can simply run:



        sudo apt-get purge network-manager



      • For Ubuntu 18.04.1 LTS with GNOME desktop purging network-manager package will also purge ubuntu-desktop and gnome-control-center (essential part of GNOME desktop). So it is not an option.



        Here you should disable NetworkManager service (as you have already done):



        sudo systemctl stop NetworkManager.service
        sudo systemctl disable NetworkManager.service


        and three more services:



        sudo systemctl stop NetworkManager-wait-online.service
        sudo systemctl disable NetworkManager-wait-online.service

        sudo systemctl stop NetworkManager-dispatcher.service
        sudo systemctl disable NetworkManager-dispatcher.service

        sudo systemctl stop network-manager.service
        sudo systemctl disable network-manager.service


        and then reboot.




      Notes:

      1. You can read more about network configuration with /etc/network/interfaces from Ubuntu 16.04 LTS Server Guide.

      2. Modern Ubuntu 18.04 LTS server uses netplan, you can read about it in the Ubuntu 18.04 LTS Server Guide.






      share|improve this answer



























        13














        The method depends on desktop environment:




        • For Ubuntu MATE 18.04.1 LTS purging network-manager package is safe. You can simply run:



          sudo apt-get purge network-manager



        • For Ubuntu 18.04.1 LTS with GNOME desktop purging network-manager package will also purge ubuntu-desktop and gnome-control-center (essential part of GNOME desktop). So it is not an option.



          Here you should disable NetworkManager service (as you have already done):



          sudo systemctl stop NetworkManager.service
          sudo systemctl disable NetworkManager.service


          and three more services:



          sudo systemctl stop NetworkManager-wait-online.service
          sudo systemctl disable NetworkManager-wait-online.service

          sudo systemctl stop NetworkManager-dispatcher.service
          sudo systemctl disable NetworkManager-dispatcher.service

          sudo systemctl stop network-manager.service
          sudo systemctl disable network-manager.service


          and then reboot.




        Notes:

        1. You can read more about network configuration with /etc/network/interfaces from Ubuntu 16.04 LTS Server Guide.

        2. Modern Ubuntu 18.04 LTS server uses netplan, you can read about it in the Ubuntu 18.04 LTS Server Guide.






        share|improve this answer

























          13












          13








          13






          The method depends on desktop environment:




          • For Ubuntu MATE 18.04.1 LTS purging network-manager package is safe. You can simply run:



            sudo apt-get purge network-manager



          • For Ubuntu 18.04.1 LTS with GNOME desktop purging network-manager package will also purge ubuntu-desktop and gnome-control-center (essential part of GNOME desktop). So it is not an option.



            Here you should disable NetworkManager service (as you have already done):



            sudo systemctl stop NetworkManager.service
            sudo systemctl disable NetworkManager.service


            and three more services:



            sudo systemctl stop NetworkManager-wait-online.service
            sudo systemctl disable NetworkManager-wait-online.service

            sudo systemctl stop NetworkManager-dispatcher.service
            sudo systemctl disable NetworkManager-dispatcher.service

            sudo systemctl stop network-manager.service
            sudo systemctl disable network-manager.service


            and then reboot.




          Notes:

          1. You can read more about network configuration with /etc/network/interfaces from Ubuntu 16.04 LTS Server Guide.

          2. Modern Ubuntu 18.04 LTS server uses netplan, you can read about it in the Ubuntu 18.04 LTS Server Guide.






          share|improve this answer














          The method depends on desktop environment:




          • For Ubuntu MATE 18.04.1 LTS purging network-manager package is safe. You can simply run:



            sudo apt-get purge network-manager



          • For Ubuntu 18.04.1 LTS with GNOME desktop purging network-manager package will also purge ubuntu-desktop and gnome-control-center (essential part of GNOME desktop). So it is not an option.



            Here you should disable NetworkManager service (as you have already done):



            sudo systemctl stop NetworkManager.service
            sudo systemctl disable NetworkManager.service


            and three more services:



            sudo systemctl stop NetworkManager-wait-online.service
            sudo systemctl disable NetworkManager-wait-online.service

            sudo systemctl stop NetworkManager-dispatcher.service
            sudo systemctl disable NetworkManager-dispatcher.service

            sudo systemctl stop network-manager.service
            sudo systemctl disable network-manager.service


            and then reboot.




          Notes:

          1. You can read more about network configuration with /etc/network/interfaces from Ubuntu 16.04 LTS Server Guide.

          2. Modern Ubuntu 18.04 LTS server uses netplan, you can read about it in the Ubuntu 18.04 LTS Server Guide.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Nov 10 '18 at 12:22

























          answered Nov 10 '18 at 12:14









          N0rbertN0rbert

          21.6k547101




          21.6k547101























              5














              Try the mask command:



              sudo systemctl stop NetworkManager.service
              sudo systemctl mask NetworkManager.service



              mask NAME...



              Mask one or more units, as specified on the command line. This will link these unit files to /dev/null, making it impossible to start them.

              This is a stronger version of disable, since it prohibits all kinds of activation of the unit, including enablement and manual activation. Use this option with care. This honors the --runtime option to only mask temporarily until the next reboot of the system.

              The --now option may be used to ensure that the units are also
              stopped. This command expects valid unit names only, it does not accept unit file paths.







              share|improve this answer



























                5














                Try the mask command:



                sudo systemctl stop NetworkManager.service
                sudo systemctl mask NetworkManager.service



                mask NAME...



                Mask one or more units, as specified on the command line. This will link these unit files to /dev/null, making it impossible to start them.

                This is a stronger version of disable, since it prohibits all kinds of activation of the unit, including enablement and manual activation. Use this option with care. This honors the --runtime option to only mask temporarily until the next reboot of the system.

                The --now option may be used to ensure that the units are also
                stopped. This command expects valid unit names only, it does not accept unit file paths.







                share|improve this answer

























                  5












                  5








                  5






                  Try the mask command:



                  sudo systemctl stop NetworkManager.service
                  sudo systemctl mask NetworkManager.service



                  mask NAME...



                  Mask one or more units, as specified on the command line. This will link these unit files to /dev/null, making it impossible to start them.

                  This is a stronger version of disable, since it prohibits all kinds of activation of the unit, including enablement and manual activation. Use this option with care. This honors the --runtime option to only mask temporarily until the next reboot of the system.

                  The --now option may be used to ensure that the units are also
                  stopped. This command expects valid unit names only, it does not accept unit file paths.







                  share|improve this answer














                  Try the mask command:



                  sudo systemctl stop NetworkManager.service
                  sudo systemctl mask NetworkManager.service



                  mask NAME...



                  Mask one or more units, as specified on the command line. This will link these unit files to /dev/null, making it impossible to start them.

                  This is a stronger version of disable, since it prohibits all kinds of activation of the unit, including enablement and manual activation. Use this option with care. This honors the --runtime option to only mask temporarily until the next reboot of the system.

                  The --now option may be used to ensure that the units are also
                  stopped. This command expects valid unit names only, it does not accept unit file paths.








                  share|improve this answer














                  share|improve this answer



                  share|improve this answer








                  edited Nov 11 '18 at 16:32

























                  answered Nov 10 '18 at 15:41









                  abu_buaabu_bua

                  3,27681026




                  3,27681026



























                      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.





                      Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                      Please pay close attention to the following guidance:


                      • 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%2f1091653%2fhow-do-i-disable-network-manager-permanently%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

                      𛂒𛀶,𛀽𛀑𛂀𛃧𛂓𛀙𛃆𛃑𛃷𛂟𛁡𛀢𛀟𛁤𛂽𛁕𛁪𛂟𛂯,𛁞𛂧𛀴𛁄𛁠𛁼𛂿𛀤 𛂘,𛁺𛂾𛃭𛃭𛃵𛀺,𛂣𛃍𛂖𛃶 𛀸𛃀𛂖𛁶𛁏𛁚 𛂢𛂞 𛁰𛂆𛀔,𛁸𛀽𛁓𛃋𛂇𛃧𛀧𛃣𛂐𛃇,𛂂𛃻𛃲𛁬𛃞𛀧𛃃𛀅 𛂭𛁠𛁡𛃇𛀷𛃓𛁥,𛁙𛁘𛁞𛃸𛁸𛃣𛁜,𛂛,𛃿,𛁯𛂘𛂌𛃛𛁱𛃌𛂈𛂇 𛁊𛃲,𛀕𛃴𛀜 𛀶𛂆𛀶𛃟𛂉𛀣,𛂐𛁞𛁾 𛁷𛂑𛁳𛂯𛀬𛃅,𛃶𛁼

                      Crossroads (UK TV series)

                      ữḛḳṊẴ ẋ,Ẩṙ,ỹḛẪẠứụỿṞṦ,Ṉẍừ,ứ Ị,Ḵ,ṏ ṇỪḎḰṰọửḊ ṾḨḮữẑỶṑỗḮṣṉẃ Ữẩụ,ṓ,ḹẕḪḫỞṿḭ ỒṱṨẁṋṜ ḅẈ ṉ ứṀḱṑỒḵ,ḏ,ḊḖỹẊ Ẻḷổ,ṥ ẔḲẪụḣể Ṱ ḭỏựẶ Ồ Ṩ,ẂḿṡḾồ ỗṗṡịṞẤḵṽẃ ṸḒẄẘ,ủẞẵṦṟầṓế