[
https://issues.apache.org/jira/browse/HBASE-18274?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Fangyuan Deng updated HBASE-18274:
----------------------------------
Description:
While using hbase autorestart , the gc log will be overwirited after the
process(hmaster or hregionserver) retarting.
This is because the autorestart loop is in internal_autostart function ( in
hbase-daemon.sh), but we only rotate the gc log in autorestart function.
(internal_autostart)
ONE_HOUR_IN_SECS=3600
autostartWindowStartDate=`date +%s`
autostartCount=0
touch "$HBASE_AUTOSTART_FILE"
# keep starting the command until asked to stop. Reloop on software crash
while true
do
code # restart the hbase process util the cluster is shut down
fi
(autorestart)
echo running $command, logging to $HBASE_LOGOUT
# stop the command
$thiscmd --config "${HBASE_CONF_DIR}" stop $command $args &
wait_until_done $!
# wait a user-specified sleep period
sp=${HBASE_RESTART_SLEEP:-3}
if [ $sp -gt 0 ]; then
sleep $sp
fi
check_before_start
hbase_rotate_log $HBASE_LOGOUT
hbase_rotate_log $HBASE_LOGGC
nohup $thiscmd --config "${HBASE_CONF_DIR}" --autostart-window-size
${AUTOSTART_WINDOW_SIZE} --autostart-window-retry-limit
${AUTOSTART_WINDOW_RETRY_LIMIT} \
internal_autostart $command $args < /dev/null > ${HBASE_LOGOUT} 2>&1 &
was:
While using hbase autorestart , the gc log will be overwirited after the
process(hmaster or hregionserver) retarting.
This is because the autorestart loop is in internal_autostart function ( in
hbase-daemon.sh), but we only rotate the gc log in autorestart function.
> hbase autorestart will overwirte the gc log
> -------------------------------------------
>
> Key: HBASE-18274
> URL: https://issues.apache.org/jira/browse/HBASE-18274
> Project: HBase
> Issue Type: Bug
> Components: hbase
> Affects Versions: 1.2.6, 1.1.11, 2.0.0-alpha-1
> Reporter: Fangyuan Deng
> Attachments: HBASE-18274.0.patch
>
>
> While using hbase autorestart , the gc log will be overwirited after the
> process(hmaster or hregionserver) retarting.
> This is because the autorestart loop is in internal_autostart function ( in
> hbase-daemon.sh), but we only rotate the gc log in autorestart function.
> (internal_autostart)
> ONE_HOUR_IN_SECS=3600
> autostartWindowStartDate=`date +%s`
> autostartCount=0
> touch "$HBASE_AUTOSTART_FILE"
> # keep starting the command until asked to stop. Reloop on software crash
> while true
> do
> code # restart the hbase process util the cluster is shut down
> fi
> (autorestart)
> echo running $command, logging to $HBASE_LOGOUT
> # stop the command
> $thiscmd --config "${HBASE_CONF_DIR}" stop $command $args &
> wait_until_done $!
> # wait a user-specified sleep period
> sp=${HBASE_RESTART_SLEEP:-3}
> if [ $sp -gt 0 ]; then
> sleep $sp
> fi
> check_before_start
> hbase_rotate_log $HBASE_LOGOUT
> hbase_rotate_log $HBASE_LOGGC
> nohup $thiscmd --config "${HBASE_CONF_DIR}" --autostart-window-size
> ${AUTOSTART_WINDOW_SIZE} --autostart-window-retry-limit
> ${AUTOSTART_WINDOW_RETRY_LIMIT} \
> internal_autostart $command $args < /dev/null > ${HBASE_LOGOUT} 2>&1
> &
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)