Bug 952297
Summary: | PRD33 - ovirt-engine service re-work | ||
---|---|---|---|
Product: | Red Hat Enterprise Virtualization Manager | Reporter: | Alon Bar-Lev <alonbl> |
Component: | ovirt-engine | Assignee: | Alon Bar-Lev <alonbl> |
Status: | CLOSED ERRATA | QA Contact: | Ilanit Stein <istein> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | unspecified | CC: | aburden, acathrow, alonbl, iheim, jkt, lpeer, mgoldboi, Rhev-m-bugs, sbonazzo, yeylon |
Target Milestone: | --- | Keywords: | Improvement |
Target Release: | 3.3.0 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | integration | ||
Fixed In Version: | is1 | Doc Type: | Enhancement |
Doc Text: |
I am unsure this should go into docs.
comment#0 should cover all required information.
|
Story Points: | --- |
Clone Of: | Environment: | ||
Last Closed: | 2014-01-21 17:17:31 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | 954359 | ||
Bug Blocks: | 838527, 959800, 976171 |
Description
Alon Bar-Lev
2013-04-15 15:33:12 UTC
packaging: service: do not use users from configuration if non-root packaging: service: only verify engine user owned directories owner In development mode directories will not be owned by root. packaging: engine-service: recover from corrupted pid file The case in which pidfile is empty is common. packaging: engine-service: remove limits.d file the limits.d file is not used as service applies rlimit on its own. packaging: engine-service: allow service user customization packaging: engine-service: use python daemon instead of own implementation packaging: engine-service: rework start pid file handling There is no reason to force user to explicit stop and start the service in case pid file contains non running process. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=838527 Change-Id: I8d8a7f8f8b7f5941f447df3d279686b973b5c393 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: add options for wrappers In order to be used at other environments, with their own init.d layout, Add: --quiet --pidfile --foreground Change-Id: I00d868fc51ec73800cae2eb24002feb933744851 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: downstream infrastructure usage Use features of downstream instead our own implementation. systemd 1. detach from controlling terminal. 2. Change user/group. 3. stop service using signal. 4. set rlimit. sysv 1. Change user/group. 2. stop service by pidfile. 3. set rlimit systemd note: As jboss return non zero error code when receiving SIGTERM, and systemd expect processes to terminate with zero error code, we create a wrapper over the java. Change-Id: Ie02f0d44bbba7d1a7af6bcf6b808610e85b907c6 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: remove dead code Change-Id: Id520a0ff33e797b2995fb217754605c219f6a922 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: set default service mode to foreground this will ease developer when executing the service. Change-Id: Ib7e5ffe4e104d2c3a0c931f3f344f7c3c12eb57f Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: remove /usr/bin symlink The engine-service script is not a utility to be used by user but by downstream packager, hence no reason to install at /usr/bin. Change-Id: I49fc25ad586b8f04e1588d04ab772858f2bfd169 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: do not allow execution as non-root all downstream has a mean to execute the script under the correct account. So no need for us to change identity nor expect other user. Change-Id: Ic30ce5316918a98bf2ef4cbf17d0eb91b85c74d1 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: do not clean environment the init system may put important variables in environment. add LC_ALL as java is effected by AC_CTYPE per defaults of string conversions, as if it is set by init it will effect us. in practice we should only set LC_CTYPE or use jnu.encoding, when we are sure that no default locale is used for conversions within application. Change-Id: Ia8231b343574df83e65c55d9ffa75698a3f2d692 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: remove unused tmpfiles config Change-Id: I81175c21f018be180157ffcaadef1dd28ee8801c Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: move service to backend subpackage Change-Id: I3df9c0f0d221d883c7a49b0c7f953a2ffde211c0 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: major cleanup Last patch in series of engine-service, after all core issues merged into existing implementation, this introduce python only rework and cleanups. 1. Removal global variable. 2. Previous patch already use python subprocess instead of direct exec. 3. Use python logging instead of direct syslog calls. 4. Add debug log. 5. Add debug parameter. 6. Add gettext support. 7. Modular functional. 8. Remove one time used variables. 9. Remove replication of configuration variable into local variables. 10. Remove dead code. 11. pyflakes free 12. pep8 complaint. Change-Id: Iea45e8131190f41171e937699ec2e261939c4bd9 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: fix systemd packaging per fedora requirements Change-Id: I84d290d2cc389450be183cd85fb91ee1e58e4e9a Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: clean /var/tmp in upgrade and cleanup previous service implementation used mixed ownership of root/ovirt in /var/tmp/ovirt-engine, /var/lib/ovirt-engine/deployments. the /var/tmp/ovirt-engine was not cleared if daemon exited so likely to remain. new service implementation does not run under root account, so having root owned resources is not healthy. during upgrade setup correct setting, during setup remove leftovers, as engine-cleanup not to be trusted as it does not actually revert to initial state. Change-Id: If0efa0b8a71673140490e2c363af7d3ba6044ffe Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: cleanup: merge check for running process Change-Id: I20238c634c418029c669bdf2b4b77e329b39faa1 Signed-off-by: Alon Bar-Lev <alonbl> Modified per future rebase. packaging: engine-service: move service out of fedora into own directory service is working in fedora, rhel, cenots, gentoo, ubuntu. service resources are installed at one directory at target, reorder filesystem structure within source tree to be similar. Change-Id: I38c2653509795ae04c190c4a84f00f53410fa983 Signed-off-by: Alon Bar-Lev <alonbl> packaging: engine-service: split service to allow code reuse this will allow to reuse effort to implement other services. Change-Id: Ie912a502f220417e72efbd2f5b87c5674525f79b Signed-off-by: Alon Bar-Lev <alonbl> Got need-info but I cannot see this in bug. How to test this is drop-in replacement using re-implementation using downstream services. existing tests should be sufficient. thanks. ACKed Verified on is3: [root@istein-33 ~]# service ovirt-engine status (pid 27342) is running... [root@istein-33 ~]# service ovirt-engine stop Stopping oVirt Engine: [ OK ] [root@istein-33 ~]# service ovirt-engine start Starting oVirt Engine: [ OK ] [root@istein-33 ~]# service ovirt-engine status (pid 21751) is running... [root@istein-33 ~]# kill -9 21751 [root@istein-33 ~]# service ovirt-engine status dead but pid file exists This bug is currently attached to errata RHEA-2013:15231. If this change is not to be documented in the text for this errata please either remove it from the errata, set the requires_doc_text flag to minus (-), or leave a "Doc Text" value of "--no tech note required" if you do not have permission to alter the flag. Otherwise to aid in the development of relevant and accurate release documentation, please fill out the "Doc Text" field above with these four (4) pieces of information: * Cause: What actions or circumstances cause this bug to present. * Consequence: What happens when the bug presents. * Fix: What was done to fix the bug. * Result: What now happens when the actions or circumstances above occur. (NB: this is not the same as 'the bug doesn't present anymore') Once filled out, please set the "Doc Type" field to the appropriate value for the type of change made and submit your edits to the bug. For further details on the Cause, Consequence, Fix, Result format please refer to: https://bugzilla.redhat.com/page.cgi?id=fields.html#cf_release_notes Thanks in advance. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. http://rhn.redhat.com/errata/RHSA-2014-0038.html |