Skip to Content
0

manually switch log

Oct 27, 2016 at 04:39 AM

655

avatar image
Former Member

hi, Just wanted to ask if it was possible to manually switch log file on HANA .

regards
Jonu

10 |10000 characters needed characters left characters exceeded

This question had been asked and answered a couple of times before. Please do your part of the know-how game and research before posting a question.

- Lars (Moderator)

0
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Denys van Kempen
Oct 28, 2016 at 07:53 AM
2

Hi Jonu,

As in ... Oracle?

ALTER SYSTEM SWITCH LOGFILE

https://docs.oracle.com/cd/B28359_01/server.111/b28310/onlineredo006.htm

==

A log switch occurs when LGWR stops writing to one redo log group and starts writing to another. By default, a log switch occurs automatically when the current redo log file group fills.

You can force a log switch to make the currently active group inactive and available for redo log maintenance operations. For example, you want to drop the currently active group, but are not able to do so until the group is inactive. You may also wish to force a log switch if the currently active group needs to be archived at a specific time before the members of the group are completely filled. This option is useful in configurations with large redo log files that take a long time to fill.

==

SAP HANA implements logging differently; there are no redo log groups, there is no LGWR, and you do not do any redo maintenance operations.

All you need to do after installation is to make an initial backup of the system. This will trigger SAP HANA to switch from log mode overwrite to log mode normal.

Read: Log Modes

In log mode normal, logging is a completely automatic operation that requires no manual maintenance.

Read: Savepoints and Redo Logs and Persistent Data Storage in the SAP HANA Database.

But if you insist, there is one thing you can do

ALTER SYSTEM RECLAIM LOG

ALTER SYSTEM RECLAIM LOG Statement

==

Log segment accumulation can be caused in several ways. For example, when automatic log backup is not operational for a long period or a log savepoint is blocked for an extended time. When such issues occur, use the ALTER SYSTEM RECLAIM LOG command, but only after the root cause of the log accumulation has been fixed.

==

If you want to learn more, there is a full playlist at the SAP HANA Academy about Database Backup and Recovery: http://bit.ly/2eNfXJf

For an update about what's new for the latest release on this topic, see

https://blogs.sap.com/2016/05/27/sap-hana-sps-12-whats-new-backup-and-recovery-by-the-sap-hana-academy/

Regards,

Denys

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Oct 31, 2016 at 02:49 AM
0

thx much Denys

Share
10 |10000 characters needed characters left characters exceeded