Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
ae9698cf
Commit
ae9698cf
authored
Mar 11, 2003
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge gweir@bk-internal.mysql.com:/home/bk/mysql-4.0
into mysql.com:/home/greg/bk/mysql-4.0
parents
f1662f3b
0f88392d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
52 additions
and
2 deletions
+52
-2
netware/mysqld_safe.c
netware/mysqld_safe.c
+52
-2
No files found.
netware/mysqld_safe.c
View file @
ae9698cf
...
...
@@ -36,6 +36,7 @@
******************************************************************************/
char
autoclose
;
char
basedir
[
PATH_MAX
];
char
checktables
;
char
datadir
[
PATH_MAX
];
char
pid_file
[
PATH_MAX
];
char
address
[
PATH_MAX
];
...
...
@@ -54,6 +55,7 @@ FILE *log_fd = NULL;
******************************************************************************/
void
usage
(
void
);
void
vlog
(
char
*
,
va_list
);
void
log
(
char
*
,
...);
void
start_defaults
(
int
,
char
*
[]);
...
...
@@ -72,6 +74,42 @@ void mysql_start(int, char*[]);
******************************************************************************/
/******************************************************************************
usage()
Show usage.
******************************************************************************/
void
usage
(
void
)
{
// keep the screen up
setscreenmode
(
SCR_NO_MODE
);
puts
(
"\
\n
\
usage: mysqld_safe [options]
\n
\
\n
\
Program to start the MySQL daemon and restart it if it dies unexpectedly.
\n
\
All options, besides those listed below, are passed on to the MySQL daemon.
\n
\
\n
\
options:
\n
\
\n
\
--autoclose Automatically close the mysqld_safe screen.
\n
\
\n
\
--check-tables Check the tables before starting the MySQL daemon.
\n
\
\n
\
--err-log=<file> Send the MySQL daemon error output to <file>.
\n
\
\n
\
--help Show this help information.
\n
\
\n
\
--mysqld=<file> Use the <file> MySQL daemon.
\n
\
\n
\
"
);
exit
(
-
1
);
}
/******************************************************************************
vlog()
...
...
@@ -136,6 +174,9 @@ void start_defaults(int argc, char *argv[])
// basedir
get_basedir
(
argv
[
0
],
basedir
);
// check-tables
checktables
=
FALSE
;
// hostname
if
(
gethostname
(
hostname
,
PATH_MAX
)
<
0
)
{
...
...
@@ -279,13 +320,15 @@ void parse_args(int argc, char *argv[])
OPT_PORT
,
OPT_ERR_LOG
,
OPT_SAFE_LOG
,
OPT_MYSQLD
OPT_MYSQLD
,
OPT_HELP
};
static
struct
option
options
[]
=
{
{
"autoclose"
,
no_argument
,
&
autoclose
,
TRUE
},
{
"basedir"
,
required_argument
,
0
,
OPT_BASEDIR
},
{
"check-tables"
,
no_argument
,
&
checktables
,
TRUE
},
{
"datadir"
,
required_argument
,
0
,
OPT_DATADIR
},
{
"pid-file"
,
required_argument
,
0
,
OPT_PID_FILE
},
{
"bind-address"
,
required_argument
,
0
,
OPT_BIND_ADDRESS
},
...
...
@@ -293,6 +336,7 @@ void parse_args(int argc, char *argv[])
{
"err-log"
,
required_argument
,
0
,
OPT_ERR_LOG
},
{
"safe-log"
,
required_argument
,
0
,
OPT_SAFE_LOG
},
{
"mysqld"
,
required_argument
,
0
,
OPT_MYSQLD
},
{
"help"
,
no_argument
,
0
,
OPT_HELP
},
{
0
,
0
,
0
,
0
}
};
...
...
@@ -341,6 +385,10 @@ void parse_args(int argc, char *argv[])
strcpy
(
mysqld
,
optarg
);
break
;
case
OPT_HELP
:
usage
();
break
;
default:
// ignore
break
;
...
...
@@ -563,6 +611,8 @@ void mysql_start(int argc, char *argv[])
static
char
*
private_options
[]
=
{
"--autoclose"
,
"--check-tables"
,
"--help"
,
"--err-log="
,
"--mysqld="
,
NULL
...
...
@@ -594,7 +644,7 @@ void mysql_start(int argc, char *argv[])
do
{
// check the database tables
check_tables
();
if
(
checktables
)
check_tables
();
// status
time
(
&
cal
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment