00001 /***************************************************************************** 00002 00003 Copyright (C) 1995, 2009, Innobase Oy. All Rights Reserved. 00004 00005 This program is free software; you can redistribute it and/or modify it under 00006 the terms of the GNU General Public License as published by the Free Software 00007 Foundation; version 2 of the License. 00008 00009 This program is distributed in the hope that it will be useful, but WITHOUT 00010 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 00011 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. 00012 00013 You should have received a copy of the GNU General Public License along with 00014 this program; if not, write to the Free Software Foundation, Inc., 51 Franklin 00015 St, Fifth Floor, Boston, MA 02110-1301 USA 00016 00017 *****************************************************************************/ 00018 00019 /**************************************************/ 00026 #pragma once 00027 #ifndef srv0start_h 00028 #define srv0start_h 00029 00030 #include "univ.i" 00031 #include "ut0byte.h" 00032 00033 /*********************************************************************/ 00035 UNIV_INTERN 00036 void 00037 srv_normalize_path_for_win( 00038 /*=======================*/ 00039 char* str); 00040 /*********************************************************************/ 00044 UNIV_INTERN 00045 ibool 00046 srv_parse_data_file_paths_and_sizes( 00047 /*================================*/ 00048 char* str); 00049 /*********************************************************************/ 00053 UNIV_INTERN 00054 ibool 00055 srv_parse_log_group_home_dirs( 00056 /*==========================*/ 00057 char* str); 00058 /*********************************************************************/ 00061 UNIV_INTERN 00062 void 00063 srv_free_paths_and_sizes(void); 00064 /*==========================*/ 00065 /*********************************************************************/ 00069 UNIV_INTERN 00070 char* 00071 srv_add_path_separator_if_needed( 00072 /*=============================*/ 00073 char* str); 00074 #ifndef UNIV_HOTBACKUP 00075 /****************************************************************/ 00079 UNIV_INTERN 00080 int 00081 innobase_start_or_create_for_mysql(void); 00082 /*====================================*/ 00083 /****************************************************************/ 00086 UNIV_INTERN 00087 int 00088 innobase_shutdown_for_mysql(void); 00089 /*=============================*/ 00091 extern ib_uint64_t srv_shutdown_lsn; 00093 extern ib_uint64_t srv_start_lsn; 00094 00095 #ifdef HAVE_DARWIN_THREADS 00096 00097 extern ibool srv_have_fullfsync; 00098 #endif 00099 00101 extern ibool srv_is_being_started; 00103 extern ibool srv_was_started; 00106 extern ibool srv_startup_is_before_trx_rollback_phase; 00107 00109 extern ibool srv_start_raw_disk_in_use; 00110 00111 00113 enum srv_shutdown_state { 00114 SRV_SHUTDOWN_NONE = 0, 00115 SRV_SHUTDOWN_CLEANUP, 00117 SRV_SHUTDOWN_LAST_PHASE, 00120 SRV_SHUTDOWN_EXIT_THREADS 00121 }; 00122 00125 extern enum srv_shutdown_state srv_shutdown_state; 00126 #endif /* !UNIV_HOTBACKUP */ 00127 00129 #define SRV_LOG_SPACE_FIRST_ID 0xFFFFFFF0UL 00130 00131 #endif