1
/* Copyright (C) 2003 MySQL AB
3
This program is free software; you can redistribute it and/or modify
4
it under the terms of the GNU General Public License as published by
5
the Free Software Foundation; version 2 of the License.
7
This program is distributed in the hope that it will be useful,
8
but WITHOUT ANY WARRANTY; without even the implied warranty of
9
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10
GNU General Public License for more details.
12
You should have received a copy of the GNU General Public License
13
along with this program; if not, write to the Free Software
14
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
16
#ifndef BACKUP_FORMAT_HPP
17
#define BACKUP_FORMAT_HPP
19
#include <ndb_types.h>
21
static const char BACKUP_MAGIC[] = { 'N', 'D', 'B', 'B', 'C', 'K', 'U', 'P' };
26
* Section types in file
33
TABLE_DESCRIPTION = 5,
67
struct FragmentHeader {
83
Uint32 NullBitmask[1];
84
Uint32 DataFixedKeys[1];
85
Uint32 DataFixedAttributes[1];
86
VariableData DataVariableAttributes[1];
89
struct FragmentFooter {
98
/* optional padding for O_DIRECT */
101
Uint32 SectionLength;
116
Uint32 SectionLength;
117
Uint32 TableIds[1]; // Length = SectionLength - 2
121
* Table description(s)
123
struct TableDescription {
125
Uint32 SectionLength;
127
Uint32 DictTabInfo[1]; // Length = SectionLength - 3
135
Uint32 SectionLength;
143
struct FragmentInfo {
145
Uint32 SectionLength;
148
Uint32 NoOfRecordsLow;
149
Uint32 NoOfRecordsHigh;
166
// If TriggerEvent & 0x10000 == true then GCI is right after data
169
Uint32 Data[1]; // Len = Length - 3
173
* Log Entry pre NDBD_FRAGID_VERSION
175
struct LogEntry_no_fragid {
178
// If TriggerEvent & 0x10000 == true then GCI is right after data
180
Uint32 Data[1]; // Len = Length - 2
188
CtlFile::TableList TableList;
189
CtlFile::TableDescription TableDescription;
190
DataFile::FragmentHeader FragmentHeader;
191
DataFile::Record Record;
192
DataFile::FragmentFooter FragmentFooter;