How to activate service aftering mounting in systemd The Next CEO of Stack OverflowHow to set environment variable in systemd service?Suddenly mysql/mariadb won't startFind the location of a systemd serviceDo systemd unit files have to be reloaded when modified?Start systemd service conditionally?OEL 7.2 with LACP systemd shutdowns networking before umounting _netdev filesystemsSystemd service: Failed to issue method call: Unit service failedKilling systemd service with and without systemctlsystemctl stops Tomcat service immediately after startDisabling systemd messages that interfere with running BASH script

Yu-Gi-Oh cards in Python 3

Would a completely good Muggle be able to use a wand?

My ex-girlfriend uses my Apple ID to login to her iPad, do I have to give her my Apple ID password to reset it?

Is dried pee considered dirt?

What was the first Unix version to run on a microcomputer?

Help! I cannot understand this game’s notations!

(How) Could a medieval fantasy world survive a magic-induced "nuclear winter"?

Would a grinding machine be a simple and workable propulsion system for an interplanetary spacecraft?

Can this note be analyzed as a non-chord tone?

I dug holes for my pergola too wide

Does destroying a Lich's phylactery destroy the soul within it?

Why the last AS PATH item always is `I` or `?`?

Is it okay to majorly distort historical facts while writing a fiction story?

Prepend last line of stdin to entire stdin

Reference request: Grassmannian and Plucker coordinates in type B, C, D

Is "three point ish" an acceptable use of ish?

TikZ: How to fill area with a special pattern?

Help understanding this unsettling image of Titan, Epimetheus, and Saturn's rings?

Is a distribution that is normal, but highly skewed, considered Gaussian?

Traduction de « Life is a roller coaster »

Expressing the idea of having a very busy time

Is it convenient to ask the journal's editor for two additional days to complete a review?

How did Beeri the Hittite come up with naming his daughter Yehudit?

What difference does it make using sed with/without whitespaces?



How to activate service aftering mounting in systemd



The Next CEO of Stack OverflowHow to set environment variable in systemd service?Suddenly mysql/mariadb won't startFind the location of a systemd serviceDo systemd unit files have to be reloaded when modified?Start systemd service conditionally?OEL 7.2 with LACP systemd shutdowns networking before umounting _netdev filesystemsSystemd service: Failed to issue method call: Unit service failedKilling systemd service with and without systemctlsystemctl stops Tomcat service immediately after startDisabling systemd messages that interfere with running BASH script










0















I want to mount aria2c service after mount mnt-usb.mount. The following config file work as expected but after mnt-usb.mount inactive and active again (because of unpluging and plug the device again) the aria2c not active again.



aria2c.service



[Unit]
Description=Aria2c download manager
After=network-online.target mnt-usb.mount
Requires=network-online.target
BindsTo=mnt-usb.mount
PartOf=mnt-usb.mount

[Service]
Type=simple
User=www-data
ExecStart=/usr/bin/aria2c --enable-rpc --rpc-listen-all --conf-path=/etc/aria2.daemon
Restart=always

[Install]
WantedBy=multi-user.target


mnt-usb.mount
[Unit]
Description=mount usb



[Mount]
What=/dev/disk/by-uuid/some-uuid
Where=/mnt/usb
Type=ntfs
Options=defaults

[Install]
WantedBy=multi-user.target


enter image description here










share|improve this question


























    0















    I want to mount aria2c service after mount mnt-usb.mount. The following config file work as expected but after mnt-usb.mount inactive and active again (because of unpluging and plug the device again) the aria2c not active again.



    aria2c.service



    [Unit]
    Description=Aria2c download manager
    After=network-online.target mnt-usb.mount
    Requires=network-online.target
    BindsTo=mnt-usb.mount
    PartOf=mnt-usb.mount

    [Service]
    Type=simple
    User=www-data
    ExecStart=/usr/bin/aria2c --enable-rpc --rpc-listen-all --conf-path=/etc/aria2.daemon
    Restart=always

    [Install]
    WantedBy=multi-user.target


    mnt-usb.mount
    [Unit]
    Description=mount usb



    [Mount]
    What=/dev/disk/by-uuid/some-uuid
    Where=/mnt/usb
    Type=ntfs
    Options=defaults

    [Install]
    WantedBy=multi-user.target


    enter image description here










    share|improve this question
























      0












      0








      0








      I want to mount aria2c service after mount mnt-usb.mount. The following config file work as expected but after mnt-usb.mount inactive and active again (because of unpluging and plug the device again) the aria2c not active again.



      aria2c.service



      [Unit]
      Description=Aria2c download manager
      After=network-online.target mnt-usb.mount
      Requires=network-online.target
      BindsTo=mnt-usb.mount
      PartOf=mnt-usb.mount

      [Service]
      Type=simple
      User=www-data
      ExecStart=/usr/bin/aria2c --enable-rpc --rpc-listen-all --conf-path=/etc/aria2.daemon
      Restart=always

      [Install]
      WantedBy=multi-user.target


      mnt-usb.mount
      [Unit]
      Description=mount usb



      [Mount]
      What=/dev/disk/by-uuid/some-uuid
      Where=/mnt/usb
      Type=ntfs
      Options=defaults

      [Install]
      WantedBy=multi-user.target


      enter image description here










      share|improve this question














      I want to mount aria2c service after mount mnt-usb.mount. The following config file work as expected but after mnt-usb.mount inactive and active again (because of unpluging and plug the device again) the aria2c not active again.



      aria2c.service



      [Unit]
      Description=Aria2c download manager
      After=network-online.target mnt-usb.mount
      Requires=network-online.target
      BindsTo=mnt-usb.mount
      PartOf=mnt-usb.mount

      [Service]
      Type=simple
      User=www-data
      ExecStart=/usr/bin/aria2c --enable-rpc --rpc-listen-all --conf-path=/etc/aria2.daemon
      Restart=always

      [Install]
      WantedBy=multi-user.target


      mnt-usb.mount
      [Unit]
      Description=mount usb



      [Mount]
      What=/dev/disk/by-uuid/some-uuid
      Where=/mnt/usb
      Type=ntfs
      Options=defaults

      [Install]
      WantedBy=multi-user.target


      enter image description here







      systemd systemctl






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked yesterday









      o0omycomputero0oo0omycomputero0o

      1162




      1162




















          0






          active

          oldest

          votes












          Your Answer








          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "2"
          ;
          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%2fserverfault.com%2fquestions%2f960719%2fhow-to-activate-service-aftering-mounting-in-systemd%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          0






          active

          oldest

          votes








          0






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Server Fault!


          • 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%2fserverfault.com%2fquestions%2f960719%2fhow-to-activate-service-aftering-mounting-in-systemd%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

          How to write a 12-bar blues melodyI-IV-V blues progressionHow to play the bridges in a standard blues progressionHow does Gdim7 fit in C# minor?question on a certain chord progressionMusicology of Melody12 bar blues, spread rhythm: alternative to 6th chord to avoid finger stretchChord progressions/ Root key/ MelodiesHow to put chords (POP-EDM) under a given lead vocal melody (starting from a good knowledge in music theory)Are there “rules” for improvising with the minor pentatonic scale over 12-bar shuffle?Confusion about blues scale and chords

          What if the end-user didn't have the required library?What is setup.py?What is a clean, pythonic way to have multiple constructors in Python?What does Ruby have that Python doesn't, and vice versa?What is the reason for having '//' in Python?How do I create a namespace package in Python?How to package shared objects that python modules depend on?setuptools vs. distutils: why is distutils still a thing?Navigation in Windows 10 vs code not going to virtualenv library when the same library is installed at user levelPython create package for local usePackaging a project that uses multiple python versionsWhy is permission denied on pip install except for when “--user” is included at end of command?

          Esgonzo ibérico Índice Descrición Distribución Hábitat Ameazas Notas Véxase tamén "Acerca dos nomes dos anfibios e réptiles galegos""Chalcides bedriagai"Chalcides bedriagai en Carrascal, L. M. Salvador, A. (Eds). Enciclopedia virtual de los vertebrados españoles. Museo Nacional de Ciencias Naturales, Madrid. España.Fotos