Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jewel: build/ops: remove SYSTEMD_RUN from initscript #9872

Merged
1 commit merged into from Oct 14, 2016

Conversation

odivlad
Copy link
Contributor

@odivlad odivlad commented Jun 22, 2016

Closes: http://tracker.ceph.com/issues/16441

systemd-run logic in initscripts was introduced because of ticket http://tracker.ceph.com/issues/7627.
If we have systemd-based distro, we should use systemd unit files from systemd directory to start/stop ceph daemons.
Otherwise, daemon() from /etc/init.d/functions on systemd distro starts service in system.slice and everything works well for case, for example, when we use hammer on RH7. With this code it will start daemon with daemon() function from init.d/functions.
systemd-run can not be run on non-systemd distros, so it's not needed on SysV systems.

Backport of: #9871

Signed-off-by: Vladislav Odintsov odivlad@gmail.com

@odivlad odivlad changed the title remove SYSTEMD_RUN from initscript jewel: remove SYSTEMD_RUN from initscript Jun 22, 2016
@smithfarm smithfarm changed the title jewel: remove SYSTEMD_RUN from initscript [DNM] jewel: remove SYSTEMD_RUN from initscript Jun 23, 2016
@smithfarm
Copy link
Contributor

Changelog:

  • marked DNM until master PR has been merged and cherry-pick SHA1 double-checked

@smithfarm
Copy link
Contributor

@odivlad Thanks for the backport! Next time, though, please wait until the master PR has been merged and then do the backports using "git cherry-pick -x" so we have the xref to the master SHA1 in the commit message.

@odivlad
Copy link
Contributor Author

odivlad commented Jul 11, 2016

@smithfarm, since my PR to master (#9871) is already merged, please, remove [DNM] prefix.
I've also updated this PR with cherry-picked commits. PR is ready for review.

@smithfarm
Copy link
Contributor

@odivlad Please update the commit message with a description of how the conflicts were resolved (for use in possible future forensic analyses).

@smithfarm smithfarm added this to the jewel milestone Jul 11, 2016
@odivlad
Copy link
Contributor Author

odivlad commented Jul 14, 2016

@smithfarm, can you please provide the example of such description?

@tchaikov
Copy link
Contributor

tchaikov commented Jul 14, 2016

@odivlad you can "git log origin/hammer" for some examples. like

in 4eea92b

Conflicts:
   src/rgw/rgw_rados.cc (hammer write_data() takes rgw_obj reference as
   4th argument, hammer throttle_data() takes rgw_obj as 2nd argument)

and in a2e7ca1

  Conflicts:
   src/test/msgr/perf_msgr_client.cc
   src/test/msgr/perf_msgr_server.cc
   src/test/perf_local.cc
         These three files were not introduced on hammer, just remove

@odivlad
Copy link
Contributor Author

odivlad commented Jul 14, 2016

done

@odivlad odivlad force-pushed the fix-init-el7-jewel branch 2 times, most recently from aed887d to 389203d Compare August 2, 2016 14:51
@ghost ghost assigned smithfarm Aug 10, 2016
@smithfarm
Copy link
Contributor

If a lead weighs in saying this should be backported to jewel, then I'm OK with it. Otherwise not. See discussion in #9871.

`systemd-run` logic in initscripts was introduced because of ticket
http://tracker.ceph.com/issues/7627.

If we have systemd-based operating system, we should use systemd unit files
from systemd directory to start/stop ceph daemons.
Otherwise, `daemon()` from `/etc/init.d/functions` on systemd distro starts service
in `system.slice` and everything works well.

`systemd-run` can not be run on non-systemd distros, so it's not needed
on SysV systems.

also, ceph-disk is now able to run the "systemctl"
to enable and start the ceph-osd, and ceph-deploy is also now
playing well with systemd when it comes to ceph-mon and ceph-mds

Fixes: http://tracker.ceph.com/issues/16440

Signed-off-by: Vladislav Odintsov <odivlad@gmail.com>
(cherry picked from commit 1fd4f92)
@odivlad
Copy link
Contributor Author

odivlad commented Oct 10, 2016

@smithfarm, I've updated PR with patching only radosgw initscripts.

@smithfarm
Copy link
Contributor

@oritwas wrote that she is OK to merge this, so I'm removing DNM.

@smithfarm smithfarm changed the title [DNM] jewel: remove SYSTEMD_RUN from initscript jewel: remove SYSTEMD_RUN from initscript Oct 10, 2016
ghost pushed a commit that referenced this pull request Oct 10, 2016
Reviewed-by: Loic Dachary <ldachary@redhat.com>
ghost pushed a commit that referenced this pull request Oct 10, 2016
Reviewed-by: Loic Dachary <ldachary@redhat.com>
ghost pushed a commit that referenced this pull request Oct 13, 2016
Reviewed-by: Loic Dachary <ldachary@redhat.com>
@ghost ghost merged commit 52e596f into ceph:jewel Oct 14, 2016
@odivlad odivlad deleted the fix-init-el7-jewel branch October 14, 2016 11:53
@theanalyst theanalyst changed the title jewel: remove SYSTEMD_RUN from initscript jewel: build/ops: remove SYSTEMD_RUN from initscript Nov 16, 2016
@theanalyst theanalyst changed the title jewel: build/ops: remove SYSTEMD_RUN from initscript "jewel: build/ops: remove SYSTEMD_RUN from initscript" Nov 17, 2016
@theanalyst theanalyst changed the title "jewel: build/ops: remove SYSTEMD_RUN from initscript" jewel: build/ops: remove SYSTEMD_RUN from initscript Nov 17, 2016
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants