Skip to content

[2016.3.0] salt-master should not set "KillMode=process" in unit file #33665

Closed

Description

@wwentland

Description of Issue/Question

The salt-master does not seem to restart cleanly with the current bootstrap script. If you install or bootstrap it you'll see the following in its log file and the master does not accept any connections:

I verified that it does install without problems directly from the repository by following the steps outlined in http://repo.saltstack.com/#debian though.

You have to kill the salt-master processes explicitly to get it working again.

EDIT: It might be better to report this against salt-bootstrap

# cat /var/log/salt/master 
2016-06-01 12:46:35,414 [salt.cli.daemons ][INFO    ][2650] Setting up the Salt Master
2016-06-01 12:46:36,429 [salt.crypt       ][INFO    ][2650] Generating master keys: /etc/salt/pki/master
2016-06-01 12:46:36,583 [salt.daemons.masterapi][INFO    ][2650] Preparing the root key for local communication
2016-06-01 12:46:36,590 [salt.cli.daemons ][WARNING ][2650] IMPORTANT: Do not use md5 hashing algorithm! Please set "hash_type" to sha256 in Salt Master config!
2016-06-01 12:46:36,590 [salt.cli.daemons ][INFO    ][2650] The Salt Master is starting up
2016-06-01 12:46:36,595 [salt.master      ][INFO    ][2650] salt-master is starting as user 'root'
2016-06-01 12:46:36,595 [salt.master      ][INFO    ][2650] Current values for max open files soft/hard setting: 16384/16384
2016-06-01 12:46:36,596 [salt.master      ][INFO    ][2650] The value for the 'max_open_files' setting, 100000, is higher than what the user running salt is allowed to raise to, 16384. Defaulting to 16384.
2016-06-01 12:46:36,597 [salt.master      ][INFO    ][2650] Creating master process manager
2016-06-01 12:46:36,597 [salt.master      ][INFO    ][2650] Creating master publisher process
2016-06-01 12:46:36,599 [salt.master      ][INFO    ][2650] Creating master event publisher process
2016-06-01 12:46:36,613 [salt.transport.zeromq][INFO    ][2772] Starting the Salt Publisher on tcp://0.0.0.0:4505
2016-06-01 12:46:36,613 [salt.transport.zeromq][INFO    ][2772] Starting the Salt Puller on ipc:///var/run/salt/master/publish_pull.ipc
2016-06-01 12:46:36,612 [salt.master      ][INFO    ][2650] Creating master maintenance process
2016-06-01 12:46:36,615 [salt.master      ][INFO    ][2650] Creating master reactor process
2016-06-01 12:46:39,722 [salt.cli.daemons ][INFO    ][2834] Setting up the Salt Master
2016-06-01 12:46:39,722 [salt.utils.verify][WARNING ][2834] Unable to bind socket, error: [Errno 98] Address already in use
2016-06-01 12:46:39,722 [salt.cli.daemons ][INFO    ][2834] The Salt Master is shut down

Setup

A simple jessie installation (in vagrant in this case).

Steps to Reproduce Issue

# ./bootstrap_salt.sh -M
 *  INFO: /bin/sh ./bootstrap_salt.sh -- Version 2016.05.11

 *  INFO: System Information:
 *  INFO:   CPU:          GenuineIntel
 *  INFO:   CPU Arch:     x86_64
 *  INFO:   OS Name:      Linux
 *  INFO:   OS Version:   3.16.0-4-amd64
 *  INFO:   Distribution: Debian 8.4

 *  INFO: Installing minion
 *  INFO: Installing master
 *  INFO: Found function install_debian_8_deps
 *  INFO: Found function install_debian_8_stable
 *  INFO: Found function install_debian_restart_daemons
 *  INFO: Found function daemons_running
 *  INFO: Found function install_debian_check_services
 *  INFO: Running install_debian_8_deps()
Ign http://httpredir.debian.org jessie InRelease
Hit http://httpredir.debian.org jessie-updates InRelease
Hit http://httpredir.debian.org jessie Release.gpg
Hit http://httpredir.debian.org jessie-updates/main Sources
Get:1 http://httpredir.debian.org jessie-updates/main amd64 Packages/DiffIndex [3,472 B]
Get:2 http://httpredir.debian.org jessie-updates/main Translation-en/DiffIndex [1,720 B]
Hit http://httpredir.debian.org jessie Release
Hit http://httpredir.debian.org jessie/main Sources
Hit http://httpredir.debian.org jessie/main amd64 Packages
Hit http://httpredir.debian.org jessie/main Translation-en
Hit http://security.debian.org jessie/updates InRelease
Hit http://security.debian.org jessie/updates/main Sources
Hit http://security.debian.org jessie/updates/main amd64 Packages
Hit http://security.debian.org jessie/updates/main Translation-en
Fetched 5,192 B in 5s (964 B/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
wget is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 12 not upgraded.
Reading package lists...
Building dependency tree...
Reading state information...
debian-archive-keyring is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 12 not upgraded.
Ign http://httpredir.debian.org jessie InRelease
Hit http://httpredir.debian.org jessie-updates InRelease
Hit http://httpredir.debian.org jessie Release.gpg
Hit http://httpredir.debian.org jessie-updates/main Sources
Get:1 http://httpredir.debian.org jessie-updates/main amd64 Packages/DiffIndex [3,472 B]
Get:2 http://httpredir.debian.org jessie-updates/main Translation-en/DiffIndex [1,720 B]
Hit http://httpredir.debian.org jessie Release
Hit http://httpredir.debian.org jessie/main Sources
Hit http://httpredir.debian.org jessie/main Translation-en
Hit http://httpredir.debian.org jessie/main amd64 Packages
Hit http://security.debian.org jessie/updates InRelease
Hit http://security.debian.org jessie/updates/main Sources
Hit http://security.debian.org jessie/updates/main amd64 Packages
Hit http://security.debian.org jessie/updates/main Translation-en
Fetched 5,192 B in 5s (982 B/s)
Reading package lists...
OK
Reading package lists...
Building dependency tree...
Reading state information...
The following NEW packages will be installed:
  apt-transport-https
0 upgraded, 1 newly installed, 0 to remove and 12 not upgraded.
Need to get 138 kB of archives.
After this operation, 195 kB of additional disk space will be used.
Get:1 http://httpredir.debian.org/debian/ jessie/main apt-transport-https amd64 1.0.9.8.3 [138 kB]
Fetched 138 kB in 0s (205 kB/s)
                               Selecting previously unselected package apt-transport-https.
(Reading database ... 30782 files and directories currently installed.)
Preparing to unpack .../apt-transport-https_1.0.9.8.3_amd64.deb ...
Unpacking apt-transport-https (1.0.9.8.3) ...
Setting up apt-transport-https (1.0.9.8.3) ...
Get:1 https://repo.saltstack.com jessie InRelease [2,834 B]
Get:2 https://repo.saltstack.com jessie/main amd64 Packages [16.0 kB]
Get:3 https://repo.saltstack.com jessie/main Translation-en_GB [268 B]
Get:4 https://repo.saltstack.com jessie/main Translation-en [265 B]
Get:5 https://repo.saltstack.com jessie/main Translation-en_GB [268 B]
Get:6 https://repo.saltstack.com jessie/main Translation-en [265 B]
Get:7 https://repo.saltstack.com jessie/main Translation-en_GB [268 B]
Get:8 https://repo.saltstack.com jessie/main Translation-en [265 B]
Get:9 https://repo.saltstack.com jessie/main Translation-en_GB [268 B]
Get:10 https://repo.saltstack.com jessie/main Translation-en [265 B]
Get:11 https://repo.saltstack.com jessie/main Translation-en_GB [268 B]
Ign https://repo.saltstack.com jessie/main Translation-en_GB
Get:12 https://repo.saltstack.com jessie/main Translation-en [265 B]
Ign https://repo.saltstack.com jessie/main Translation-en
Ign http://httpredir.debian.org jessie InRelease
Hit http://httpredir.debian.org jessie-updates InRelease
Hit http://httpredir.debian.org jessie Release.gpg
Hit http://httpredir.debian.org jessie-updates/main Sources
Get:13 http://httpredir.debian.org jessie-updates/main amd64 Packages/DiffIndex [3,472 B]
Get:14 http://httpredir.debian.org jessie-updates/main Translation-en/DiffIndex [1,720 B]
Hit http://httpredir.debian.org jessie Release
Hit http://httpredir.debian.org jessie/main Sources
Hit http://httpredir.debian.org jessie/main amd64 Packages
Hit http://httpredir.debian.org jessie/main Translation-en
Hit http://security.debian.org jessie/updates InRelease
Hit http://security.debian.org jessie/updates/main Sources
Hit http://security.debian.org jessie/updates/main amd64 Packages
Hit http://security.debian.org jessie/updates/main Translation-en
Fetched 24.0 kB in 10s (2,329 B/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
pciutils is already the newest version.
procps is already the newest version.
python-apt is already the newest version.
The following extra packages will be installed:
  libpgm-5.1-0 libsodium13 python-cffi python-cryptography
  python-ndg-httpsclient python-openssl python-ply python-pyasn1
  python-pycparser python-urllib3
Suggested packages:
  python-dev python-cryptography-doc python-cryptography-vectors
  python-openssl-doc python-openssl-dbg python-ply-doc doc-base cpp
The following NEW packages will be installed:
  libpgm-5.1-0 libsodium13 libzmq3 libzmq3-dev python-cffi python-cryptography
  python-ndg-httpsclient python-openssl python-ply python-pyasn1
  python-pycparser python-requests python-urllib3 python-zmq
0 upgraded, 14 newly installed, 0 to remove and 12 not upgraded.
Need to get 2,121 kB of archives.
After this operation, 7,579 kB of additional disk space will be used.
Get:1 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main libsodium13 amd64 1.0.3-1 [139 kB]
Get:2 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main libzmq3 amd64 4.0.5+dfsg-3 [437 kB]
Get:3 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main libzmq3-dev amd64 4.0.5+dfsg-3 [564 kB]
Get:4 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main python-urllib3 all 1.10.4-1 [61.1 kB]
Get:5 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main python-requests all 2.7.0-3 [66.4 kB]
Get:6 http://httpredir.debian.org/debian/ jessie/main libpgm-5.1-0 amd64 5.1.118-1~dfsg-1 [157 kB]
Get:7 http://httpredir.debian.org/debian/ jessie/main python-ply all 3.4-5 [62.9 kB]
Get:8 http://httpredir.debian.org/debian/ jessie/main python-pycparser all 2.10+dfsg-3 [58.8 kB]
Get:9 http://httpredir.debian.org/debian/ jessie/main python-cffi amd64 0.8.6-1 [67.2 kB]
Get:10 http://httpredir.debian.org/debian/ jessie/main python-cryptography amd64 0.6.1-1 [165 kB]
Get:11 http://httpredir.debian.org/debian/ jessie/main python-openssl all 0.14-1 [81.1 kB]
Get:12 http://httpredir.debian.org/debian/ jessie/main python-ndg-httpsclient all 0.3.2-1 [20.5 kB]
Get:13 http://httpredir.debian.org/debian/ jessie/main python-pyasn1 all 0.1.7-1 [49.3 kB]
Get:14 http://httpredir.debian.org/debian/ jessie/main python-zmq amd64 14.4.0-1 [191 kB]
Fetched 2,121 kB in 6s (343 kB/s)
                                 Selecting previously unselected package libsodium13:amd64.
(Reading database ... 30788 files and directories currently installed.)
Preparing to unpack .../libsodium13_1.0.3-1_amd64.deb ...
Unpacking libsodium13:amd64 (1.0.3-1) ...
Selecting previously unselected package libpgm-5.1-0.
Preparing to unpack .../libpgm-5.1-0_5.1.118-1~dfsg-1_amd64.deb ...
Unpacking libpgm-5.1-0 (5.1.118-1~dfsg-1) ...
Selecting previously unselected package libzmq3:amd64.
Preparing to unpack .../libzmq3_4.0.5+dfsg-3_amd64.deb ...
Unpacking libzmq3:amd64 (4.0.5+dfsg-3) ...
Selecting previously unselected package libzmq3-dev:amd64.
Preparing to unpack .../libzmq3-dev_4.0.5+dfsg-3_amd64.deb ...
Unpacking libzmq3-dev:amd64 (4.0.5+dfsg-3) ...
Selecting previously unselected package python-ply.
Preparing to unpack .../python-ply_3.4-5_all.deb ...
Unpacking python-ply (3.4-5) ...
Selecting previously unselected package python-pycparser.
Preparing to unpack .../python-pycparser_2.10+dfsg-3_all.deb ...
Unpacking python-pycparser (2.10+dfsg-3) ...
Selecting previously unselected package python-cffi.
Preparing to unpack .../python-cffi_0.8.6-1_amd64.deb ...
Unpacking python-cffi (0.8.6-1) ...
Selecting previously unselected package python-cryptography.
Preparing to unpack .../python-cryptography_0.6.1-1_amd64.deb ...
Unpacking python-cryptography (0.6.1-1) ...
Selecting previously unselected package python-openssl.
Preparing to unpack .../python-openssl_0.14-1_all.deb ...
Unpacking python-openssl (0.14-1) ...
Selecting previously unselected package python-ndg-httpsclient.
Preparing to unpack .../python-ndg-httpsclient_0.3.2-1_all.deb ...
Unpacking python-ndg-httpsclient (0.3.2-1) ...
Selecting previously unselected package python-pyasn1.
Preparing to unpack .../python-pyasn1_0.1.7-1_all.deb ...
Unpacking python-pyasn1 (0.1.7-1) ...
Selecting previously unselected package python-urllib3.
Preparing to unpack .../python-urllib3_1.10.4-1_all.deb ...
Unpacking python-urllib3 (1.10.4-1) ...
Selecting previously unselected package python-requests.
Preparing to unpack .../python-requests_2.7.0-3_all.deb ...
Unpacking python-requests (2.7.0-3) ...
Selecting previously unselected package python-zmq.
Preparing to unpack .../python-zmq_14.4.0-1_amd64.deb ...
Unpacking python-zmq (14.4.0-1) ...
Setting up libsodium13:amd64 (1.0.3-1) ...
Setting up libpgm-5.1-0 (5.1.118-1~dfsg-1) ...
Setting up libzmq3:amd64 (4.0.5+dfsg-3) ...
Setting up libzmq3-dev:amd64 (4.0.5+dfsg-3) ...
Setting up python-ply (3.4-5) ...
Setting up python-pycparser (2.10+dfsg-3) ...
Setting up python-cffi (0.8.6-1) ...
Setting up python-cryptography (0.6.1-1) ...
Setting up python-openssl (0.14-1) ...
Setting up python-ndg-httpsclient (0.3.2-1) ...
Setting up python-pyasn1 (0.1.7-1) ...
Setting up python-urllib3 (1.10.4-1) ...
Setting up python-requests (2.7.0-3) ...
Setting up python-zmq (14.4.0-1) ...
Processing triggers for libc-bin (2.19-18+deb8u4) ...
Processing triggers for python-support (1.0.15) ...
 *  INFO: Running install_debian_8_stable()
Reading package lists...
Building dependency tree...
Reading state information...
The following extra packages will be installed:
  bsdmainutils dctrl-tools debconf-utils git git-man javascript-common
  liberror-perl libjs-jquery libmysqlclient18 libyaml-0-2 mysql-common
  python-async python-croniter python-crypto python-dateutil python-git
  python-gitdb python-jinja2 python-markupsafe python-msgpack python-mysqldb
  python-pycurl python-smmap python-tornado python-tz python-yaml salt-common
Suggested packages:
  cpp wamerican wordlist vacation debtags git-daemon-run git-daemon-sysvinit
  git-doc git-el git-email git-gui gitk gitweb git-arch git-cvs git-mediawiki
  git-svn apache2 lighttpd httpd python-crypto-dbg python-crypto-doc
  python-jinja2-doc python-egenix-mxdatetime mysql-server-5.1 mysql-server
  python-mysqldb-dbg libcurl4-gnutls-dev python-pycurl-dbg python-pycurl-doc
  python-augeas
The following NEW packages will be installed:
  bsdmainutils dctrl-tools debconf-utils git git-man javascript-common
  liberror-perl libjs-jquery libmysqlclient18 libyaml-0-2 mysql-common
  python-async python-croniter python-crypto python-dateutil python-git
  python-gitdb python-jinja2 python-markupsafe python-msgpack python-mysqldb
  python-pycurl python-smmap python-tornado python-tz python-yaml salt-common
  salt-master salt-minion
0 upgraded, 29 newly installed, 0 to remove and 12 not upgraded.
Need to get 11.0 MB of archives.
After this operation, 53.7 MB of additional disk space will be used.
Get:1 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main python-tornado amd64 4.2.1-1 [275 kB]
Get:2 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main salt-common all 2016.3.0+ds-1 [3,568 kB]
Get:3 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main salt-master all 2016.3.0+ds-1 [37.2 kB]
Get:4 https://repo.saltstack.com/apt/debian/8/amd64/latest/ jessie/main salt-minion all 2016.3.0+ds-1 [25.7 kB]
Get:5 http://security.debian.org/ jessie/updates/main mysql-common all 5.5.49-0+deb8u1 [81.1 kB]
Get:6 http://security.debian.org/ jessie/updates/main libmysqlclient18 amd64 5.5.49-0+deb8u1 [675 kB]
Get:7 http://httpredir.debian.org/debian/ jessie/main libyaml-0-2 amd64 0.1.6-3 [50.4 kB]
Get:8 http://httpredir.debian.org/debian/ jessie/main python-dateutil all 2.2-2 [51.3 kB]
Get:9 http://httpredir.debian.org/debian/ jessie/main python-tz all 2012c+dfsg-0.1 [31.9 kB]
Get:10 http://httpredir.debian.org/debian/ jessie/main python-croniter all 0.3.4-1 [10.5 kB]
Get:11 http://httpredir.debian.org/debian/ jessie/main bsdmainutils amd64 9.0.6 [183 kB]
Get:12 http://httpredir.debian.org/debian/ jessie/main dctrl-tools amd64 2.23 [170 kB]
Get:13 http://httpredir.debian.org/debian/ jessie/main debconf-utils all 1.5.56 [57.6 kB]
Get:14 http://httpredir.debian.org/debian/ jessie/main liberror-perl all 0.17-1.1 [22.4 kB]
Get:15 http://httpredir.debian.org/debian/ jessie/main git-man all 1:2.1.4-2.1+deb8u2 [1,267 kB]
Get:16 http://httpredir.debian.org/debian/ jessie/main git amd64 1:2.1.4-2.1+deb8u2 [3,262 kB]
Get:17 http://httpredir.debian.org/debian/ jessie/main javascript-common all 11 [6,120 B]
Get:18 http://httpredir.debian.org/debian/ jessie/main libjs-jquery all 1.7.2+dfsg-3.2 [97.5 kB]
Get:19 http://httpredir.debian.org/debian/ jessie/main python-crypto amd64 2.6.1-5+b2 [256 kB]
Get:20 http://httpredir.debian.org/debian/ jessie/main python-async amd64 0.6.1-1 [42.7 kB]
Get:21 http://httpredir.debian.org/debian/ jessie/main python-smmap all 0.8.2-2 [19.0 kB]
Get:22 http://httpredir.debian.org/debian/ jessie/main python-gitdb amd64 0.5.4-1 [58.9 kB]
Get:23 http://httpredir.debian.org/debian/ jessie/main python-git all 0.3.2~RC1-3 [249 kB]
Get:24 http://httpredir.debian.org/debian/ jessie/main python-markupsafe amd64 0.23-1+b1 [15.9 kB]
Get:25 http://httpredir.debian.org/debian/ jessie/main python-jinja2 all 2.7.3-1 [170 kB]
Get:26 http://httpredir.debian.org/debian/ jessie/main python-msgpack amd64 0.4.2-1 [55.2 kB]
Get:27 http://httpredir.debian.org/debian/ jessie/main python-mysqldb amd64 1.2.3-2.1 [62.2 kB]
Get:28 http://httpredir.debian.org/debian/ jessie/main python-pycurl amd64 7.19.5-3 [50.5 kB]
Get:29 http://httpredir.debian.org/debian/ jessie/main python-yaml amd64 3.11-2 [112 kB]
Fetched 11.0 MB in 15s (722 kB/s)
                                 Selecting previously unselected package mysql-common.
(Reading database ... 31489 files and directories currently installed.)
Preparing to unpack .../mysql-common_5.5.49-0+deb8u1_all.deb ...
Unpacking mysql-common (5.5.49-0+deb8u1) ...
Selecting previously unselected package libmysqlclient18:amd64.
Preparing to unpack .../libmysqlclient18_5.5.49-0+deb8u1_amd64.deb ...
Unpacking libmysqlclient18:amd64 (5.5.49-0+deb8u1) ...
Selecting previously unselected package libyaml-0-2:amd64.
Preparing to unpack .../libyaml-0-2_0.1.6-3_amd64.deb ...
Unpacking libyaml-0-2:amd64 (0.1.6-3) ...
Selecting previously unselected package python-dateutil.
Preparing to unpack .../python-dateutil_2.2-2_all.deb ...
Unpacking python-dateutil (2.2-2) ...
Selecting previously unselected package python-tz.
Preparing to unpack .../python-tz_2012c+dfsg-0.1_all.deb ...
Unpacking python-tz (2012c+dfsg-0.1) ...
Selecting previously unselected package python-croniter.
Preparing to unpack .../python-croniter_0.3.4-1_all.deb ...
Unpacking python-croniter (0.3.4-1) ...
Selecting previously unselected package bsdmainutils.
Preparing to unpack .../bsdmainutils_9.0.6_amd64.deb ...
Unpacking bsdmainutils (9.0.6) ...
Selecting previously unselected package dctrl-tools.
Preparing to unpack .../dctrl-tools_2.23_amd64.deb ...
Unpacking dctrl-tools (2.23) ...
Selecting previously unselected package debconf-utils.
Preparing to unpack .../debconf-utils_1.5.56_all.deb ...
Unpacking debconf-utils (1.5.56) ...
Selecting previously unselected package liberror-perl.
Preparing to unpack .../liberror-perl_0.17-1.1_all.deb ...
Unpacking liberror-perl (0.17-1.1) ...
Selecting previously unselected package git-man.
Preparing to unpack .../git-man_1%3a2.1.4-2.1+deb8u2_all.deb ...
Unpacking git-man (1:2.1.4-2.1+deb8u2) ...
Selecting previously unselected package git.
Preparing to unpack .../git_1%3a2.1.4-2.1+deb8u2_amd64.deb ...
Unpacking git (1:2.1.4-2.1+deb8u2) ...
Selecting previously unselected package javascript-common.
Preparing to unpack .../javascript-common_11_all.deb ...
Unpacking javascript-common (11) ...
Selecting previously unselected package libjs-jquery.
Preparing to unpack .../libjs-jquery_1.7.2+dfsg-3.2_all.deb ...
Unpacking libjs-jquery (1.7.2+dfsg-3.2) ...
Selecting previously unselected package python-crypto.
Preparing to unpack .../python-crypto_2.6.1-5+b2_amd64.deb ...
Unpacking python-crypto (2.6.1-5+b2) ...
Selecting previously unselected package python-async.
Preparing to unpack .../python-async_0.6.1-1_amd64.deb ...
Unpacking python-async (0.6.1-1) ...
Selecting previously unselected package python-smmap.
Preparing to unpack .../python-smmap_0.8.2-2_all.deb ...
Unpacking python-smmap (0.8.2-2) ...
Selecting previously unselected package python-gitdb.
Preparing to unpack .../python-gitdb_0.5.4-1_amd64.deb ...
Unpacking python-gitdb (0.5.4-1) ...
Selecting previously unselected package python-git.
Preparing to unpack .../python-git_0.3.2~RC1-3_all.deb ...
Unpacking python-git (0.3.2~RC1-3) ...
Selecting previously unselected package python-markupsafe.
Preparing to unpack .../python-markupsafe_0.23-1+b1_amd64.deb ...
Unpacking python-markupsafe (0.23-1+b1) ...
Selecting previously unselected package python-jinja2.
Preparing to unpack .../python-jinja2_2.7.3-1_all.deb ...
Unpacking python-jinja2 (2.7.3-1) ...
Selecting previously unselected package python-msgpack.
Preparing to unpack .../python-msgpack_0.4.2-1_amd64.deb ...
Unpacking python-msgpack (0.4.2-1) ...
Selecting previously unselected package python-mysqldb.
Preparing to unpack .../python-mysqldb_1.2.3-2.1_amd64.deb ...
Unpacking python-mysqldb (1.2.3-2.1) ...
Selecting previously unselected package python-pycurl.
Preparing to unpack .../python-pycurl_7.19.5-3_amd64.deb ...
Unpacking python-pycurl (7.19.5-3) ...
Selecting previously unselected package python-tornado.
Preparing to unpack .../python-tornado_4.2.1-1_amd64.deb ...
Unpacking python-tornado (4.2.1-1) ...
Selecting previously unselected package python-yaml.
Preparing to unpack .../python-yaml_3.11-2_amd64.deb ...
Unpacking python-yaml (3.11-2) ...
Selecting previously unselected package salt-common.
Preparing to unpack .../salt-common_2016.3.0+ds-1_all.deb ...
Unpacking salt-common (2016.3.0+ds-1) ...
Selecting previously unselected package salt-master.
Preparing to unpack .../salt-master_2016.3.0+ds-1_all.deb ...
Unpacking salt-master (2016.3.0+ds-1) ...
Selecting previously unselected package salt-minion.
Preparing to unpack .../salt-minion_2016.3.0+ds-1_all.deb ...
Unpacking salt-minion (2016.3.0+ds-1) ...
Processing triggers for systemd (215-17+deb8u4) ...
Setting up mysql-common (5.5.49-0+deb8u1) ...
Setting up libmysqlclient18:amd64 (5.5.49-0+deb8u1) ...
Setting up libyaml-0-2:amd64 (0.1.6-3) ...
Setting up python-dateutil (2.2-2) ...
Setting up python-tz (2012c+dfsg-0.1) ...
Setting up python-croniter (0.3.4-1) ...
Setting up bsdmainutils (9.0.6) ...
update-alternatives: using /usr/bin/bsd-write to provide /usr/bin/write (write) in auto mode
update-alternatives: using /usr/bin/bsd-from to provide /usr/bin/from (from) in auto mode
Setting up dctrl-tools (2.23) ...
Setting up debconf-utils (1.5.56) ...
Setting up liberror-perl (0.17-1.1) ...
Setting up git-man (1:2.1.4-2.1+deb8u2) ...
Setting up git (1:2.1.4-2.1+deb8u2) ...
Setting up javascript-common (11) ...
Setting up libjs-jquery (1.7.2+dfsg-3.2) ...
Setting up python-crypto (2.6.1-5+b2) ...
Setting up python-async (0.6.1-1) ...
Setting up python-smmap (0.8.2-2) ...
Setting up python-gitdb (0.5.4-1) ...
Setting up python-git (0.3.2~RC1-3) ...
Setting up python-markupsafe (0.23-1+b1) ...
Setting up python-jinja2 (2.7.3-1) ...
Setting up python-msgpack (0.4.2-1) ...
Setting up python-mysqldb (1.2.3-2.1) ...
Setting up python-pycurl (7.19.5-3) ...
Setting up python-tornado (4.2.1-1) ...
Setting up python-yaml (3.11-2) ...
Setting up salt-common (2016.3.0+ds-1) ...
Setting up salt-master (2016.3.0+ds-1) ...
Setting up salt-minion (2016.3.0+ds-1) ...
Processing triggers for libc-bin (2.19-18+deb8u4) ...
Processing triggers for systemd (215-17+deb8u4) ...
 *  INFO: Running install_debian_check_services()
 *  INFO: Running install_debian_restart_daemons()
 *  INFO: Running daemons_running()
 *  INFO: Salt installed!
root@saltdev-debian-jessie:~# cat /var/log/salt/master 
2016-06-01 12:46:35,414 [salt.cli.daemons ][INFO    ][2650] Setting up the Salt Master
2016-06-01 12:46:36,429 [salt.crypt       ][INFO    ][2650] Generating master keys: /etc/salt/pki/master
2016-06-01 12:46:36,583 [salt.daemons.masterapi][INFO    ][2650] Preparing the root key for local communication
2016-06-01 12:46:36,590 [salt.cli.daemons ][WARNING ][2650] IMPORTANT: Do not use md5 hashing algorithm! Please set "hash_type" to sha256 in Salt Master config!
2016-06-01 12:46:36,590 [salt.cli.daemons ][INFO    ][2650] The Salt Master is starting up
2016-06-01 12:46:36,595 [salt.master      ][INFO    ][2650] salt-master is starting as user 'root'
2016-06-01 12:46:36,595 [salt.master      ][INFO    ][2650] Current values for max open files soft/hard setting: 16384/16384
2016-06-01 12:46:36,596 [salt.master      ][INFO    ][2650] The value for the 'max_open_files' setting, 100000, is higher than what the user running salt is allowed to raise to, 16384. Defaulting to 16384.
2016-06-01 12:46:36,597 [salt.master      ][INFO    ][2650] Creating master process manager
2016-06-01 12:46:36,597 [salt.master      ][INFO    ][2650] Creating master publisher process
2016-06-01 12:46:36,599 [salt.master      ][INFO    ][2650] Creating master event publisher process
2016-06-01 12:46:36,613 [salt.transport.zeromq][INFO    ][2772] Starting the Salt Publisher on tcp://0.0.0.0:4505
2016-06-01 12:46:36,613 [salt.transport.zeromq][INFO    ][2772] Starting the Salt Puller on ipc:///var/run/salt/master/publish_pull.ipc
2016-06-01 12:46:36,612 [salt.master      ][INFO    ][2650] Creating master maintenance process
2016-06-01 12:46:36,615 [salt.master      ][INFO    ][2650] Creating master reactor process
2016-06-01 12:46:39,722 [salt.cli.daemons ][INFO    ][2834] Setting up the Salt Master
2016-06-01 12:46:39,722 [salt.utils.verify][WARNING ][2834] Unable to bind socket, error: [Errno 98] Address already in use
2016-06-01 12:46:39,722 [salt.cli.daemons ][INFO    ][2834] The Salt Master is shut down

Versions Report

  1. Bootstrap script
# salt --versions-report
Salt Version:
           Salt: 2016.3.0

Dependency Versions:
           cffi: 0.8.6
       cherrypy: Not Installed
       dateutil: 2.2
          gitdb: 0.5.4
      gitpython: 0.3.2 RC1
          ioflo: Not Installed
         Jinja2: 2.7.3
        libgit2: Not Installed
        libnacl: Not Installed
       M2Crypto: Not Installed
           Mako: Not Installed
   msgpack-pure: Not Installed
 msgpack-python: 0.4.2
   mysql-python: 1.2.3
      pycparser: 2.10
       pycrypto: 2.6.1
         pygit2: Not Installed
         Python: 2.7.9 (default, Mar  1 2015, 12:57:24)
   python-gnupg: Not Installed
         PyYAML: 3.11
          PyZMQ: 14.4.0
           RAET: Not Installed
          smmap: 0.8.2
        timelib: Not Installed
        Tornado: 4.2.1
            ZMQ: 4.0.5

System Versions:
           dist: debian 8.4 
        machine: x86_64
        release: 3.16.0-4-amd64
         system: Linux
        version: debian 8.4 

Activity

  1. Ch3LL commented on Jun 1, 2016

    @Ch3LL
    Contributor

    @BABILEN would you mind opening this up on the bootstrap repo so we can track it from that repository?

    Also while we will move this conversation to that other repo I am not able to replicate this on a debian 8 box. My test case as follows:

    1. Clean debian 8 box
    2. wget -O bootstrap.sh https://bootstrap.saltstack.com
    3. chmod +x bootstrap.sh
    4. ./bootstrap.sh -M
    5. It installs the master and starts up the process file:
    ...
    Processing triggers for libc-bin (2.19-18+deb8u3) ...
    Processing triggers for systemd (215-17+deb8u3) ...
     *  INFO: Running install_debian_check_services()
     *  INFO: Running install_debian_restart_daemons()
     *  INFO: Running daemons_running()
     *  INFO: Salt installed!
    

    And in the logs:

    2016-06-01 20:21:39,330 [salt.cli.daemons ][INFO    ][16628] Setting up the Salt Master
    2016-06-01 20:21:40,486 [salt.crypt       ][INFO    ][16628] Generating master keys: /etc/salt/pki/master
    2016-06-01 20:21:40,632 [salt.daemons.masterapi][INFO    ][16628] Preparing the root key for local communication
    2016-06-01 20:21:40,648 [salt.cli.daemons ][WARNING ][16628] IMPORTANT: Do not use md5 hashing algorithm! Please set "hash_type" to sha256 in Salt Master config!
    2016-06-01 20:21:40,648 [salt.cli.daemons ][INFO    ][16628] The Salt Master is starting up
    2016-06-01 20:21:40,657 [salt.master      ][INFO    ][16628] salt-master is starting as user 'root'
    2016-06-01 20:21:40,658 [salt.master      ][INFO    ][16628] Current values for max open files soft/hard setting: 16384/16384
    2016-06-01 20:21:40,659 [salt.master      ][INFO    ][16628] The value for the 'max_open_files' setting, 100000, is higher than what the user running salt is allowed to raise to, 16384. Defaulting to 16384.
    2016-06-01 20:21:40,662 [salt.master      ][INFO    ][16628] Creating master process manager
    2016-06-01 20:21:40,663 [salt.master      ][INFO    ][16628] Creating master publisher process
    2016-06-01 20:21:40,670 [salt.master      ][INFO    ][16628] Creating master event publisher process
    2016-06-01 20:21:40,682 [salt.transport.zeromq][INFO    ][16741] Starting the Salt Publisher on tcp://0.0.0.0:4505
    2016-06-01 20:21:40,691 [salt.transport.zeromq][INFO    ][16741] Starting the Salt Puller on ipc:///var/run/salt/master/publish_pull.ipc
    2016-06-01 20:21:40,699 [salt.master      ][INFO    ][16628] Creating master maintenance process
    2016-06-01 20:21:40,706 [salt.master      ][INFO    ][16628] Creating master reactor process
    2016-06-01 20:21:41,298 [salt.master      ][INFO    ][16628] Creating master request server process
    2016-06-01 20:21:41,320 [salt.transport.zeromq][INFO    ][16849] Setting up the master communication server
    2016-06-01 20:21:43,368 [salt.utils.parsers][WARNING ][16628] Master received a SIGTERM. Exiting.
    2016-06-01 20:21:43,369 [salt.cli.daemons ][INFO    ][16628] The Salt Master is shut down
    2016-06-01 20:21:43,758 [salt.cli.daemons ][INFO    ][17168] Setting up the Salt Master
    2016-06-01 20:21:44,585 [salt.daemons.masterapi][INFO    ][17168] Preparing the root key for local communication
    2016-06-01 20:21:44,598 [salt.cli.daemons ][WARNING ][17168] IMPORTANT: Do not use md5 hashing algorithm! Please set "hash_type" to sha256 in Salt Master config!
    2016-06-01 20:21:44,598 [salt.cli.daemons ][INFO    ][17168] The Salt Master is starting up
    2016-06-01 20:21:44,605 [salt.master      ][INFO    ][17168] salt-master is starting as user 'root'
    2016-06-01 20:21:44,606 [salt.master      ][INFO    ][17168] Current values for max open files soft/hard setting: 16384/16384
    2016-06-01 20:21:44,606 [salt.master      ][INFO    ][17168] The value for the 'max_open_files' setting, 100000, is higher than what the user running salt is allowed to raise to, 16384. Defaulting to 16384.
    2016-06-01 20:21:44,608 [salt.master      ][INFO    ][17168] Creating master process manager
    2016-06-01 20:21:44,608 [salt.master      ][INFO    ][17168] Creating master publisher process
    2016-06-01 20:21:44,616 [salt.master      ][INFO    ][17168] Creating master event publisher process
    2016-06-01 20:21:44,620 [salt.transport.zeromq][INFO    ][17219] Starting the Salt Publisher on tcp://0.0.0.0:4505
    2016-06-01 20:21:44,621 [salt.transport.zeromq][INFO    ][17219] Starting the Salt Puller on ipc:///var/run/salt/master/publish_pull.ipc
    2016-06-01 20:21:44,634 [salt.master      ][INFO    ][17168] Creating master maintenance process
    2016-06-01 20:21:44,638 [salt.master      ][INFO    ][17168] Creating master reactor process
    2016-06-01 20:21:44,983 [salt.master      ][INFO    ][17168] Creating master request server process
    2016-06-01 20:21:45,005 [salt.transport.zeromq][INFO    ][17295] Setting up the master communication server
    2016-06-01 20:21:48,992 [salt.transport.zeromq][INFO    ][17305] Worker binding to socket ipc:///var/run/salt/master/workers.ipc
    2016-06-01 20:21:49,176 [salt.transport.zeromq][INFO    ][17307] Worker binding to socket ipc:///var/run/salt/master/workers.ipc
    2016-06-01 20:21:49,230 [salt.transport.zeromq][INFO    ][17309] Worker binding to socket ipc:///var/run/salt/master/workers.ipc
    2016-06-01 20:21:49,249 [salt.transport.zeromq][INFO    ][17308] Worker binding to socket ipc:///var/run/salt/master/workers.ipc
    2016-06-01 20:21:49,255 [salt.transport.zeromq][INFO    ][17304] Worker binding to socket ipc:///var/run/salt/master/workers.ipc
    

    Am I missing something in my test case? Maybe you already had salt installed on the box?

    Also can you ping me on the new issue in bootstrap. Thanks!

  2. added
    needs-more-info
    cannot-reproduce
    on Jun 1, 2016
  3. added this to the Blocked milestone on Jun 1, 2016
  4. wwentland commented on Jun 1, 2016

    @wwentland
    ContributorAuthor

    I'll do that and your procedure looks fine. Let me try to reproduce in different environments.

  5. wwentland commented on Jun 2, 2016

    @wwentland
    ContributorAuthor

    I investigated this issue a bit more and tracked it down to install_debian_restart_daemons in the bootstrap script, but I believe that the underlying problem exists in salt, which is why I keep the issue open here (for now).

    The problem seems to be that a call to systemctl stop salt-master does not wait for all salt-master processes to exit before returning, which causes the subsequent systemctl start salt-master to start too early and run into Unable to bind socket, error: [Errno 98] Address already in use.

    I modified that function to provide more details:

    install_debian_restart_daemons() {
        [ "$_START_DAEMONS" -eq $BS_FALSE ] && return
    
        echoinfo "install_debian_restart_daemons"
        for fname in minion master syndic api; do
            # Skip salt-api since the service should be opt-in and not necessarily started on boot
            [ $fname = "api" ] && continue
    
            # Skip if not meant to be installed
            [ $fname = "minion" ] && [ "$_INSTALL_MINION" -eq $BS_FALSE ] && continue
            [ $fname = "master" ] && [ "$_INSTALL_MASTER" -eq $BS_FALSE ] && continue
            #[ $fname = "api" ] && ([ "$_INSTALL_MASTER" -eq $BS_FALSE ] || [ ! -f "/etc/init.d/salt-$fname" ]) && continue
            [ $fname = "syndic" ] && [ "$_INSTALL_SYNDIC" -eq $BS_FALSE ] && continue
    
            echo "fname: " $fname
    
            if [ -f /bin/systemctl ]; then
                # Debian 8 uses systemd
                echo "SystemD"
    
                echo "-----"
                /bin/systemctl status salt-$fname.service
                ps aux|grep salt-$fname
                echo "-----"
    
                echo "Stopping " $fname
                /bin/systemctl stop salt-$fname > /dev/null 2>&1
    
                echo "-----"
                /bin/systemctl status salt-$fname.service
    
                echo "running processes:"
                ps aux|grep salt-$fname
                echo ""
                echo "-----"
    
                echo "Starting " $fname
                /bin/systemctl start salt-$fname.service
    
                echo "-----"
                /bin/systemctl status salt-$fname.service
                ps aux|grep [s]alt-$fname
                echo "-----"
    
            elif [ -f /etc/init.d/salt-$fname ]; then
                # Still in SysV init
                /etc/init.d/salt-$fname stop > /dev/null 2>&1
                /etc/init.d/salt-$fname start
            fi
        done
    }
    

    and see the following behaviour:

    ...
    -----
    fname:  master
    SystemD
    -----
    ● salt-master.service - The Salt Master Server
       Loaded: loaded (/lib/systemd/system/salt-master.service; enabled)
       Active: active (running) since Thu 2016-06-02 15:52:12 CEST; 4s ago
     Main PID: 2434 (salt-master)
       CGroup: /system.slice/salt-master.service
               ├─2434 /usr/bin/python /usr/bin/salt-master
               ├─2446 /usr/bin/python /usr/bin/salt-master
               ├─2542 /usr/bin/python /usr/bin/salt-master
               ├─2543 /usr/bin/python /usr/bin/salt-master
               └─2547 /usr/bin/python /usr/bin/salt-master
    
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] salt-master is starting as user 'root'
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Current values for max open files soft/hard setting: 16384/16384
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] The value for the 'max_open_files' setting, 100000, is higher than what the user running salt is allowed to raise to, 16384. Defaulting to 16384.
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master process manager
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master publisher process
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master event publisher process
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Starting the Salt Publisher on tcp://0.0.0.0:4505
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Starting the Salt Puller on ipc:///var/run/salt/master/publish_pull.ipc
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master maintenance process
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master reactor process
    root      2434 15.5 11.9 243636 60676 ?        Ss   15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2446  0.0  4.1 146276 21160 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2542  0.0 10.5 322172 53156 ?        Sl   15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2543  0.0  9.9 240244 50296 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2547  7.0 11.1 245400 56516 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2623  0.0  0.4  14204  2500 pts/0    S+   15:52   0:00 grep salt-master
    -----
    Stopping  master
    -----
    ● salt-master.service - The Salt Master Server
       Loaded: loaded (/lib/systemd/system/salt-master.service; enabled)
       Active: inactive (dead) since Thu 2016-06-02 15:52:17 CEST; 6ms ago
     Main PID: 2434 (code=killed, signal=TERM)
    
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] salt-master is starting as user 'root'
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Current values for max open files soft/hard setting: 16384/16384
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] The value for the 'max_open_files' setting, 100000, is higher than what the user running salt is allowed to raise to, 16384. Defaulting to 16384.
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master process manager
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master publisher process
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master event publisher process
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Starting the Salt Publisher on tcp://0.0.0.0:4505
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Starting the Salt Puller on ipc:///var/run/salt/master/publish_pull.ipc
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master maintenance process
    Jun 02 15:52:13 saltdev-debian-jessie salt-master[2434]: [INFO    ] Creating master reactor process
    running processes:
    root      2446  0.0  4.1 146276 21160 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2542  0.0 10.5 322172 53156 ?        Sl   15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2543  0.0  9.9 240244 50296 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2547  7.0 11.1 245400 56516 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2629  0.0  0.4  14204  2344 pts/0    S+   15:52   0:00 grep salt-master
    
    -----
    Starting  master
    -----
    ● salt-master.service - The Salt Master Server
       Loaded: loaded (/lib/systemd/system/salt-master.service; enabled)
       Active: active (running) since Thu 2016-06-02 15:52:17 CEST; 12ms ago
     Main PID: 2633 (salt-master)
       CGroup: /system.slice/salt-master.service
               ├─2446 /usr/bin/python /usr/bin/salt-master
               ├─2542 /usr/bin/python /usr/bin/salt-master
               ├─2543 /usr/bin/python /usr/bin/salt-master
               ├─2547 /usr/bin/python /usr/bin/salt-master
               └─2633 /usr/bin/python /usr/bin/salt-master
    root      2446  0.0  4.1 146276 21160 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2542  0.0 10.5 322172 53156 ?        Sl   15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2543  0.0  9.9 240244 50296 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2547  7.0 11.1 245400 56516 ?        S    15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2633  0.0  1.6  42904  8244 ?        Rs   15:52   0:00 /usr/bin/python /usr/bin/salt-master
    root      2636  0.0  0.4  14204  2440 pts/0    S+   15:52   0:00 grep salt-master
    -----
     *  INFO: Running daemons_running()
     *  INFO: Salt installed!
    ...
    

    As you can see in the Stopping master block, there are still a number of salt-master processes running.

    It should be noted that the same behaviour can be seen if one changes the call to systemctl restart salt-master, but that introducing a sleep 10 gets rid of the problem. There appears to be a problem with the way salt terminates child processes and the script therefore suffers from a race condition.

    With sleep 10 in there, I see the following (note the code=exited, status=0/SUCCESS vs. earlier code=killed, signal=TERM):

    Stopping  master
    -----
    ● salt-master.service - The Salt Master Server
       Loaded: loaded (/lib/systemd/system/salt-master.service; enabled)
       Active: inactive (dead) since Thu 2016-06-02 16:26:25 CEST; 10s ago
     Main PID: 2489 (code=exited, status=0/SUCCESS)
    
    Jun 02 16:26:18 saltdev-debian-jessie salt-master[2489]: [WARNING ] Failed to kill the following processes: Process: <MWorker(MWorker-1, started)> (Pid: 2713); Process: <MWorker(MWorker-2, started)> (Pid: 2714)
    Jun 02 16:26:18 saltdev-debian-jessie salt-master[2489]: [WARNING ] Salt will either fail to terminate now or leave some zombie processes behind
    Jun 02 16:26:19 saltdev-debian-jessie salt-master[2489]: [INFO    ] Some processes failed to respect the KILL signal: Process: <MWorker(MWorker-1, started)> (Pid: 2713); Process: <MWorker(MWorker-2, started)> (Pid: 2714)
    Jun 02 16:26:19 saltdev-debian-jessie salt-master[2489]: [INFO    ] kill_children retries left: 2
    Jun 02 16:26:20 saltdev-debian-jessie salt-master[2489]: [INFO    ] Some processes failed to respect the KILL signal: Process: <MWorker(MWorker-1, started)> (Pid: 2713)
    Jun 02 16:26:20 saltdev-debian-jessie salt-master[2489]: [INFO    ] kill_children retries left: 1
    Jun 02 16:26:21 saltdev-debian-jessie salt-master[2489]: [INFO    ] Some processes failed to respect the KILL signal: Process: <MWorker(MWorker-1, started)> (Pid: 2713)
    Jun 02 16:26:21 saltdev-debian-jessie salt-master[2489]: [INFO    ] kill_children retries left: 0
    Jun 02 16:26:22 saltdev-debian-jessie salt-master[2489]: [WARNING ] Failed to kill the following processes: Process: <MWorker(MWorker-1, started)> (Pid: 2713)
    Jun 02 16:26:22 saltdev-debian-jessie salt-master[2489]: [WARNING ] Salt will either fail to terminate now or leave some zombie processes behind
    running processes:
    root      2958  0.0  0.4  14204  2500 pts/0    S+   16:26   0:00 grep salt-master
    

    Insofar I have also only been able to reproduce this in a vagrant box and not on Jessie VMs in the cloud. I am, as of now, not entirely sure what would cause the delay on my vagrant box and will look into that further.

  6. wwentland commented on Jun 2, 2016

    @wwentland
    ContributorAuthor

    This could also very well be related to KillMode=process in the service file as that would explain why the child processes aren't terminated cleanly.

  7. wwentland commented on Jun 3, 2016

    @wwentland
    ContributorAuthor

    @jfindlay I have just confirmed that removing KillMode=process from the salt-master unit file and running systemctl daemon-reload fixes this issue.

    Not entirely sure why this option was added to the unit files of all salt services in the first place, but I would recommend to only keep it for salt-minion for now (unless a better option is found there as well).

    What baffles me a little is that I can't easily reproduce this in other VMs or even just by running systemctl restart salt-master.service after an installation that follows the procedure on http://repo.saltstack.com/#debian though.

  8. changed the title [-][2016.3.0] salt-master does not start when bootstrapped[/-] [+][2016.3.0] salt-master should not set "KillMode=process" in unit file[/+] on Jun 3, 2016
  9. wwentland commented on Jun 7, 2016

    @wwentland
    ContributorAuthor

    So, I can reproduce it using the following steps.

    1. Remove all vagrant base boxes from vagrant and libvirt storage
    2. Run "rm -rf ~/.vagrant.d"
    3. Run "vagrant plugin install landrush" and "vagrant plugin install vagrant-libvirt"
    4. Create the following Vagrantfile:
    VAGRANTFILE_API_VERSION = "2"
    
    Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
    
      config.vm.box = "debian/jessie64"
      config.landrush.enabled = true
      config.landrush.tld = 'test'
      config.vm.network "private_network", type: "dhcp"
      config.vm.synced_folder "./", "/vagrant/", type: "rsync"
      config.vm.define :saltdev do |saltdev|
        saltdev.vm.hostname = "saltdev-debian-jessie.test"
        saltdev.vm.provision "shell", inline: "apt-get -qq install ca-certificates curl"
      end
    end
    
    1. Run "vagrant up", "vagrant ssh" and become root.
    2. Run "curl -o bootstrap_salt.sh -L https://bootstrap.saltstack.com" and "sh bootstrap_salt.sh -M"

    You can now observe in /var/log/salt/master that the aforementioned error has been reproduced.

    I believe that this is due to the fact that landrush introduces a delay in lookups for salt that cause a delay in process initialisation or teardown. You can circumvent the problem with the following workarounds:

    1. Using 'salt' as hostname by removing "config.landrush.tld = 'test'" and using saltdev.vm.hostname = "salt"
    2. Editing the bootstrap script and adding the aforementioned sleep 10 between service stop and start
    3. Editing the bootstrap script and adding the following two lines in install_debian_restart_daemons:
            ...
            if [ -f /bin/systemctl ]; then
    
                sed -ie "s/KillMode=process//" /lib/systemd/system/salt-master.service
                /bin/systemctl daemon-reload
    
                # Debian 8 uses systemd
                ...
    

    Given that one would want to ensure that all salt-master processes are cleanly stopped before starting a new one I still recommend to remove KillMode=process.

  10. modified the milestones: Approved, Blocked on Jun 7, 2016
  11. added
    bug
    severity-medium
    Packaging
    P3
    Platform
    and removed
    needs-more-info
    on Jun 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3PackagingPlatformbugcannot-reproduceseverity-medium

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions