HW_ERROR(3) 1 HW_ERROR(3)hw_Error - Error numberSYNOPSIS
int hw_error (int $connection)
DESCRIPTION
Returns the last error number, for the last command.
PARAMETERS
o $connection
- The connection identifier.
RETURN VALUES
Returns the last error number or 0 if no error occurred.
SEE ALSO hw_errormsg(3).
PHP Documentation Group HW_ERROR(3)
Check Out this Related Man Page
MYSQLI_THREAD_ID(3) 1 MYSQLI_THREAD_ID(3)mysqli::$thread_id - Returns the thread ID for the current connection
Object oriented style
SYNOPSIS
int$mysqli->thread_id ()
DESCRIPTION
Procedural style
int mysqli_thread_id (mysqli $link)
The mysqli_thread_id(3) function returns the thread ID for the current connection which can then be killed using the mysqli_kill(3) func-
tion. If the connection is lost and you reconnect with mysqli_ping(3), the thread ID will be other. Therefore you should get the thread ID
only when you need it.
Note
The thread ID is assigned on a connection-by-connection basis. Hence, if the connection is broken and then re-established a new
thread ID will be assigned.
To kill a running query you can use the SQL command KILL QUERY processid.
PARAMETERS
o $
link -Procedural style only: A link identifier returned by mysqli_connect(3) or mysqli_init(3)RETURN VALUES
Returns the Thread ID for the current connection.
EXAMPLES
Example #1
$mysqli->thread_id example
Object oriented style
<?php
$mysqli = new mysqli("localhost", "my_user", "my_password", "world");
/* check connection */
if (mysqli_connect_errno()) {
printf("Connect failed: %s
", mysqli_connect_error());
exit();
}
/* determine our thread id */
$thread_id = $mysqli->thread_id;
/* Kill connection */
$mysqli->kill($thread_id);
/* This should produce an error */
if (!$mysqli->query("CREATE TABLE myCity LIKE City")) {
printf("Error: %s
", $mysqli->error);
exit;
}
/* close connection */
$mysqli->close();
?>
Procedural style
<?php
$link = mysqli_connect("localhost", "my_user", "my_password", "world");
/* check connection */
if (mysqli_connect_errno()) {
printf("Connect failed: %s
", mysqli_connect_error());
exit();
}
/* determine our thread id */
$thread_id = mysqli_thread_id($link);
/* Kill connection */
mysqli_kill($link, $thread_id);
/* This should produce an error */
if (!mysqli_query($link, "CREATE TABLE myCity LIKE City")) {
printf("Error: %s
", mysqli_error($link));
exit;
}
/* close connection */
mysqli_close($link);
?>
The above examples will output:
Error: MySQL server has gone away
SEE ALSO mysqli_kill(3).
PHP Documentation Group MYSQLI_THREAD_ID(3)
Hi all,
i have run iostat -em, and get below result. Can i know what is this output meaning, and how to fix that problem.
iostat -em
---- errors ---
device s/w h/w trn tot
sd7 0 1 0 1
sd8 1 1 0 2
sd9 0 1 0 1
sd10 0 ... (2 Replies)
Hi, it seems I've got an hw error on more than one device.
I use an AIX 5.2.
this is the problem desc.
Description
DISK OPERATION ERROR
Probable Causes
DASD DEVICE
Failure Causes
DISK DRIVE
DISK DRIVE ELECTRONICS
I wish to read the SYSLOG file, where is it ?
tk (1 Reply)
A mirror Raid system with two disk (probabaly raid1: Sun solaris Netra 240)
the following error occured
when I look at it with metastat :
d101: Submirror of d100
State: Needs maintenance
Invoke: metareplace d100 c1t0d0s5 <new device>
is there any advice that it indicates that... (15 Replies)
Hi,
i am running an old Opensolaris 5.11 snv_111b on an x86 server. After almost 4 years of successful service, last night out of the blue started to refuse all connections to it's services, ssh, http,etc. The only visible solution at that time was a restart. But now instead of booting the... (2 Replies)
Hi,
we have a server that runs on redhat linux. It was working fine until last year and all of sudden we are not able to ssh on to that server. we are getting the ping response but not getting the login prompt when tried to connect via ssh.
Port 22 is opened and i have tested it out using... (6 Replies)