| Bug #40583 | Agent startup doesn't produce a log file. | ||
|---|---|---|---|
| Submitted: | 7 Nov 2008 17:34 | Modified: | 28 Jan 2009 16:47 |
| Reporter: | Simon Mudd | ||
| Status: | Closed | ||
| Category: | Monitoring: Config | Severity: | S3 (Non-critical) |
| Version: | 2.0.0.7088 | OS: | Linux (CentOS 4 x86_64) |
| Assigned to: | MC Brown | Target Version: | |
[7 Nov 2008 17:34]
Simon Mudd
[14 Nov 2008 21:10]
Mark Matthews
Simon, Does the log file get produced if you fully-qualify the pathname, as you do with the pid file?
[17 Nov 2008 13:21]
Simon Mudd
Feedback provided but kept private due to internal information being shown. Summary: no difference noted when using a FQDN. A similar server does not exhibit this problem so I'm going to try and determine what differences there are between the 2 boxes.
[17 Nov 2008 16:32]
Debs Wade
When the full pathname is given to the binary then the agent operates normally.
So starting the agent like this:
sh -x /opt/mysql/enterprise/agent3/bin/mysql-monitor-agent
--defaults-file=/opt/mysql/enterprise/agent3/etc/mysql-monitor-agent.ini --daemon
--pid-file=/opt/mysql/enterprise/agent3/mysql-monitor-agent.pid
is a workaround and so is changing the init.d file to use the full path works
[snipped from modified init.d file]
## if the PID-file exists and the PID is used, don't start
if test -f $MERLIN_AGENT_PID; then
## pid-file exists, check if the process is still up
if kill -0 `cat $MERLIN_AGENT_PID` 2> /dev/null; then
## process is running, ok, out of here
echo -n "(already running)"
log_success_msg
exit 0
else
# it it's, start it
cd $MERLIN_AGENT_ROOTDIR
$MERLIN_AGENT_BIN $MERLIN_AGENT_OPTIONS >/dev/null 2>&1 &
wait_for_pid create
# Make lock for RedHat / SuSE
if test -w "/var/lock/subsys" ; then
touch "/var/lock/subsys/$MERLIN_AGENT_SERVICE"
fi
fi
else
# no PID file, no process. It's time to start one
cd $MERLIN_AGENT_ROOTDIR
$MERLIN_AGENT_BIN $MERLIN_AGENT_OPTIONS >/dev/null 2>&1 &
wait_for_pid create
[end -snip]
[22 Jan 2009 14:20]
Diego Medina
Verified *not* fixed yet on 2.0.2.7131 The mysql-monitor-agent script does not show the changes from the patch.
[22 Jan 2009 19:41]
Keith Russell
The 'init.d/mysql-monitor-agent' script has previously been picked up by the installer build from the installer repository. Therefore the mod by Kay was not picked up. The following changes have been made. Change made in versions => 2.0.4.7139. (except 2.1.0.1003) - The 'init.d/mysql-monitor-agent' script has been moved from the installer repository to the agent development repository. - The installer build has been modified accordingly for future builds. - The modified script was forwarded to Bitrock for review.
[27 Jan 2009 20:38]
Diego Medina
Verified fixed on 2.0.4.7140
[28 Jan 2009 16:47]
Tony Bedford
An entry has been added to the 2.0.4 changelog: The Service Agent startup configuration did not seem to work and did not generate a log file.
