How should properly stop x0vncserver?












0















I use x0vncserver to connect to my ubuntu display. I start it with /usr/bin/x0vncserver -display :0. I can see it running with pidof x0vncserver.



I have also seen that the proper way to stop vncserver is to use vncserver -kill :xx command.



Is there a similar command to properly stop x0vncserver or one should just use killall x0vncserver to stop it?



When trying sudo systemctl stop x0vncserver, I got:



Failed to stop x0vncserver.service: Unit x0vncserver.service not loaded.









share|improve this question





























    0















    I use x0vncserver to connect to my ubuntu display. I start it with /usr/bin/x0vncserver -display :0. I can see it running with pidof x0vncserver.



    I have also seen that the proper way to stop vncserver is to use vncserver -kill :xx command.



    Is there a similar command to properly stop x0vncserver or one should just use killall x0vncserver to stop it?



    When trying sudo systemctl stop x0vncserver, I got:



    Failed to stop x0vncserver.service: Unit x0vncserver.service not loaded.









    share|improve this question



























      0












      0








      0








      I use x0vncserver to connect to my ubuntu display. I start it with /usr/bin/x0vncserver -display :0. I can see it running with pidof x0vncserver.



      I have also seen that the proper way to stop vncserver is to use vncserver -kill :xx command.



      Is there a similar command to properly stop x0vncserver or one should just use killall x0vncserver to stop it?



      When trying sudo systemctl stop x0vncserver, I got:



      Failed to stop x0vncserver.service: Unit x0vncserver.service not loaded.









      share|improve this question
















      I use x0vncserver to connect to my ubuntu display. I start it with /usr/bin/x0vncserver -display :0. I can see it running with pidof x0vncserver.



      I have also seen that the proper way to stop vncserver is to use vncserver -kill :xx command.



      Is there a similar command to properly stop x0vncserver or one should just use killall x0vncserver to stop it?



      When trying sudo systemctl stop x0vncserver, I got:



      Failed to stop x0vncserver.service: Unit x0vncserver.service not loaded.






      vnc remote kill






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Feb 6 at 10:08









      Melebius

      5,05752040




      5,05752040










      asked Feb 4 at 0:21









      SaTaSaTa

      7017




      7017






















          1 Answer
          1






          active

          oldest

          votes


















          1














          It looks like killing by PID is the way to go.



          First obtain the PID:



          pidof x0vncserver



          Then kill it with the resulting PID from the above command.



          kill -15 PID or kill -SIGTERM PID



          You can also use killall processname where process name is the process you wish to kill provided you have the psmisc package installed. You can confirm that with the command dpkg -l psmisc which will provide output like this:



          $ dpkg -l psmisc
          Desired=Unknown/Install/Remove/Purge/Hold
          | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
          |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
          ||/ Name Version Architecture Description
          +++-===========================-==================-==================-===========================================================
          ii psmisc 22.21-2.1build1 amd64 utilities that use the proc file system


          Sources:
          https://groups.google.com/forum/#!topic/tigervnc-users/lxRS20r2XFc



          https://www.cyberciti.biz/faq/kill-process-in-linux-or-terminate-a-process-in-unix-or-linux-systems/



          man killall






          share|improve this answer


























          • Thanks, would killall x0vncserver do the same job as above?

            – SaTa
            Feb 9 at 14:03











          • @SaTa updated answer

            – Elder Geek
            Feb 9 at 20:54











          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%2f1115398%2fhow-should-properly-stop-x0vncserver%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









          1














          It looks like killing by PID is the way to go.



          First obtain the PID:



          pidof x0vncserver



          Then kill it with the resulting PID from the above command.



          kill -15 PID or kill -SIGTERM PID



          You can also use killall processname where process name is the process you wish to kill provided you have the psmisc package installed. You can confirm that with the command dpkg -l psmisc which will provide output like this:



          $ dpkg -l psmisc
          Desired=Unknown/Install/Remove/Purge/Hold
          | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
          |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
          ||/ Name Version Architecture Description
          +++-===========================-==================-==================-===========================================================
          ii psmisc 22.21-2.1build1 amd64 utilities that use the proc file system


          Sources:
          https://groups.google.com/forum/#!topic/tigervnc-users/lxRS20r2XFc



          https://www.cyberciti.biz/faq/kill-process-in-linux-or-terminate-a-process-in-unix-or-linux-systems/



          man killall






          share|improve this answer


























          • Thanks, would killall x0vncserver do the same job as above?

            – SaTa
            Feb 9 at 14:03











          • @SaTa updated answer

            – Elder Geek
            Feb 9 at 20:54
















          1














          It looks like killing by PID is the way to go.



          First obtain the PID:



          pidof x0vncserver



          Then kill it with the resulting PID from the above command.



          kill -15 PID or kill -SIGTERM PID



          You can also use killall processname where process name is the process you wish to kill provided you have the psmisc package installed. You can confirm that with the command dpkg -l psmisc which will provide output like this:



          $ dpkg -l psmisc
          Desired=Unknown/Install/Remove/Purge/Hold
          | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
          |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
          ||/ Name Version Architecture Description
          +++-===========================-==================-==================-===========================================================
          ii psmisc 22.21-2.1build1 amd64 utilities that use the proc file system


          Sources:
          https://groups.google.com/forum/#!topic/tigervnc-users/lxRS20r2XFc



          https://www.cyberciti.biz/faq/kill-process-in-linux-or-terminate-a-process-in-unix-or-linux-systems/



          man killall






          share|improve this answer


























          • Thanks, would killall x0vncserver do the same job as above?

            – SaTa
            Feb 9 at 14:03











          • @SaTa updated answer

            – Elder Geek
            Feb 9 at 20:54














          1












          1








          1







          It looks like killing by PID is the way to go.



          First obtain the PID:



          pidof x0vncserver



          Then kill it with the resulting PID from the above command.



          kill -15 PID or kill -SIGTERM PID



          You can also use killall processname where process name is the process you wish to kill provided you have the psmisc package installed. You can confirm that with the command dpkg -l psmisc which will provide output like this:



          $ dpkg -l psmisc
          Desired=Unknown/Install/Remove/Purge/Hold
          | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
          |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
          ||/ Name Version Architecture Description
          +++-===========================-==================-==================-===========================================================
          ii psmisc 22.21-2.1build1 amd64 utilities that use the proc file system


          Sources:
          https://groups.google.com/forum/#!topic/tigervnc-users/lxRS20r2XFc



          https://www.cyberciti.biz/faq/kill-process-in-linux-or-terminate-a-process-in-unix-or-linux-systems/



          man killall






          share|improve this answer















          It looks like killing by PID is the way to go.



          First obtain the PID:



          pidof x0vncserver



          Then kill it with the resulting PID from the above command.



          kill -15 PID or kill -SIGTERM PID



          You can also use killall processname where process name is the process you wish to kill provided you have the psmisc package installed. You can confirm that with the command dpkg -l psmisc which will provide output like this:



          $ dpkg -l psmisc
          Desired=Unknown/Install/Remove/Purge/Hold
          | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
          |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
          ||/ Name Version Architecture Description
          +++-===========================-==================-==================-===========================================================
          ii psmisc 22.21-2.1build1 amd64 utilities that use the proc file system


          Sources:
          https://groups.google.com/forum/#!topic/tigervnc-users/lxRS20r2XFc



          https://www.cyberciti.biz/faq/kill-process-in-linux-or-terminate-a-process-in-unix-or-linux-systems/



          man killall







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Feb 9 at 20:54

























          answered Feb 6 at 15:03









          Elder GeekElder Geek

          27.4k955128




          27.4k955128













          • Thanks, would killall x0vncserver do the same job as above?

            – SaTa
            Feb 9 at 14:03











          • @SaTa updated answer

            – Elder Geek
            Feb 9 at 20:54



















          • Thanks, would killall x0vncserver do the same job as above?

            – SaTa
            Feb 9 at 14:03











          • @SaTa updated answer

            – Elder Geek
            Feb 9 at 20:54

















          Thanks, would killall x0vncserver do the same job as above?

          – SaTa
          Feb 9 at 14:03





          Thanks, would killall x0vncserver do the same job as above?

          – SaTa
          Feb 9 at 14:03













          @SaTa updated answer

          – Elder Geek
          Feb 9 at 20:54





          @SaTa updated answer

          – Elder Geek
          Feb 9 at 20:54


















          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%2f1115398%2fhow-should-properly-stop-x0vncserver%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

          Human spaceflight

          Can not write log (Is /dev/pts mounted?) - openpty in Ubuntu-on-Windows?

          張江高科駅