Description of problem: I tried to stop all running (openstack services): [root@turing openstack-dashboard]# for i in `systemctl --full --all | grep openstack | awk '{print $1}'`; do systemctl stop $i; done [root@turing openstack-dashboard]# ps ax | grep swift 10560 ? Ss 0:00 /usr/bin/python /usr/bin/swift-container-updater /etc/swift/container-server.conf 10583 ? Ss 0:01 /usr/bin/python /usr/bin/swift-object-updater /etc/swift/object-server.conf 17214 pts/13 S+ 0:00 grep --color=auto swift 27907 ? Ss 0:51 /usr/bin/python /usr/bin/swift-account-replicator /etc/swift/account-server.conf 27913 ? Ss 0:00 /usr/bin/python /usr/bin/swift-account-auditor /etc/swift/account-server.conf 27932 ? Ss 0:17 /usr/bin/python /usr/bin/swift-container-replicator /etc/swift/container-server.conf 27948 ? Ss 0:00 /usr/bin/python /usr/bin/swift-container-auditor /etc/swift/container-server.conf 27967 ? Ssl 0:19 /usr/bin/python /usr/bin/swift-object-replicator /etc/swift/object-server.conf 28039 ? Ss 0:04 /usr/bin/python /usr/bin/swift-object-auditor /etc/swift/object-server.conf 28044 ? S 1:44 /usr/bin/python /usr/bin/swift-object-auditor /etc/swift/object-server.conf That is repeatable using systemctl stop (servicename) [root@turing openstack-dashboard]# rpm -q openstack-swift openstack-swift-1.7.2-1.fc18.noarch
Derek is on vacation, I'm going to take a look at this.
Thanks Pete, this can probably be marked as a duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=807170
Good eye, Derek. I see now that Mattias server only has auditors, replicators and updaters remaining: no servers! But it's not so clear to me that it's merely missing unit files, because systemd is supposed to be able to terminate any children of services, no matter how they are daemonized. I assume Mattias started everything with systemctl too, not swift-init (is that correct?).
(In reply to comment #3) > I assume Mattias started everything with systemctl too, not swift-init > (is that correct?). Yes, that is correct. Started via systemctl and also tried to stop it via systemctl. I'm not sure, if this is a duplicate of bz#807170: [root@turing system]# ls -l /lib/systemd/system/openstack-swift-* -rwxr-xr-x. 1 root root 247 Sep 20 19:42 /lib/systemd/system/openstack-swift-account.service -rwxr-xr-x. 1 root root 262 Sep 20 19:42 /lib/systemd/system/openstack-swift-account@.service -rwxr-xr-x. 1 root root 253 Sep 20 19:42 /lib/systemd/system/openstack-swift-container.service -rwxr-xr-x. 1 root root 268 Sep 20 19:42 /lib/systemd/system/openstack-swift-container@.service -rwxr-xr-x. 1 root root 244 Sep 20 19:42 /lib/systemd/system/openstack-swift-object.service -rwxr-xr-x. 1 root root 259 Sep 20 19:42 /lib/systemd/system/openstack-swift-object@.service -rwxr-xr-x. 1 root root 241 Sep 20 19:42 /lib/systemd/system/openstack-swift-proxy.service It seems, I don't have swift-init (or else) as systemd unit.
swift-init isn't a systemd unit file it is a service starter provided by upstream swift. matthias I'm guessing those services your looking at were started by openstack-demo-install (using swift-init) https://github.com/fedora-openstack/openstack-utils/blob/5c1a74bbbb173611d9a1071af361ad44ff0602b5/utils/openstack-demo-install#L304 the systemd unit files your looking at only start/stop the main http servers I think the main issue we have here is that we need systemd unit files to start all of these services.
When not using systemctl to start openstack-swift-services, I shouldn't see this, right? [root@turing ~]# systemctl status openstack-swift-object.service openstack-swift-object.service - OpenStack Object Storage (swift) - Object Server Loaded: loaded (/usr/lib/systemd/system/openstack-swift-object.service; enabled) Active: active (running) since Fri, 02 Nov 2012 09:03:24 +0100; 4h 0min ago Main PID: 9396 (swift-object-se) CGroup: name=systemd:/system/openstack-swift-object.service ├ 9396 /usr/bin/python /usr/bin/swift-object-server /etc/... ├ 9417 /usr/bin/python /usr/bin/swift-object-server /etc/... ├ 9418 /usr/bin/python /usr/bin/swift-object-server /etc/... └ 9419 /usr/bin/python /usr/bin/swift-object-server /etc/... Nov 02 09:03:24 turing.berg.ol swift-object-se[9396]: object-server Started c... Nov 02 09:03:24 turing.berg.ol swift-object-se[9396]: object-server Started c... Nov 02 09:03:24 turing.berg.ol swift-object-se[9396]: object-server Started c... So basically, I'm able to start swift services via systemctl, but not to stop them.... Derek, I'm sure, I rebooted that machine after demo-install.
(In reply to comment #6) > When not using systemctl to start openstack-swift-services, I shouldn't see > this, right? > > [root@turing ~]# systemctl status openstack-swift-object.service > openstack-swift-object.service - OpenStack Object Storage (swift) - Object > Server > Loaded: loaded (/usr/lib/systemd/system/openstack-swift-object.service; > enabled) > Active: active (running) since Fri, 02 Nov 2012 09:03:24 +0100; 4h 0min > ago > Main PID: 9396 (swift-object-se) > CGroup: name=systemd:/system/openstack-swift-object.service > ├ 9396 /usr/bin/python /usr/bin/swift-object-server /etc/... > ├ 9417 /usr/bin/python /usr/bin/swift-object-server /etc/... > ├ 9418 /usr/bin/python /usr/bin/swift-object-server /etc/... > └ 9419 /usr/bin/python /usr/bin/swift-object-server /etc/... > > Nov 02 09:03:24 turing.berg.ol swift-object-se[9396]: object-server Started > c... > Nov 02 09:03:24 turing.berg.ol swift-object-se[9396]: object-server Started > c... > Nov 02 09:03:24 turing.berg.ol swift-object-se[9396]: object-server Started > c... > > So basically, I'm able to start swift services via systemctl, but not to > stop them... that particular service you would see with systemctl we have systemd unit files for 4 swift services openstack-swift-{account,container,object,proxy}, these are what you listed in comment 4, the other services you listed in the original description aren't covered by the systemd unit files. the fact that we have both cases in our swift packaging is probably what is causing confusion see this loop in openstack-demo-install starting services with both service and swift-init https://github.com/fedora-openstack/openstack-utils/blob/5c1a74bbbb173611d9a1071af361ad44ff0602b5/utils/openstack-demo-install#L299 > Derek, I'm sure, I rebooted that machine after demo-install. that should have killed them, I've tried it here just now, so I can't explain this,
In short, it's plain impossible to start (or stop) the processes that were listed in the original report, while using systemctl. An invocation of swift-init mush have occured for them to run at all. I verified this on rawhide too, to make sure nobody fixed bz#807170 while I was looking the other way.
Right after system startup: [mrunge@turing ~]$ ps ax | grep swift 749 ? Ss 0:00 /usr/bin/python /usr/bin/swift-account-server /etc/swift/account-server.conf 754 ? Ss 0:00 /usr/bin/python /usr/bin/swift-object-server /etc/swift/object-server.conf 768 ? Ss 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 775 ? Ss 0:00 /usr/bin/python /usr/bin/swift-container-server /etc/swift/container-server.conf 1260 ? S 0:00 /usr/bin/python /usr/bin/swift-container-server /etc/swift/container-server.conf 1261 ? S 0:00 /usr/bin/python /usr/bin/swift-object-server /etc/swift/object-server.conf 1262 ? S 0:00 /usr/bin/python /usr/bin/swift-object-server /etc/swift/object-server.conf 1263 ? S 0:00 /usr/bin/python /usr/bin/swift-object-server /etc/swift/object-server.conf 1264 ? S 0:00 /usr/bin/python /usr/bin/swift-account-server /etc/swift/account-server.conf 1265 ? S 0:00 /usr/bin/python /usr/bin/swift-container-server /etc/swift/container-server.conf 1266 ? S 0:00 /usr/bin/python /usr/bin/swift-account-server /etc/swift/account-server.conf 1409 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 1410 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 1411 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 1412 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 1413 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 1414 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 1415 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf 1416 ? S 0:00 /usr/bin/python /usr/bin/swift-proxy-server /etc/swift/proxy-server.conf [mrunge@turing ~]$ ls -l /etc/init.d/sw* ls: cannot access /etc/init.d/sw*: No such file or directory -> no sysv init script [mrunge@turing ~]$ ls -l /lib/systemd/system/openstack-swift-* -rwxr-xr-x. 1 root root 247 Sep 20 19:42 /lib/systemd/system/openstack-swift-account.service -rwxr-xr-x. 1 root root 262 Sep 20 19:42 /lib/systemd/system/openstack-swift-account@.service -rwxr-xr-x. 1 root root 253 Sep 20 19:42 /lib/systemd/system/openstack-swift-container.service -rwxr-xr-x. 1 root root 268 Sep 20 19:42 /lib/systemd/system/openstack-swift-container@.service -rwxr-xr-x. 1 root root 244 Sep 20 19:42 /lib/systemd/system/openstack-swift-object.service -rwxr-xr-x. 1 root root 259 Sep 20 19:42 /lib/systemd/system/openstack-swift-object@.service -rwxr-xr-x. 1 root root 241 Sep 20 19:42 /lib/systemd/system/openstack-swift-proxy.service e.g. [root@turing ~]# systemctl status openstack-swift-account.service openstack-swift-account.service - OpenStack Object Storage (swift) - Account Server Loaded: loaded (/usr/lib/systemd/system/openstack-swift-account.service; enabled) Active: active (running) since Sun, 04 Nov 2012 04:21:38 +0100 Main PID: 749 (swift-account-s) CGroup: name=systemd:/system/openstack-swift-account.service ├ 749 /usr/bin/python /usr/bin/swift-account-server /etc... ├ 1264 /usr/bin/python /usr/bin/swift-account-server /etc... └ 1266 /usr/bin/python /usr/bin/swift-account-server /etc... Nov 04 04:21:45 turing.berg.ol swift-account-s[749]: account-server Started c... Nov 04 04:21:45 turing.berg.ol swift-account-s[749]: account-server Started c... /lib/systemd/system/openstack-swift-account.service: [Unit] Description=OpenStack Object Storage (swift) - Account Server After=syslog.target network.target [Service] Type=simple User=swift ExecStart=/usr/bin/swift-account-server /etc/swift/account-server.conf [Install] WantedBy=multi-user.target looks like a systemd target for me. [root@turing ~]# rpm -qf /lib/systemd/system/openstack-swift-account.service openstack-swift-account-1.7.2-1.fc18.noarch
Following discussion with Matthias this can be marked as a duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=807170 , we will need to create systemd unit files for swift-account-auditor swift-account-replicator swift-container-auditor swift-container-replicator swift-container-updater swift-object-auditor swift-object-replicator swift-object-updater and possibly more *** This bug has been marked as a duplicate of bug 807170 ***