[SRU] vtun not running on ubuntu 20.04 LTS

Bug #1881522 reported by Willian
28
This bug affects 4 people
Affects Status Importance Assigned to Milestone
vtun (Ubuntu)
Status tracked in Noble
Focal
Fix Released
Undecided
Unassigned
Jammy
Fix Released
Undecided
Unassigned
Mantic
Fix Released
Undecided
Unassigned
Noble
Fix Released
Undecided
Unassigned

Bug Description

[ Impact ]

vtund can not be run as a server as the <-s> option is not available.
The manpage at https://manpages.ubuntu.com/manpages/noble/en/man8/vtund.8.html says about <-s> which can be used to run vtud as a server. But the Ubuntu releases from Focal only have <-i> which allows vtund to run as a inted server.

The current package when executed after installing shows:

$ vtund
vtund[3175]: Can not open /etc/vtund.conf
VTun ver 3.X 11/24/2021
Usage:
  Server:
 vtund <-i> [-f file] [-P port] [-L local address]
  Client:
 vtund [-f file] [-q] [-p] [-m] [-t timeout] <host profile> <server address>

The <-s> option is not there in the Server options.

[ Test Plan ]

1. First simple test (no need to test the package even)
   - check the build log to see if it says autoconf has found fork(). With the bug fixed the log will have:

checking for fork... yes
checking for vfork... yes
checking for working fork... yes
checking for working vfork... (cached) yes

2. Test the package.
   - execute the command vtund.
     With the fixed package it will show:

Usage:
  Server:
 vtund <-s|-i> [-f file] [-P port] [-L local address]

[ Where problems could occur ]

Looking at the diff between 3.0.3-4build1 and 3.0.4-2, I can see the code is mostly same for the server and listener. upstream has only added the check for fork() and then moved the server and listerner code in #ifdef. Since the (now) disabled part of the code has been used in pre-Focal, I think there should not be any regression.
But again, this part of the code has never been used in Focal onwards, so I can not tell for sure that other parts of the system will not affect the server execution.

[ Other Info ]
Debian also had the same problem of fork() not getting detected and that was fixed in 3.0.4-2. But for some reason (I will really like to know why) Ubuntu build systems of Focal and Jammy could not detect fork() is present. And since the package was not rebuilt after Jammy, so the problem remained.

This is the build log from Debian: https://buildd.debian.org/status/fetch.php?pkg=vtun&arch=amd64&ver=3.0.4-2&stamp=1573583517&raw=0
This is the build log from Ubuntu: https://launchpadlibrarian.net/451222645/buildlog_ubuntu-focal-amd64.vtun_3.0.4-2_BUILDING.txt.gz

The Debian build log has:
checking for fork... yes
checking for vfork... yes
checking for working fork... yes
checking for working vfork... (cached) yes

Whereas the build log from Ubuntu of the same version does not have fork in it.

[ Original Bug Description ]

When installing a new server with Ubuntu 20.04 LTS with vtun_3.0.4-2_amd64 does not run the service as a server.
It has possibly errors in the compilation for Ubuntu Focal.
It runs normally on version 3.0.3-4build1 on Ubuntu 18.04 and also on the version of the package available in the Debian repository in the same version at: http://ftp.us.debian.org/debian/pool/main/v/vtun/vtun_3.0.4-2_amd64.deb

Error log in the current version Ubuntu(Focal).

vtun_3.0.4-2_amd64.deb: Exact Size 61068 Byte (59.6 kByte)

May 20 01:44:05 server vtun [3177]: * Starting virtual tunnel daemon server vtun
May 20 01:44:05 server vtun [3186]: VTun see 3.X 11/11/2019
May 20 01:44:05 server vtun [3186]: Usage:
May 20 01:44:05 server vtun [3186]: Server:
May 20 01:44:05 server vtun [3186]: # 011vtund <-i> [-f file] [-P port] [-L local address]
May 20 01:44:05 server vtun [3186]: Client:
May 20 01:44:05 server vtun [3186]: # 011vtund [-f file] [-q] [-p] [-m] [-t timeout] <host profile> <server address>
May 20 01:44:05 server systemd [1]: vtun.service: Control process exited, code = exited, status = 1 / FAILURE
May 20 01:44:05 server systemd [1]: vtun.service: Failed with result 'exit-code'.
May 20 01:44:05 server systemd [1]: Failed to start LSB: virtual tunnel over TCP / IP networks.

In the version that works the following return:

VTun ver 3.X 02/05/2018
Usage:
  Server:
        vtund <-s> [-f file] [-P port] [-L local address]
  Client:
        vtund [-f file] [-p] [-m] [-t timeout] <host profile> <server address>

Version running of Debian repository:

vtun_3.0.4-2_amd64.deb: Exact Size 71124 Byte (69.5 kByte)

VTun ver 3.X 11/11/2019
Usage:
  Server:
        vtund <-s | -i> [-f file] [-P port] [-L local address]
  Client:
        vtund [-f file] [-q] [-p] [-m] [-t timeout] <host profile> <server address>

In the log error, such as option -i in the new version Focal and in the previous versions running, -s for the server environment.

#lsb_release -rd
Description: Ubuntu 20.04 LTS
Release: 20.04

vtun:
   Installed: 3.0.4-2
   Candidate: 3.0.4-2
   Version table:
     3.0.4-2 500
        500 http://br.archive.ubuntu.com/ubuntu focal/universe amd64 Packages
 *** 3.0.4-2 100
        100 /var/lib/dpkg/status

Willian (wgalev)
description: updated
Willian (wgalev)
description: updated
Willian (wgalev)
description: updated
Revision history for this message
Maxim N. Kostrikin (mkostrikin) wrote :

Look like the build process has missing `HAVE_WORKING_FORK` at the build stage. For me, the issue was fixed on by rebuild from the source (so the source is correct), probably original build process affects HAVE_WORKING_FORK
Unfortunately, I have no idea, how to fix the package.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in vtun (Ubuntu):
status: New → Confirmed
Revision history for this message
Ludovic LEVET (llevet) wrote :

Same problem on Ubuntu 22.04.3 LTS

Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

I can see the problem on all releases from Focal to Noble.

And, looking at the code I can see that the standalone server will get disabled for this. It can only work via inetd. But the problem does not exist in Debian unstable image.

Changed in vtun (Ubuntu Focal):
assignee: nobody → Sudip Mukherjee (sudipmuk)
Changed in vtun (Ubuntu Jammy):
assignee: nobody → Sudip Mukherjee (sudipmuk)
Changed in vtun (Ubuntu Mantic):
assignee: nobody → Sudip Mukherjee (sudipmuk)
Changed in vtun (Ubuntu Noble):
assignee: nobody → Sudip Mukherjee (sudipmuk)
Changed in vtun (Ubuntu Focal):
status: New → In Progress
Changed in vtun (Ubuntu Jammy):
status: New → In Progress
Changed in vtun (Ubuntu Mantic):
status: New → In Progress
Changed in vtun (Ubuntu Noble):
status: Confirmed → In Progress
Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

debdiff for Noble attached.

summary: - vtun not running on ubuntu 20.04 LTS
+ [SRU] vtun not running on ubuntu 20.04 LTS
description: updated
Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

debdiff for Mantic attached.

Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

debdiff for Jammy attached.

Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

debdiff for Focal attached.

Changed in vtun (Ubuntu Focal):
status: In Progress → Confirmed
Changed in vtun (Ubuntu Jammy):
status: In Progress → Confirmed
Changed in vtun (Ubuntu Mantic):
status: In Progress → Confirmed
Changed in vtun (Ubuntu Noble):
status: In Progress → Confirmed
Changed in vtun (Ubuntu Focal):
assignee: Sudip Mukherjee (sudipmuk) → nobody
Changed in vtun (Ubuntu Jammy):
assignee: Sudip Mukherjee (sudipmuk) → nobody
Changed in vtun (Ubuntu Mantic):
assignee: Sudip Mukherjee (sudipmuk) → nobody
Changed in vtun (Ubuntu Noble):
assignee: Sudip Mukherjee (sudipmuk) → nobody
Revision history for this message
Julian Andres Klode (juliank) wrote :

Sudip, can you please add more explanation to the changelog how autoupdate fixes this, because that is not easy to see the connection.

Changed in vtun (Ubuntu Focal):
status: Confirmed → Incomplete
Changed in vtun (Ubuntu Jammy):
status: Confirmed → Incomplete
Changed in vtun (Ubuntu Mantic):
status: Confirmed → Incomplete
Changed in vtun (Ubuntu Noble):
status: Confirmed → Incomplete
Revision history for this message
Sudip Mukherjee (sudipmuk) wrote (last edit ):

New debdiffs with modified changelog attached.

Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :
Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :
Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :
Changed in vtun (Ubuntu Focal):
status: Incomplete → Confirmed
Changed in vtun (Ubuntu Jammy):
status: Incomplete → Confirmed
Changed in vtun (Ubuntu Mantic):
status: Incomplete → Confirmed
Changed in vtun (Ubuntu Noble):
status: Incomplete → Confirmed
Revision history for this message
Lukas Märdian (slyon) wrote :
Download full text (3.4 KiB)

I can see relevant logs in the latest LP buildlog:
```
 debian/rules build
autoconf
configure.in:11: warning: The macro `AC_CONFIG_HEADER' is obsolete.
configure.in:11: You should run autoupdate.
./lib/autoconf/status.m4:719: AC_CONFIG_HEADER is expanded from...
configure.in:11: the top level
configure.in:82: warning: The macro `AC_CANONICAL_SYSTEM' is obsolete.
configure.in:82: You should run autoupdate.
./lib/autoconf/general.m4:2081: AC_CANONICAL_SYSTEM is expanded from...
configure.in:82: the top level
configure.in:86: warning: AC_PROG_LEX without either yywrap or noyywrap is obsolete
./lib/autoconf/programs.m4:716: _AC_PROG_LEX is expanded from...
./lib/autoconf/programs.m4:709: AC_PROG_LEX is expanded from...
configure.in:86: the top level
configure.in:95: warning: The macro `AC_HEADER_STDC' is obsolete.
configure.in:95: You should run autoupdate.
./lib/autoconf/headers.m4:704: AC_HEADER_STDC is expanded from...
configure.in:95: the top level
configure.in:124: warning: The macro `AC_CHECKING' is obsolete.
configure.in:124: You should run autoupdate.
./lib/autoconf/general.m4:2499: AC_CHECKING is expanded from...
configure.in:124: the top level
configure.in:136: warning: The macro `AC_CHECKING' is obsolete.
configure.in:136: You should run autoupdate.
./lib/autoconf/general.m4:2499: AC_CHECKING is expanded from...
configure.in:136: the top level
configure.in:170: warning: The macro `AC_CHECKING' is obsolete.
configure.in:170: You should run autoupdate.
./lib/autoconf/general.m4:2499: AC_CHECKING is expanded from...
configure.in:170: the top level
configure.in:180: warning: The macro `AC_CHECKING' is obsolete.
configure.in:180: You should run autoupdate.
./lib/autoconf/general.m4:2499: AC_CHECKING is expanded from...
configure.in:180: the top level
configure.in:197: warning: The macro `AC_CHECKING' is obsolete.
configure.in:197: You should run autoupdate.
./lib/autoconf/general.m4:2499: AC_CHECKING is expanded from...
configure.in:197: the top level
configure.in:212: warning: The macro `AC_CHECKING' is obsolete.
configure.in:212: You should run autoupdate.
./lib/autoconf/general.m4:2499: AC_CHECKING is expanded from...
configure.in:212: the top level
configure.in:231: warning: The macro `AC_CHECKING' is obsolete.
configure.in:231: You should run autoupdate.
./lib/autoconf/general.m4:2499: AC_CHECKING is expanded from...
configure.in:231: the top level
configure.in:288: warning: AC_OUTPUT should be used without arguments.
configure.in:288: You should run autoupdate.
```

Which is resolved after applying the debdiff:
```
 debian/rules build
autoupdate
autoupdate: warning: autoconf input should be named 'configure.ac', not 'configure.in'
configure.in:95: warning: The preprocessor macro `STDC_HEADERS' is obsolete.
  Except in unusual embedded environments, you can safely include all
  ISO C90 headers unconditionally.
autoconf
configure.in:86: warning: AC_PROG_LEX without either yywrap or noyywrap is obsolete
./lib/autoconf/programs.m4:716: _AC_PROG_LEX is expanded from...
./lib/autoconf/programs.m4:709: AC_PROG_LEX is expanded from...
configure.in:86: the top level
configure.in:95: warning: The preprocessor macro `STDC_HEADERS' is obsolete.
c...

Read more...

Lukas Märdian (slyon)
Changed in vtun (Ubuntu Mantic):
status: Confirmed → In Progress
Changed in vtun (Ubuntu Jammy):
status: Confirmed → In Progress
Changed in vtun (Ubuntu Focal):
status: Confirmed → In Progress
Changed in vtun (Ubuntu Noble):
status: Confirmed → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package vtun - 3.0.4-2ubuntu1

---------------
vtun (3.0.4-2ubuntu1) noble; urgency=medium

  * Fix failure to run vtun in standalone server mode. (LP: #1881522)
    - run autoupdate to update configure.in to use the syntax of
      current version of Autoconf.

 -- Sudip Mukherjee <email address hidden> Sun, 18 Feb 2024 14:29:21 +0000

Changed in vtun (Ubuntu Noble):
status: Fix Committed → Fix Released
Revision history for this message
Timo Aaltonen (tjaalton) wrote : Please test proposed package

Hello Willian, or anyone else affected,

Accepted vtun into mantic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/vtun/3.0.4-2ubuntu0.23.10.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-mantic to verification-done-mantic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-mantic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in vtun (Ubuntu Mantic):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-mantic
Changed in vtun (Ubuntu Jammy):
status: In Progress → Fix Committed
tags: added: verification-needed-jammy
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

Hello Willian, or anyone else affected,

Accepted vtun into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/vtun/3.0.4-2ubuntu0.22.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in vtun (Ubuntu Focal):
status: In Progress → Fix Committed
tags: added: verification-needed-focal
Revision history for this message
Timo Aaltonen (tjaalton) wrote :

Hello Willian, or anyone else affected,

Accepted vtun into focal-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/vtun/3.0.4-2ubuntu0.20.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-focal to verification-done-focal. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-focal. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

I can confirm that the vtun package in mantic-proposed has fixed the bug for me.

Test done:

1. Install vtun from mantic-proposed
2. Execute vtund.

$ vtund
vtund[2312]: Can not open /etc/vtund.conf
VTun ver 3.X 02/18/2024
Usage:
  Server:
 vtund <-s|-i> [-f file] [-P port] [-L local address]
  Client:
 vtund [-f file] [-q] [-p] [-m] [-t timeout] <host profile> <server address>

The help message shows "-s" has now been enabled in vtund.

Test result: the errors with vtun has been fixed.

Package tested:

$ dpkg -l | grep vtun
ii vtun 3.0.4-2ubuntu0.23.10.1 amd64 virtual tunnel over TCP/IP networks

Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

I can confirm that the vtun package in jammy-proposed has fixed the bug for me.

Test done:

1. Install vtun from jammy-proposed
2. Execute vtund.

$ vtund
vtund[1567]: Can not open /etc/vtund.conf
VTun ver 3.X 02/18/2024
Usage:
  Server:
 vtund <-s|-i> [-f file] [-P port] [-L local address]
  Client:
 vtund [-f file] [-q] [-p] [-m] [-t timeout] <host profile> <server address>

The help message shows "-s" has now been enabled in vtund.

Test result: the errors with vtun has been fixed.

Package tested:

$ dpkg -l | grep vtun
ii vtun 3.0.4-2ubuntu0.22.04.1 amd64 virtual tunnel over TCP/IP networks

Revision history for this message
Sudip Mukherjee (sudipmuk) wrote :

I can confirm that the vtun package in focal-proposed has fixed the bug for me.

Test done:

1. Install vtun from focal-proposed
2. Execute vtund.

$ vtund
vtund[2554]: Can not open /etc/vtund.conf
VTun ver 3.X 02/18/2024
Usage:
  Server:
 vtund <-s|-i> [-f file] [-P port] [-L local address]
  Client:
 vtund [-f file] [-q] [-p] [-m] [-t timeout] <host profile> <server address>

The help message shows "-s" has now been enabled in vtund.

Test result: the errors with vtun has been fixed.

Package tested:

$ dpkg -l | grep vtun
ii vtun 3.0.4-2ubuntu0.20.04.1 amd64 virtual tunnel over TCP/IP networks

tags: added: verification-done verification-done-focal verification-done-jammy verification-done-mantic
removed: verification-needed verification-needed-focal verification-needed-jammy verification-needed-mantic
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package vtun - 3.0.4-2ubuntu0.23.10.1

---------------
vtun (3.0.4-2ubuntu0.23.10.1) mantic; urgency=medium

  * Fix failure to run vtun in standalone server mode. (LP: #1881522)
    - run autoupdate to update configure.in to use the syntax of
      current version of Autoconf.

 -- Sudip Mukherjee <email address hidden> Sun, 18 Feb 2024 14:33:10 +0000

Changed in vtun (Ubuntu Mantic):
status: Fix Committed → Fix Released
Revision history for this message
Chris Halse Rogers (raof) wrote : Update Released

The verification of the Stable Release Update for vtun has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Andreas Hasenack (ahasenack) wrote (last edit ):

Running autoupdate, or any such tool (like autoreconf and others) in an SRU is a bit scary. The change it introduces to the configure script cannot be easily verified, as it's usually a huge diff.

What I would suggest for future SRUs of this type, is to think carefully about what could go wrong with such a fix. Mainly, that the new ./configure could detect different things, and build the binary in a different way. Which may be exactly what we want for the SRU (like in this case here), but still, it's a regression potential.

I would suggest to carefully check the ./configure output from before and now, to see what else might have changed. Or perhaps there is another tool to show us that from the resulting binaries (diffoscope perhaps?).

For this SRU, I did a quick check of the dependencies of the new jammy build, and they remained the same. I also checked the configure output between the build from the release pocket, and the build from the proposed pocket. Saw some differences of course, but nothing that struck me as odd or that needed further inspection.

That all said and done, there are multiple build failures of this package:
jammy: riscv64 (and it built before)
focal: armhf, ppc64el, riscv64 (which also built before)

I'll retry these, but until then, this cannot be released.

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

The rebuilds succeeded, now we need to wait for the excuses report to be updated with the new tests that can now run in the architectures that weren't built before, but are built now.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package vtun - 3.0.4-2ubuntu0.22.04.1

---------------
vtun (3.0.4-2ubuntu0.22.04.1) jammy; urgency=medium

  * Fix failure to run vtun in standalone server mode. (LP: #1881522)
    - run autoupdate to update configure.in to use the syntax of
      current version of Autoconf.

 -- Sudip Mukherjee <email address hidden> Sun, 18 Feb 2024 14:35:37 +0000

Changed in vtun (Ubuntu Jammy):
status: Fix Committed → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package vtun - 3.0.4-2ubuntu0.20.04.1

---------------
vtun (3.0.4-2ubuntu0.20.04.1) focal; urgency=medium

  * Fix failure to run vtun in standalone server mode. (LP: #1881522)
    - run autoupdate to update configure.in to use the syntax of
      current version of Autoconf.

 -- Sudip Mukherjee <email address hidden> Sun, 18 Feb 2024 14:37:36 +0000

Changed in vtun (Ubuntu Focal):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.