1
/******************************************************
2
Starts the Innobase database server
4
(c) 1995-2000 Innobase Oy
6
Created 10/10/1995 Heikki Tuuri
7
*******************************************************/
16
/*************************************************************************
17
Normalizes a directory path for Windows: converts slashes to backslashes. */
20
srv_normalize_path_for_win(
21
/*=======================*/
22
char* str); /* in/out: null-terminated character string */
23
/*************************************************************************
24
Reads the data files and their sizes from a character string given in
28
srv_parse_data_file_paths_and_sizes(
29
/*================================*/
30
/* out: TRUE if ok, FALSE if parsing
32
char* str, /* in: the data file path string */
33
char*** data_file_names, /* out, own: array of data file
35
ulint** data_file_sizes, /* out, own: array of data file sizes
37
ulint** data_file_is_raw_partition,/* out, own: array of flags
38
showing which data files are raw
40
ulint* n_data_files, /* out: number of data files */
41
ibool* is_auto_extending, /* out: TRUE if the last data file is
43
ulint* max_auto_extend_size); /* out: max auto extend size for the
44
last file if specified, 0 if not */
45
/*************************************************************************
46
Reads log group home directories from a character string given in
50
srv_parse_log_group_home_dirs(
51
/*==========================*/
52
/* out: TRUE if ok, FALSE if parsing
54
char* str, /* in: character string */
55
char*** log_group_home_dirs); /* out, own: log group home dirs */
56
/*************************************************************************
57
Adds a slash or a backslash to the end of a string if it is missing
58
and the string is not empty. */
61
srv_add_path_separator_if_needed(
62
/*=============================*/
63
/* out: string which has the separator if the
64
string is not empty */
65
char* str); /* in: null-terminated character string */
66
/********************************************************************
67
Starts Innobase and creates a new database if database files
68
are not found and the user wants. Server parameters are
69
read from a file of name "srv_init" in the ib_home directory. */
72
innobase_start_or_create_for_mysql(void);
73
/*====================================*/
74
/* out: DB_SUCCESS or error code */
75
/********************************************************************
76
Shuts down the Innobase database. */
78
innobase_shutdown_for_mysql(void);
79
/*=============================*/
80
/* out: DB_SUCCESS or error code */
81
extern dulint srv_shutdown_lsn;
82
extern dulint srv_start_lsn;
85
void set_panic_flag_for_netware(void);
88
#ifdef HAVE_DARWIN_THREADS
89
extern ibool srv_have_fullfsync;
92
extern ulint srv_sizeof_trx_t_in_ha_innodb_cc;
94
extern ibool srv_is_being_started;
95
extern ibool srv_startup_is_before_trx_rollback_phase;
96
extern ibool srv_is_being_shut_down;
98
extern ibool srv_start_raw_disk_in_use;
100
/* At a shutdown the value first climbs from 0 to SRV_SHUTDOWN_CLEANUP
101
and then to SRV_SHUTDOWN_LAST_PHASE, and so on */
103
extern ulint srv_shutdown_state;
105
#define SRV_SHUTDOWN_CLEANUP 1
106
#define SRV_SHUTDOWN_LAST_PHASE 2
107
#define SRV_SHUTDOWN_EXIT_THREADS 3
109
/* Log 'spaces' have id's >= this */
110
#define SRV_LOG_SPACE_FIRST_ID 0xFFFFFFF0UL