Repository: zerotier/ZeroTierOne

Issue #355: Update from 1.1.4 to 1.1.8 hangs on Ubuntu 14.04 LTS
Created: 2016-07-12T07:21:52Z
Hi,
While upgrading from 1.1.4 to 1.1.8 on Ubuntu the update hang after asking if it should replace the config file and did not go on. I had to manually kill the process, then do a dpkg-reconfigure to make things work. ZT seems to operate without issues after this. This happened to two non-identical Ubuntu 14.04 servers, but did not happen on 15.10.
This was the (end of) the output of the script, omitting the apt-get update part.
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  linux-headers-3.13.0-86 linux-headers-3.13.0-86-generic
  linux-headers-3.13.0-87 linux-headers-3.13.0-87-generic
  linux-image-3.13.0-86-generic linux-image-3.13.0-87-generic
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  libhttp-parser2.1 libnatpmp1
Suggested packages:
  natpmp-utils minissdpd
The following NEW packages will be installed:
  libhttp-parser2.1 libnatpmp1
The following packages will be upgraded:
  zerotier-one
1 upgraded, 2 newly installed, 0 to remove and 17 not upgraded.
Need to get 257 kB of archives.
After this operation, 144 kB disk space will be freed.
Get:1 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu/ trusty/universe libhttp-parser2.1 amd64 2.1-2 [18.2 kB]
Get:2 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu/ trusty/main libnatpmp1 amd64 20110808-3ubuntu2 [8,460 B]
Get:3 http://download.zerotier.com/debian/trusty/ trusty/main zerotier-one amd64 1.1.8 [231 kB]
Fetched 257 kB in 0s (262 kB/s)                            
Selecting previously unselected package libhttp-parser2.1:amd64.
(Reading database ... 191584 files and directories currently installed.)
Preparing to unpack .../libhttp-parser2.1_2.1-2_amd64.deb ...
Unpacking libhttp-parser2.1:amd64 (2.1-2) ...
Selecting previously unselected package libnatpmp1.
Preparing to unpack .../libnatpmp1_20110808-3ubuntu2_amd64.deb ...
Unpacking libnatpmp1 (20110808-3ubuntu2) ...
Preparing to unpack .../zerotier-one_1.1.8_amd64.deb ...
Unpacking zerotier-one (1.1.8) over (1.1.4) ...
Processing triggers for ureadahead (0.100.0-16) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Setting up libhttp-parser2.1:amd64 (2.1-2) ...
Setting up libnatpmp1 (20110808-3ubuntu2) ...
Setting up zerotier-one (1.1.8) ...

Configuration file '/etc/init.d/zerotier-one'
 ==> File on system created by you or by a script.
 ==> File also in package provided by package maintainer.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.
*** zerotier-one (Y/I/N/O/D/Z) [default=N] ? y


After which the process hang endlessley. This is what I could see in ps -axf:
  975 ?        Ss     0:00 /usr/sbin/sshd -D
24895 ?        Ss     0:00  \_ sshd: ubuntu [priv] 
24945 ?        S      0:00  |   \_ sshd: ubuntu@pts/0  
24946 pts/0    Ss     0:00  |       \_ -bash
24966 pts/0    S+     0:00  |           \_ bash /tmp/zt-install.sh
25050 pts/0    S+     0:00  |               \_ sudo apt-get install -y zerotier-one
25051 pts/0    S+     3:38  |                   \_ apt-get install -y zerotier-one
25702 pts/1    Ss+    0:00  |                       \_ /usr/bin/dpkg --status-fd 68 --configure libhttp-parser2.1:amd64 libnatpmp1:amd64 zerotier-one:amd64

After killing the dpkg process manually, installation finished with this:
E: Sub-process /usr/bin/dpkg exited unexpectedly

*** Enabling and starting zerotier-one service...
 System start/stop links for /etc/init.d/zerotier-one already exist.
ZeroTier One already running.

*** Waiting for identity generation...

*** Success! You are connected to port 8796cfa5cb of Earth's planetary smart switch.

After this I did a dpkg-reconfigure and it ran fine:
sudo dpkg --configure -a
Setting up zerotier-one (1.1.8) ...

Configuration file '/etc/init.d/zerotier-one'
 ==> File on system created by you or by a script.
 ==> File also in package provided by package maintainer.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.
*** zerotier-one (Y/I/N/O/D/Z) [default=N] ? i
Installing new version of config file /etc/init.d/zerotier-one ...
zerotier-one start/running, process 26171
Processing triggers for libc-bin (2.19-0ubuntu6.9) ...
Processing triggers for ureadahead (0.100.0-16) ...

Notice that there is no mention of libhttp-parser here, even though previously that was the point where the process hang.
I do not know if this is a ZeroTier issue or if it has something to do with libhttp-parser, but maybe at least this report will help a bit.
lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.4 LTS
Release:        14.04
Codename:       trusty

Best,
Adam

Duplicate issue #367: Waiting for identity generation
Created: 2016-07-25T01:26:32Z
When I update ZT 1.1.4 to 1.1.14 in Ubuntu 14.04, I use "curl -s https://install.zerotier.com | sudo bash" command.But when it comes 'Waiting for identity generation', it will remain and report a problem to system.

Closing comment (2016-07-25T15:47:07Z): Turns out this is a duplicate of #355 -- will try this ourselves and should be able to fix the installer script.