[
https://issues.apache.org/jira/browse/AMQ-6190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Ben Magistro updated AMQ-6190:
------------------------------
Labels: easyfix (was: )
Description:
When "ACTIVEMQ_USER" is defined and launching via "./bin/activemq start" PID
file is owned by the defined user. If launching as "./bin/activemq console"
PID file is owned by the calling user. Subsequent calls to "start" may fail as
permissions would not allow the defined user to manipulate the file.
Workarounds:
1) call console using "sudo -u <defined user> ./bin/activemq console" (or
switch to the user if it is allowed (user may not be allowed to login)
2) change ownership of pid file
3) remove pid file
Suggest either creating the pid file using the defined user and/or removing the
pid file once ctrl+c has been pressed/console run ends.
Edit:
Looking at the script there is a print line to say it is removing thepid file
but the command to do the work is no present. Using others in the script as a
reference, at line 481 insert "rm -f "$ACTIVEMQ_PIDFILE" >/dev/null 2>&1"
was:
When "ACTIVEMQ_USER" is defined and launching via "./bin/activemq start" PID
file is owned by the defined user. If launching as "./bin/activemq console"
PID file is owned by the calling user. Subsequent calls to "start" may fail as
permissions would not allow the defined user to manipulate the file.
Workarounds:
1) call console using "sudo -u <defined user> ./bin/activemq console" (or
switch to the user if it is allowed (user may not be allowed to login)
2) change ownership of pid file
3) remove pid file
Suggest either creating the pid file using the defined user and/or removing the
pid file once ctrl+c has been pressed/console run ends.
May attempt writing a patch.
> When running "./bin/activemq console" PID file is not owned by "ACTIVEMQ_USER"
> ------------------------------------------------------------------------------
>
> Key: AMQ-6190
> URL: https://issues.apache.org/jira/browse/AMQ-6190
> Project: ActiveMQ
> Issue Type: Bug
> Affects Versions: 5.13.0
> Environment: CentOS 6.x
> Reporter: Ben Magistro
> Priority: Minor
> Labels: easyfix
>
> When "ACTIVEMQ_USER" is defined and launching via "./bin/activemq start" PID
> file is owned by the defined user. If launching as "./bin/activemq console"
> PID file is owned by the calling user. Subsequent calls to "start" may fail
> as permissions would not allow the defined user to manipulate the file.
> Workarounds:
> 1) call console using "sudo -u <defined user> ./bin/activemq console" (or
> switch to the user if it is allowed (user may not be allowed to login)
> 2) change ownership of pid file
> 3) remove pid file
> Suggest either creating the pid file using the defined user and/or removing
> the pid file once ctrl+c has been pressed/console run ends.
> Edit:
> Looking at the script there is a print line to say it is removing thepid file
> but the command to do the work is no present. Using others in the script as
> a reference, at line 481 insert "rm -f "$ACTIVEMQ_PIDFILE" >/dev/null 2>&1"
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)