[ 
https://issues.apache.org/jira/browse/VCL-966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15997339#comment-15997339
 ] 

ASF subversion and git services commented on VCL-966:
-----------------------------------------------------

Commit 1793863 from [email protected] in branch 'vcl/trunk'
[ https://svn.apache.org/r1793863 ]

VCL-966
Reworked Upstart.pm to be able to control some service control functions for 
services that can't be controlled by initctl.

Added Upstart.pm::_get_service_info. Much of it was previously in 
get_service_names. Added call to 'service --status-all' after 'initctl list' is 
executed. The service command may show additional services which can't be 
controlled by initctl such as xrdp. A hash is constructed containing service 
name keys and the utility used to control the service (service/initctl) as the 
values.

Added subroutines:
* Upstart.pm::_controlled_by_service_command
* Upstart.pm::_call_service_start
* Upstart.pm::_call_service_stop
* Upstart.pm::_call_service_restart
* Upstart.pm::_call_service_status

Added code to start_service, stop..., etc to check if the initctl or service 
command should be used via _controlled_by_service_command. If service is used, 
the corresponding _call_service_* subroutine is called.

Included code in _call_service_stop to overcome problems due to bugs in the 
xrdp service. It doesn't always clean up the .pid file and this prevents the 
service from being restarted.

> Ubuntu not detecting SysV-controlled services if chkconfig is not installed
> ---------------------------------------------------------------------------
>
>                 Key: VCL-966
>                 URL: https://issues.apache.org/jira/browse/VCL-966
>             Project: VCL
>          Issue Type: Improvement
>          Components: vcld (backend)
>    Affects Versions: 2.4.2
>            Reporter: Andy Kurth
>             Fix For: 2.5
>
>
> SysV-controlled services are not being correctly detected in Ubuntu if the 
> _chkconfig_ utility is not installed.  An example is xRDP.  When installed 
> via apt-get, the xRDP service is controlled by SysV.  The service appears if 
> you run *service --status-all*:
> {noformat} [ + ]  xrdp{noformat}
> The code is attempting to call *chkconfig*.  On Ubuntu 14 and possibly 
> others, this utility is not available on recent versions of Ubuntu.
> As a result, warnings are generated in vcld.log:
> {noformat}
> Linux.pm:command_exists|5567|'chkconfig' command does NOT exist on vm1, 
> command: which chkconfig
> Linux.pm:service_exists|3438|'xrdp' service is not controlled by Upstart init 
> module (0)
> Linux.pm:service_exists|3443|'xrdp' service does not exist on vm1
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to