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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
393bd5cf
Commit
393bd5cf
authored
Jul 17, 2002
by
Sinisa@sinisa.nasamreza.org
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Another try to fix slave timeouts
parent
46047734
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
sql/mini_client.cc
sql/mini_client.cc
+4
-1
sql/slave.cc
sql/slave.cc
+4
-3
No files found.
sql/mini_client.cc
View file @
393bd5cf
...
@@ -112,6 +112,8 @@ static my_bool is_NT(void)
...
@@ -112,6 +112,8 @@ static my_bool is_NT(void)
}
}
#endif
#endif
extern
ulong
slave_net_timeout
;
/*
/*
** Create a named pipe connection
** Create a named pipe connection
*/
*/
...
@@ -203,6 +205,7 @@ mc_mysql_init(MYSQL *mysql)
...
@@ -203,6 +205,7 @@ mc_mysql_init(MYSQL *mysql)
#ifdef __WIN__
#ifdef __WIN__
mysql
->
options
.
connect_timeout
=
20
;
mysql
->
options
.
connect_timeout
=
20
;
#endif
#endif
mysql
->
net
.
timeout
=
slave_net_timeout
;
return
mysql
;
return
mysql
;
}
}
...
@@ -655,7 +658,7 @@ mc_mysql_connect(MYSQL *mysql,const char *host, const char *user,
...
@@ -655,7 +658,7 @@ mc_mysql_connect(MYSQL *mysql,const char *host, const char *user,
goto
error
;
goto
error
;
}
}
vio_keepalive
(
net
->
vio
,
TRUE
);
vio_keepalive
(
net
->
vio
,
TRUE
);
net
->
timeout
=
slave_net_timeout
;
/* Get version info */
/* Get version info */
mysql
->
protocol_version
=
PROTOCOL_VERSION
;
/* Assume this */
mysql
->
protocol_version
=
PROTOCOL_VERSION
;
/* Assume this */
if
((
pkt_length
=
mc_net_safe_read
(
mysql
))
==
packet_error
)
if
((
pkt_length
=
mc_net_safe_read
(
mysql
))
==
packet_error
)
...
...
sql/slave.cc
View file @
393bd5cf
...
@@ -456,7 +456,7 @@ int fetch_nx_table(THD* thd, MASTER_INFO* mi)
...
@@ -456,7 +456,7 @@ int fetch_nx_table(THD* thd, MASTER_INFO* mi)
nx_errno
=
ER_BAD_HOST_ERROR
;
nx_errno
=
ER_BAD_HOST_ERROR
;
goto
err
;
goto
err
;
}
}
mysql
->
net
.
timeout
=
slave_net_timeout
;
safe_connect
(
thd
,
mysql
,
mi
);
safe_connect
(
thd
,
mysql
,
mi
);
if
(
slave_killed
(
thd
))
if
(
slave_killed
(
thd
))
goto
err
;
goto
err
;
...
@@ -1312,7 +1312,7 @@ pthread_handler_decl(handle_slave,arg __attribute__((unused)))
...
@@ -1312,7 +1312,7 @@ pthread_handler_decl(handle_slave,arg __attribute__((unused)))
goto
err
;
goto
err
;
}
}
mysql
->
net
.
timeout
=
slave_net_timeout
;
thd
->
proc_info
=
"connecting to master"
;
thd
->
proc_info
=
"connecting to master"
;
#ifndef DBUG_OFF
#ifndef DBUG_OFF
sql_print_error
(
"Slave thread initialized"
);
sql_print_error
(
"Slave thread initialized"
);
...
@@ -1331,7 +1331,8 @@ pthread_handler_decl(handle_slave,arg __attribute__((unused)))
...
@@ -1331,7 +1331,8 @@ pthread_handler_decl(handle_slave,arg __attribute__((unused)))
}
}
connected:
connected:
mysql
->
net
.
timeout
=
slave_net_timeout
;
while
(
!
slave_killed
(
thd
))
while
(
!
slave_killed
(
thd
))
{
{
thd
->
proc_info
=
"Requesting binlog dump"
;
thd
->
proc_info
=
"Requesting binlog dump"
;
...
...
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