Ubuntu 16.04 - Wifi Disconnection - Script To Fix

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
0
down vote

favorite












Randomly (every few days), the wifi disconnects (USB adapter). Issuing this command fixes it:



sudo service network-manager restart



Logging into it manually to issue this command is annoying. How can I find out that the network is down and issue this command? I am thinking of scheduling something to ping an IP and if that fails then issue the above command. But my knowledge is limited. Appreciate any help or nudge in the right direction.










share|improve this question



























    up vote
    0
    down vote

    favorite












    Randomly (every few days), the wifi disconnects (USB adapter). Issuing this command fixes it:



    sudo service network-manager restart



    Logging into it manually to issue this command is annoying. How can I find out that the network is down and issue this command? I am thinking of scheduling something to ping an IP and if that fails then issue the above command. But my knowledge is limited. Appreciate any help or nudge in the right direction.










    share|improve this question

























      up vote
      0
      down vote

      favorite









      up vote
      0
      down vote

      favorite











      Randomly (every few days), the wifi disconnects (USB adapter). Issuing this command fixes it:



      sudo service network-manager restart



      Logging into it manually to issue this command is annoying. How can I find out that the network is down and issue this command? I am thinking of scheduling something to ping an IP and if that fails then issue the above command. But my knowledge is limited. Appreciate any help or nudge in the right direction.










      share|improve this question















      Randomly (every few days), the wifi disconnects (USB adapter). Issuing this command fixes it:



      sudo service network-manager restart



      Logging into it manually to issue this command is annoying. How can I find out that the network is down and issue this command? I am thinking of scheduling something to ping an IP and if that fails then issue the above command. But my knowledge is limited. Appreciate any help or nudge in the right direction.







      networking wireless scripts network-manager






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 14 at 2:52

























      asked Mar 14 at 2:46









      code4kix

      1013




      1013

























          active

          oldest

          votes











          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',
          convertImagesToLinks: true,
          noModals: false,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          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%2f1014757%2fubuntu-16-04-wifi-disconnection-script-to-fix%23new-answer', 'question_page');

          );

          Post as a guest



































          active

          oldest

          votes













          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















           

          draft saved


          draft discarded















































           


          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1014757%2fubuntu-16-04-wifi-disconnection-script-to-fix%23new-answer', 'question_page');

          );

          Post as a guest













































































          Popular posts from this blog

          pylint3 and pip3 broken

          Missing snmpget and snmpwalk

          How to enroll fingerprints to Ubuntu 17.10 with VFS491