View Issue Details

IDProjectCategoryView StatusLast Update
1237RackTablesdefaultpublic2014-06-06 21:37
Reportercabbiebatman Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionwon't fix 
PlatformLinuxOSCentosOS Version6.2
Product Version0.20.7 
Summary1237: Linkmgmt plugin SQLSTATE[HY000] error
DescriptionError when creating links
Pdo exception: PDOException
SQLSTATE[HY000]: General error: 1267 Illegal mix of collations (utf8_bin,NONE) and (utf8_general_ci,COERCIBLE) for operation 'ifnull' (HY000)

at file /var/www/html/RackTables/inc/database.php, line 3845

/var/www/html/RackTables/inc/database.php:3845 execute(Array
(
    [0] => 24
    [1] => 24
    [2] => 13614
    [3] => 1508
Steps To ReproduceCreate link
TagsNo tags attached.
Attached Files
linkmgmt error.txt (3,839 bytes)   
Pdo exception: PDOException
SQLSTATE[HY000]: General error: 1267 Illegal mix of collations (utf8_bin,NONE) and (utf8_general_ci,COERCIBLE) for operation 'ifnull' (HY000)

at file /var/www/html/RackTables/inc/database.php, line 3845

/var/www/html/RackTables/inc/database.php:3845 execute(Array
(
    [0] => 24
    [1] => 24
    [2] => 13614
    [3] => 1508
)
)
/var/www/html/plugins/Linkmgmt.php:1839 usePreparedSelectBlade('SELECT remotePort.id, CONCAT(IFNULL(remoteObject.name, CONCAT('[',remoteObjectDictionary.dict_value,']')), ' : ', remotePort.name,
				IFNULL(CONCAT(' == ', IFNULL(IFNULL(infolnk_a.cable,infolnk_b.cable),''), ' ==> ', InfoPort.name, ' : ', IFNULL(InfoObject.name,CONCAT('[',InfoObjectDictionary.dict_value,']'))),'') ) as Text FROM Port as remotePort LEFT JOIN Object as remoteObject on remotePort.object_id = remoteObject.id LEFT JOIN Dictionary as remoteObjectDictionary on (remoteObjectDictionary.chapter_id = 1 AND remoteObject.objtype_id = remoteObjectDictionary.dict_key) LEFT JOIN LinkBackend as infolnk_a on remotePort.id = infolnk_a.porta LEFT JOIN LinkBackend as infolnk_b on remotePort.id = infolnk_b.portb LEFT JOIN Port as InfoPort on InfoPort.id = IFNULL(infolnk_a.portb, infolnk_b.porta) LEFT JOIN Object as InfoObject on InfoObject.id = InfoPort.object_id LEFT JOIN Dictionary as InfoObjectDictionary on (InfoObject.objtype_id = InfoObjectDictionary.dict_key  AND InfoObjectDictionary.chapter_id = 1) LEFT JOIN Link as lnk_a on remotePort.id = lnk_a.porta LEFT JOIN Link as lnk_b on remotePort.id = lnk_b.portb INNER JOIN PortInnerInterface pii ON remotePort.iif_id = pii.id
			INNER JOIN Dictionary d ON d.dict_key = remotePort.type INNER JOIN (
			SELECT Port.id FROM Port
			INNER JOIN
			(
				SELECT DISTINCT pic2.iif_id
					FROM PortInterfaceCompat pic2
					INNER JOIN PortCompat pc ON pc.type2 = pic2.oif_id WHERE pc.type1 = ? AND pic2.iif_id <> 1
			 ) AS sub1 USING (iif_id)
			UNION
			SELECT Port.id
			FROM Port
			INNER JOIN PortCompat ON type1 = type
			WHERE iif_id = 1 and type2 = ?
			) AS sub2 ON sub2.id = remotePort.id WHERE remotePort.id <> ? AND lnk_a.porta is NULL AND lnk_b.portb is NULL AND remotePort.object_id IN (SELECT DISTINCT object_id FROM RackSpace WHERE rack_id IN (?))  ORDER BY remoteObject.name ,remotePort.name', Array
(
    [0] => 24
    [1] => 24
    [2] => 13614
    [3] => 1508
)
)
/var/www/html/plugins/Linkmgmt.php:1946 linkmgmt_findSparePorts(Array
(
    [id] => 13614
    [name] => 1
    [object_id] => 1857
    [object_name] => LDC-AC-TEST
    [l2address] => 
    [label] => 
    [reservation_comment] => 
    [iif_id] => 1
    [oif_id] => 24
    [iif_name] => hardwired
    [oif_name] => 1000Base-T
    [cableid] => 
    [remote_id] => 
    [remote_name] => 
    [remote_object_id] => 
    [remote_object_name] => 
    [log_count] => 0
    [linked] => 0
    [last_log] => Array
        (
        )

)
, Array
(
    [racks] => Array
        (
            [0] => 1508
        )

    [objects] => 
    [object_id] => 
    [ports] => 
)
, 'front', , , , 1)
linkmgmt_renderPopupPortSelector()
/var/www/html/RackTables/inc/functions.php:5285 call_user_func_array('linkmgmt_renderPopupPortSelector', Array
(
)
)
/var/www/html/plugins/Linkmgmt.php:1635 getOutputOf('linkmgmt_renderPopupPortSelector')
linkmgmt_opPortLinkDialog()
/var/www/html/RackTables/index.php:235 call_user_func('linkmgmt_opPortLinkDialog')

Error info:

Array
(
    [0] => HY000
    [1] => 1267
    [2] => Illegal mix of collations (utf8_bin,NONE) and (utf8_general_ci,COERCIBLE) for operation 'ifnull'
)

Parameters:
GET
module	redirect
page	object
tab	linkmgmt
object_id	1856
allports	1
op	PortLinkDialog
port	13614
linktype	front
POST
COOKIE
PHPSESSID	fa69geubgq1nodcvv30siveiq0
linkmgmt error.txt (3,839 bytes)   

Activities

adoom42

adoom42

2014-05-23 22:30

administrator   ~0002329

linkmgmt.php is a third-party plugin. You should contact the plugin developer. His e-mail address can be found in the source code.

https://github.com/RackTables/racktables-contribs/blob/master/linkmgmt.php
infrastation

infrastation

2014-06-06 21:37

administrator   ~0002347

For history: the following query should solve the problem (this change is already in the latest revision of linkmgmt.php):

ALTER TABLE `LinkBackend` CONVERT TO CHARACTER SET utf8 COLLATE utf8_unicode_ci;

Issue History

Date Modified Username Field Change
2014-05-23 20:59 cabbiebatman New Issue
2014-05-23 20:59 cabbiebatman File Added: linkmgmt error.txt
2014-05-23 22:30 adoom42 Note Added: 0002329
2014-05-23 22:30 adoom42 Resolution open => won't fix
2014-05-23 22:30 adoom42 Status new => closed
2014-06-06 21:37 infrastation Note Added: 0002347