Ubuntu Server 16.04 - OpenVPN seems not to start, no logs get written

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











up vote
12
down vote

favorite
6












I installed and oepnvpn on an Ubuntu server 16.04 by following the following guideline
how-to-set-up-an-openvpn-server-on-ubuntu



When I start the openVPN server with: service openvpn start it looks like it get started, but I get no log files written even though I have the log option activated.



status /var/log/openvpn-status.log
log /var/log/openvpn.log


Any hints what I can try?



  • how can I check if the process/service is really running?

  • how can I find out if the service is crashing every time?

  • any idea why the log files don't get written?

output on starting the service



root@Diabolo:/etc/openvpn# service openvpn stop
root@Diabolo:/etc/openvpn# service openvpn start
root@Diabolo:/etc/openvpn# service openvpn status
openvpn.service - OpenVPN service
Loaded: loaded (/lib/systemd/system/openvpn.service; enabled; vendor preset: enabled)
Active: active (exited) since Sat 2016-06-25 19:04:12 CEST; 3s ago
Process: 3956 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
Main PID: 3956 (code=exited, status=0/SUCCESS)
Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


output on syslog



Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


config file server.conf



port 1194
proto udp
dev tun
ca /etc/openvpn/ca.crt
cert /etc/openvpn/server.crt
key /etc/openvpn/server.key
dh /etc/openvpn/dh2048.pem
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
push "redirect-gateway def1 bypass-dhcp"
push "dhcp-option DNS 208.67.222.222"
push "dhcp-option DNS 208.67.220.220"
keepalive 10 120
comp-lzo
max-clients 100
user nobody
group nogroup
persist-key
persist-tun
status /var/log/openvpn-status.log
log /var/log/openvpn.log
verb 3









share|improve this question



























    up vote
    12
    down vote

    favorite
    6












    I installed and oepnvpn on an Ubuntu server 16.04 by following the following guideline
    how-to-set-up-an-openvpn-server-on-ubuntu



    When I start the openVPN server with: service openvpn start it looks like it get started, but I get no log files written even though I have the log option activated.



    status /var/log/openvpn-status.log
    log /var/log/openvpn.log


    Any hints what I can try?



    • how can I check if the process/service is really running?

    • how can I find out if the service is crashing every time?

    • any idea why the log files don't get written?

    output on starting the service



    root@Diabolo:/etc/openvpn# service openvpn stop
    root@Diabolo:/etc/openvpn# service openvpn start
    root@Diabolo:/etc/openvpn# service openvpn status
    openvpn.service - OpenVPN service
    Loaded: loaded (/lib/systemd/system/openvpn.service; enabled; vendor preset: enabled)
    Active: active (exited) since Sat 2016-06-25 19:04:12 CEST; 3s ago
    Process: 3956 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
    Main PID: 3956 (code=exited, status=0/SUCCESS)
    Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
    Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


    output on syslog



    Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
    Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


    config file server.conf



    port 1194
    proto udp
    dev tun
    ca /etc/openvpn/ca.crt
    cert /etc/openvpn/server.crt
    key /etc/openvpn/server.key
    dh /etc/openvpn/dh2048.pem
    server 10.8.0.0 255.255.255.0
    ifconfig-pool-persist ipp.txt
    push "redirect-gateway def1 bypass-dhcp"
    push "dhcp-option DNS 208.67.222.222"
    push "dhcp-option DNS 208.67.220.220"
    keepalive 10 120
    comp-lzo
    max-clients 100
    user nobody
    group nogroup
    persist-key
    persist-tun
    status /var/log/openvpn-status.log
    log /var/log/openvpn.log
    verb 3









    share|improve this question

























      up vote
      12
      down vote

      favorite
      6









      up vote
      12
      down vote

      favorite
      6






      6





      I installed and oepnvpn on an Ubuntu server 16.04 by following the following guideline
      how-to-set-up-an-openvpn-server-on-ubuntu



      When I start the openVPN server with: service openvpn start it looks like it get started, but I get no log files written even though I have the log option activated.



      status /var/log/openvpn-status.log
      log /var/log/openvpn.log


      Any hints what I can try?



      • how can I check if the process/service is really running?

      • how can I find out if the service is crashing every time?

      • any idea why the log files don't get written?

      output on starting the service



      root@Diabolo:/etc/openvpn# service openvpn stop
      root@Diabolo:/etc/openvpn# service openvpn start
      root@Diabolo:/etc/openvpn# service openvpn status
      openvpn.service - OpenVPN service
      Loaded: loaded (/lib/systemd/system/openvpn.service; enabled; vendor preset: enabled)
      Active: active (exited) since Sat 2016-06-25 19:04:12 CEST; 3s ago
      Process: 3956 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
      Main PID: 3956 (code=exited, status=0/SUCCESS)
      Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
      Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


      output on syslog



      Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
      Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


      config file server.conf



      port 1194
      proto udp
      dev tun
      ca /etc/openvpn/ca.crt
      cert /etc/openvpn/server.crt
      key /etc/openvpn/server.key
      dh /etc/openvpn/dh2048.pem
      server 10.8.0.0 255.255.255.0
      ifconfig-pool-persist ipp.txt
      push "redirect-gateway def1 bypass-dhcp"
      push "dhcp-option DNS 208.67.222.222"
      push "dhcp-option DNS 208.67.220.220"
      keepalive 10 120
      comp-lzo
      max-clients 100
      user nobody
      group nogroup
      persist-key
      persist-tun
      status /var/log/openvpn-status.log
      log /var/log/openvpn.log
      verb 3









      share|improve this question















      I installed and oepnvpn on an Ubuntu server 16.04 by following the following guideline
      how-to-set-up-an-openvpn-server-on-ubuntu



      When I start the openVPN server with: service openvpn start it looks like it get started, but I get no log files written even though I have the log option activated.



      status /var/log/openvpn-status.log
      log /var/log/openvpn.log


      Any hints what I can try?



      • how can I check if the process/service is really running?

      • how can I find out if the service is crashing every time?

      • any idea why the log files don't get written?

      output on starting the service



      root@Diabolo:/etc/openvpn# service openvpn stop
      root@Diabolo:/etc/openvpn# service openvpn start
      root@Diabolo:/etc/openvpn# service openvpn status
      openvpn.service - OpenVPN service
      Loaded: loaded (/lib/systemd/system/openvpn.service; enabled; vendor preset: enabled)
      Active: active (exited) since Sat 2016-06-25 19:04:12 CEST; 3s ago
      Process: 3956 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
      Main PID: 3956 (code=exited, status=0/SUCCESS)
      Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
      Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


      output on syslog



      Jun 25 19:04:12 Diabolo systemd[1]: Starting OpenVPN service...
      Jun 25 19:04:12 Diabolo systemd[1]: Started OpenVPN service.


      config file server.conf



      port 1194
      proto udp
      dev tun
      ca /etc/openvpn/ca.crt
      cert /etc/openvpn/server.crt
      key /etc/openvpn/server.key
      dh /etc/openvpn/dh2048.pem
      server 10.8.0.0 255.255.255.0
      ifconfig-pool-persist ipp.txt
      push "redirect-gateway def1 bypass-dhcp"
      push "dhcp-option DNS 208.67.222.222"
      push "dhcp-option DNS 208.67.220.220"
      keepalive 10 120
      comp-lzo
      max-clients 100
      user nobody
      group nogroup
      persist-key
      persist-tun
      status /var/log/openvpn-status.log
      log /var/log/openvpn.log
      verb 3






      ubuntu openvpn syslog






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Feb 7 at 12:08









      Jeff Schaller

      34.6k952115




      34.6k952115










      asked Jun 25 '16 at 17:15









      megloff

      2201210




      2201210




















          4 Answers
          4






          active

          oldest

          votes

















          up vote
          12
          down vote



          accepted










          The problem is that service config /lib/systemd/system/openvpn.service just calls /bin/true (I have no idea on why it wasn't just removed).
          Usable configuration might be found in /lib/systemd/system/openvpn@.service, but it still needs to be somewhat hacked.



          Solution that worked for me:



          1. Create dependency on networking service



          To protect it from overwriting, create it in a separate file in subdirectory:



           mkdir -p /lib/systemd/system/openvpn@.service.d


          Create a file in this directory. Its name must end with .conf, for example:



           vi /lib/systemd/system/openvpn@.service.d/local-after-ifup.conf


          Put following content in this file:



          [Unit]
          Requires=networking.service
          After=networking.service


          2. Try to start the server



          systemctl start openvpn@<CONF_NAME>.service


          Where CONF_NAME is the name of your .conf file in /etc/openvpn directory. In your case:



          systemctl start openvpn@server.service


          3. Enable service autostart if everything works



          systemctl enable openvpn@server.service





          share|improve this answer



























            up vote
            10
            down vote













            After searching all over I found this link:



            https://a20.net/bert/2016/09/27/openvpn-client-connection-not-started-on-ubuntu-16-04/



            edit /etc/default/openvpn, uncomment AUTOSTART=”all”
            sudo systemctl daemon-reload
            sudo service openvpn restart


            I boiled it down a bit more into :



            echo 'echo "AUTOSTART=""all""" >> /etc/default/openvpn' | sudo -s
            sudo systemctl daemon-reload
            sudo service openvpn restart





            share|improve this answer






















            • Used to work on my system months ago. No notable change on the system exect I didn't need openvpn for a while. And now it didn't work. This solved the problem... Thanks ! +1
              – gissehel
              Feb 7 at 12:03

















            up vote
            0
            down vote













            Due to a bug in /etc/init.d/openvpn ?



            # check if automatic startup is disabled by AUTOSTART=none
            if test "x$AUTOSTART" = "xnone" -o -z "$AUTOSTART" ; then
            log_warning_msg " Autostart disabled."
            exit 0
            fi
            if test -z "$AUTOSTART" -o "x$AUTOSTART" = "xall" ; then
            # all VPNs shall be started automatically
            ...


            It seems that if AUTOSTART is empty in /etc/default/openvpn then the scripts just exits.
            So either you choose Phillip's solution or you remove in line 119 the second condition:



            -o -z "$AUTOSTART"




            share








            New contributor




            Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
            Check out our Code of Conduct.
























              up vote
              -1
              down vote













              As an alternative to Phillip Moxley’s answer,
              you can edit the /etc/default/openvpn file
              and change the AUTOSTART line to



              AUTOSTART="server"





              share|improve this answer






















              • (1) Is this what you meant?  (1a) If yes, please write your answers like this in the future.  They should be self-sufficient — i.e., somebody should be able to read the question and your answer alone, and your answer should make sense.  But, if you’re building on somebody else’s answer, you should say so (referencing it by name and link).  (1b) If this isn’t what you meant, please edit your answer to make it clearer and more complete.  (2) Please don’t include “thanks” in an answer.  (3) How is AUTOSTART="server" different from AUTOSTART="all"?  Is it better?  Why? … (Cont’d)
                – Scott
                Apr 3 at 16:49










              • (Cont’d)   …   Again, please do not respond in comments;  edit your answer to make it clearer and more complete.
                – Scott
                Apr 3 at 16:49










              Your Answer







              StackExchange.ready(function()
              var channelOptions =
              tags: "".split(" "),
              id: "106"
              ;
              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: false,
              noModals: false,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: null,
              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%2funix.stackexchange.com%2fquestions%2f292091%2fubuntu-server-16-04-openvpn-seems-not-to-start-no-logs-get-written%23new-answer', 'question_page');

              );

              Post as a guest






























              4 Answers
              4






              active

              oldest

              votes








              4 Answers
              4






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes








              up vote
              12
              down vote



              accepted










              The problem is that service config /lib/systemd/system/openvpn.service just calls /bin/true (I have no idea on why it wasn't just removed).
              Usable configuration might be found in /lib/systemd/system/openvpn@.service, but it still needs to be somewhat hacked.



              Solution that worked for me:



              1. Create dependency on networking service



              To protect it from overwriting, create it in a separate file in subdirectory:



               mkdir -p /lib/systemd/system/openvpn@.service.d


              Create a file in this directory. Its name must end with .conf, for example:



               vi /lib/systemd/system/openvpn@.service.d/local-after-ifup.conf


              Put following content in this file:



              [Unit]
              Requires=networking.service
              After=networking.service


              2. Try to start the server



              systemctl start openvpn@<CONF_NAME>.service


              Where CONF_NAME is the name of your .conf file in /etc/openvpn directory. In your case:



              systemctl start openvpn@server.service


              3. Enable service autostart if everything works



              systemctl enable openvpn@server.service





              share|improve this answer
























                up vote
                12
                down vote



                accepted










                The problem is that service config /lib/systemd/system/openvpn.service just calls /bin/true (I have no idea on why it wasn't just removed).
                Usable configuration might be found in /lib/systemd/system/openvpn@.service, but it still needs to be somewhat hacked.



                Solution that worked for me:



                1. Create dependency on networking service



                To protect it from overwriting, create it in a separate file in subdirectory:



                 mkdir -p /lib/systemd/system/openvpn@.service.d


                Create a file in this directory. Its name must end with .conf, for example:



                 vi /lib/systemd/system/openvpn@.service.d/local-after-ifup.conf


                Put following content in this file:



                [Unit]
                Requires=networking.service
                After=networking.service


                2. Try to start the server



                systemctl start openvpn@<CONF_NAME>.service


                Where CONF_NAME is the name of your .conf file in /etc/openvpn directory. In your case:



                systemctl start openvpn@server.service


                3. Enable service autostart if everything works



                systemctl enable openvpn@server.service





                share|improve this answer






















                  up vote
                  12
                  down vote



                  accepted







                  up vote
                  12
                  down vote



                  accepted






                  The problem is that service config /lib/systemd/system/openvpn.service just calls /bin/true (I have no idea on why it wasn't just removed).
                  Usable configuration might be found in /lib/systemd/system/openvpn@.service, but it still needs to be somewhat hacked.



                  Solution that worked for me:



                  1. Create dependency on networking service



                  To protect it from overwriting, create it in a separate file in subdirectory:



                   mkdir -p /lib/systemd/system/openvpn@.service.d


                  Create a file in this directory. Its name must end with .conf, for example:



                   vi /lib/systemd/system/openvpn@.service.d/local-after-ifup.conf


                  Put following content in this file:



                  [Unit]
                  Requires=networking.service
                  After=networking.service


                  2. Try to start the server



                  systemctl start openvpn@<CONF_NAME>.service


                  Where CONF_NAME is the name of your .conf file in /etc/openvpn directory. In your case:



                  systemctl start openvpn@server.service


                  3. Enable service autostart if everything works



                  systemctl enable openvpn@server.service





                  share|improve this answer












                  The problem is that service config /lib/systemd/system/openvpn.service just calls /bin/true (I have no idea on why it wasn't just removed).
                  Usable configuration might be found in /lib/systemd/system/openvpn@.service, but it still needs to be somewhat hacked.



                  Solution that worked for me:



                  1. Create dependency on networking service



                  To protect it from overwriting, create it in a separate file in subdirectory:



                   mkdir -p /lib/systemd/system/openvpn@.service.d


                  Create a file in this directory. Its name must end with .conf, for example:



                   vi /lib/systemd/system/openvpn@.service.d/local-after-ifup.conf


                  Put following content in this file:



                  [Unit]
                  Requires=networking.service
                  After=networking.service


                  2. Try to start the server



                  systemctl start openvpn@<CONF_NAME>.service


                  Where CONF_NAME is the name of your .conf file in /etc/openvpn directory. In your case:



                  systemctl start openvpn@server.service


                  3. Enable service autostart if everything works



                  systemctl enable openvpn@server.service






                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Oct 4 '16 at 11:42









                  Wildfire

                  23634




                  23634






















                      up vote
                      10
                      down vote













                      After searching all over I found this link:



                      https://a20.net/bert/2016/09/27/openvpn-client-connection-not-started-on-ubuntu-16-04/



                      edit /etc/default/openvpn, uncomment AUTOSTART=”all”
                      sudo systemctl daemon-reload
                      sudo service openvpn restart


                      I boiled it down a bit more into :



                      echo 'echo "AUTOSTART=""all""" >> /etc/default/openvpn' | sudo -s
                      sudo systemctl daemon-reload
                      sudo service openvpn restart





                      share|improve this answer






















                      • Used to work on my system months ago. No notable change on the system exect I didn't need openvpn for a while. And now it didn't work. This solved the problem... Thanks ! +1
                        – gissehel
                        Feb 7 at 12:03














                      up vote
                      10
                      down vote













                      After searching all over I found this link:



                      https://a20.net/bert/2016/09/27/openvpn-client-connection-not-started-on-ubuntu-16-04/



                      edit /etc/default/openvpn, uncomment AUTOSTART=”all”
                      sudo systemctl daemon-reload
                      sudo service openvpn restart


                      I boiled it down a bit more into :



                      echo 'echo "AUTOSTART=""all""" >> /etc/default/openvpn' | sudo -s
                      sudo systemctl daemon-reload
                      sudo service openvpn restart





                      share|improve this answer






















                      • Used to work on my system months ago. No notable change on the system exect I didn't need openvpn for a while. And now it didn't work. This solved the problem... Thanks ! +1
                        – gissehel
                        Feb 7 at 12:03












                      up vote
                      10
                      down vote










                      up vote
                      10
                      down vote









                      After searching all over I found this link:



                      https://a20.net/bert/2016/09/27/openvpn-client-connection-not-started-on-ubuntu-16-04/



                      edit /etc/default/openvpn, uncomment AUTOSTART=”all”
                      sudo systemctl daemon-reload
                      sudo service openvpn restart


                      I boiled it down a bit more into :



                      echo 'echo "AUTOSTART=""all""" >> /etc/default/openvpn' | sudo -s
                      sudo systemctl daemon-reload
                      sudo service openvpn restart





                      share|improve this answer














                      After searching all over I found this link:



                      https://a20.net/bert/2016/09/27/openvpn-client-connection-not-started-on-ubuntu-16-04/



                      edit /etc/default/openvpn, uncomment AUTOSTART=”all”
                      sudo systemctl daemon-reload
                      sudo service openvpn restart


                      I boiled it down a bit more into :



                      echo 'echo "AUTOSTART=""all""" >> /etc/default/openvpn' | sudo -s
                      sudo systemctl daemon-reload
                      sudo service openvpn restart






                      share|improve this answer














                      share|improve this answer



                      share|improve this answer








                      edited Sep 2 '17 at 18:24

























                      answered Sep 2 '17 at 6:19









                      Phillip Moxley

                      20124




                      20124











                      • Used to work on my system months ago. No notable change on the system exect I didn't need openvpn for a while. And now it didn't work. This solved the problem... Thanks ! +1
                        – gissehel
                        Feb 7 at 12:03
















                      • Used to work on my system months ago. No notable change on the system exect I didn't need openvpn for a while. And now it didn't work. This solved the problem... Thanks ! +1
                        – gissehel
                        Feb 7 at 12:03















                      Used to work on my system months ago. No notable change on the system exect I didn't need openvpn for a while. And now it didn't work. This solved the problem... Thanks ! +1
                      – gissehel
                      Feb 7 at 12:03




                      Used to work on my system months ago. No notable change on the system exect I didn't need openvpn for a while. And now it didn't work. This solved the problem... Thanks ! +1
                      – gissehel
                      Feb 7 at 12:03










                      up vote
                      0
                      down vote













                      Due to a bug in /etc/init.d/openvpn ?



                      # check if automatic startup is disabled by AUTOSTART=none
                      if test "x$AUTOSTART" = "xnone" -o -z "$AUTOSTART" ; then
                      log_warning_msg " Autostart disabled."
                      exit 0
                      fi
                      if test -z "$AUTOSTART" -o "x$AUTOSTART" = "xall" ; then
                      # all VPNs shall be started automatically
                      ...


                      It seems that if AUTOSTART is empty in /etc/default/openvpn then the scripts just exits.
                      So either you choose Phillip's solution or you remove in line 119 the second condition:



                      -o -z "$AUTOSTART"




                      share








                      New contributor




                      Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                      Check out our Code of Conduct.





















                        up vote
                        0
                        down vote













                        Due to a bug in /etc/init.d/openvpn ?



                        # check if automatic startup is disabled by AUTOSTART=none
                        if test "x$AUTOSTART" = "xnone" -o -z "$AUTOSTART" ; then
                        log_warning_msg " Autostart disabled."
                        exit 0
                        fi
                        if test -z "$AUTOSTART" -o "x$AUTOSTART" = "xall" ; then
                        # all VPNs shall be started automatically
                        ...


                        It seems that if AUTOSTART is empty in /etc/default/openvpn then the scripts just exits.
                        So either you choose Phillip's solution or you remove in line 119 the second condition:



                        -o -z "$AUTOSTART"




                        share








                        New contributor




                        Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                        Check out our Code of Conduct.



















                          up vote
                          0
                          down vote










                          up vote
                          0
                          down vote









                          Due to a bug in /etc/init.d/openvpn ?



                          # check if automatic startup is disabled by AUTOSTART=none
                          if test "x$AUTOSTART" = "xnone" -o -z "$AUTOSTART" ; then
                          log_warning_msg " Autostart disabled."
                          exit 0
                          fi
                          if test -z "$AUTOSTART" -o "x$AUTOSTART" = "xall" ; then
                          # all VPNs shall be started automatically
                          ...


                          It seems that if AUTOSTART is empty in /etc/default/openvpn then the scripts just exits.
                          So either you choose Phillip's solution or you remove in line 119 the second condition:



                          -o -z "$AUTOSTART"




                          share








                          New contributor




                          Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                          Check out our Code of Conduct.









                          Due to a bug in /etc/init.d/openvpn ?



                          # check if automatic startup is disabled by AUTOSTART=none
                          if test "x$AUTOSTART" = "xnone" -o -z "$AUTOSTART" ; then
                          log_warning_msg " Autostart disabled."
                          exit 0
                          fi
                          if test -z "$AUTOSTART" -o "x$AUTOSTART" = "xall" ; then
                          # all VPNs shall be started automatically
                          ...


                          It seems that if AUTOSTART is empty in /etc/default/openvpn then the scripts just exits.
                          So either you choose Phillip's solution or you remove in line 119 the second condition:



                          -o -z "$AUTOSTART"





                          share








                          New contributor




                          Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                          Check out our Code of Conduct.








                          share


                          share






                          New contributor




                          Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                          Check out our Code of Conduct.









                          answered 4 mins ago









                          Alex

                          11




                          11




                          New contributor




                          Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                          Check out our Code of Conduct.





                          New contributor





                          Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                          Check out our Code of Conduct.






                          Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                          Check out our Code of Conduct.




















                              up vote
                              -1
                              down vote













                              As an alternative to Phillip Moxley’s answer,
                              you can edit the /etc/default/openvpn file
                              and change the AUTOSTART line to



                              AUTOSTART="server"





                              share|improve this answer






















                              • (1) Is this what you meant?  (1a) If yes, please write your answers like this in the future.  They should be self-sufficient — i.e., somebody should be able to read the question and your answer alone, and your answer should make sense.  But, if you’re building on somebody else’s answer, you should say so (referencing it by name and link).  (1b) If this isn’t what you meant, please edit your answer to make it clearer and more complete.  (2) Please don’t include “thanks” in an answer.  (3) How is AUTOSTART="server" different from AUTOSTART="all"?  Is it better?  Why? … (Cont’d)
                                – Scott
                                Apr 3 at 16:49










                              • (Cont’d)   …   Again, please do not respond in comments;  edit your answer to make it clearer and more complete.
                                – Scott
                                Apr 3 at 16:49














                              up vote
                              -1
                              down vote













                              As an alternative to Phillip Moxley’s answer,
                              you can edit the /etc/default/openvpn file
                              and change the AUTOSTART line to



                              AUTOSTART="server"





                              share|improve this answer






















                              • (1) Is this what you meant?  (1a) If yes, please write your answers like this in the future.  They should be self-sufficient — i.e., somebody should be able to read the question and your answer alone, and your answer should make sense.  But, if you’re building on somebody else’s answer, you should say so (referencing it by name and link).  (1b) If this isn’t what you meant, please edit your answer to make it clearer and more complete.  (2) Please don’t include “thanks” in an answer.  (3) How is AUTOSTART="server" different from AUTOSTART="all"?  Is it better?  Why? … (Cont’d)
                                – Scott
                                Apr 3 at 16:49










                              • (Cont’d)   …   Again, please do not respond in comments;  edit your answer to make it clearer and more complete.
                                – Scott
                                Apr 3 at 16:49












                              up vote
                              -1
                              down vote










                              up vote
                              -1
                              down vote









                              As an alternative to Phillip Moxley’s answer,
                              you can edit the /etc/default/openvpn file
                              and change the AUTOSTART line to



                              AUTOSTART="server"





                              share|improve this answer














                              As an alternative to Phillip Moxley’s answer,
                              you can edit the /etc/default/openvpn file
                              and change the AUTOSTART line to



                              AUTOSTART="server"






                              share|improve this answer














                              share|improve this answer



                              share|improve this answer








                              edited Apr 3 at 16:35









                              Scott

                              6,42742550




                              6,42742550










                              answered Apr 3 at 16:02









                              Gerard

                              1




                              1











                              • (1) Is this what you meant?  (1a) If yes, please write your answers like this in the future.  They should be self-sufficient — i.e., somebody should be able to read the question and your answer alone, and your answer should make sense.  But, if you’re building on somebody else’s answer, you should say so (referencing it by name and link).  (1b) If this isn’t what you meant, please edit your answer to make it clearer and more complete.  (2) Please don’t include “thanks” in an answer.  (3) How is AUTOSTART="server" different from AUTOSTART="all"?  Is it better?  Why? … (Cont’d)
                                – Scott
                                Apr 3 at 16:49










                              • (Cont’d)   …   Again, please do not respond in comments;  edit your answer to make it clearer and more complete.
                                – Scott
                                Apr 3 at 16:49
















                              • (1) Is this what you meant?  (1a) If yes, please write your answers like this in the future.  They should be self-sufficient — i.e., somebody should be able to read the question and your answer alone, and your answer should make sense.  But, if you’re building on somebody else’s answer, you should say so (referencing it by name and link).  (1b) If this isn’t what you meant, please edit your answer to make it clearer and more complete.  (2) Please don’t include “thanks” in an answer.  (3) How is AUTOSTART="server" different from AUTOSTART="all"?  Is it better?  Why? … (Cont’d)
                                – Scott
                                Apr 3 at 16:49










                              • (Cont’d)   …   Again, please do not respond in comments;  edit your answer to make it clearer and more complete.
                                – Scott
                                Apr 3 at 16:49















                              (1) Is this what you meant?  (1a) If yes, please write your answers like this in the future.  They should be self-sufficient — i.e., somebody should be able to read the question and your answer alone, and your answer should make sense.  But, if you’re building on somebody else’s answer, you should say so (referencing it by name and link).  (1b) If this isn’t what you meant, please edit your answer to make it clearer and more complete.  (2) Please don’t include “thanks” in an answer.  (3) How is AUTOSTART="server" different from AUTOSTART="all"?  Is it better?  Why? … (Cont’d)
                              – Scott
                              Apr 3 at 16:49




                              (1) Is this what you meant?  (1a) If yes, please write your answers like this in the future.  They should be self-sufficient — i.e., somebody should be able to read the question and your answer alone, and your answer should make sense.  But, if you’re building on somebody else’s answer, you should say so (referencing it by name and link).  (1b) If this isn’t what you meant, please edit your answer to make it clearer and more complete.  (2) Please don’t include “thanks” in an answer.  (3) How is AUTOSTART="server" different from AUTOSTART="all"?  Is it better?  Why? … (Cont’d)
                              – Scott
                              Apr 3 at 16:49












                              (Cont’d)   …   Again, please do not respond in comments;  edit your answer to make it clearer and more complete.
                              – Scott
                              Apr 3 at 16:49




                              (Cont’d)   …   Again, please do not respond in comments;  edit your answer to make it clearer and more complete.
                              – Scott
                              Apr 3 at 16:49

















                               

                              draft saved


                              draft discarded















































                               


                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function ()
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f292091%2fubuntu-server-16-04-openvpn-seems-not-to-start-no-logs-get-written%23new-answer', 'question_page');

                              );

                              Post as a guest













































































                              Popular posts from this blog

                              How to check contact read email or not when send email to Individual?

                              Bahrain

                              Postfix configuration issue with fips on centos 7; mailgun relay