BMS-HOSxP Community

HOSxP => MySQL => ข้อความที่เริ่มโดย: วีระวัฒน์ (เอก) ที่ มิถุนายน 30, 2007, 15:25:15 PM

หัวข้อ: upgrade structure MySQL ใน Linux ไม่ได้
เริ่มหัวข้อโดย: วีระวัฒน์ (เอก) ที่ มิถุนายน 30, 2007, 15:25:15 PM
ผม upgrade จาก 3.50.3.7 เป็น 3.50.3.30 หรือ สูงกว่าและล่าสุดจาก 3.50.3.7 เป็น V3.50.6.26 ไม่สามารถทำได้ถ้าใช้ MySQL ใน Linux ผมใช้ red hat enterprise 4  64 bit โดยมีข้อความใน
DebugWindowsMassage ว่า
Safe alter table start for table an_stat command  ADD `debt_id_list` varchar(50) NULL   
Install Trigger on an_stat
SQL Error: Access denied; you need the SUPER privilege for this operation
SQL Error: Access denied; you need the SUPER privilege for this operation
SQL Error: Access denied; you need the SUPER privilege for this operation
 
ผมใช้คำสั่ง ในเครื่อง server Linux ในการ grant  ตอนติดตั้ง V3.50.3.7
Mysql>create database hos;
Mysql>grant all on hos.* to sa@'%' identified by 'sa' with grant option;
 
ใช้ MySQL 5.0.37  for red hat enterprise 4  64 bit
แต่ upgrade จาก 3.50.3.7 เป็น 3.50.3.30...หรือ 3.50.3.7 เป็น 3.50.6.26 ทำใน MySQL for Windows ทำได้ไม่มีปัญหา
หัวข้อ: Re: upgrade structure MySQL ใน Linux ไม่ได้
เริ่มหัวข้อโดย: armds ที่ มิถุนายน 30, 2007, 16:37:28 PM
ลอง  เพิ่มคำสั่งนี้ไปดูครับ

Mysql>grant all on hos.* to sa@'%' identified by 'sa' with grant option;
Mysql>flush privileges;

น่าจะได้นะครับ
หัวข้อ: Re: upgrade structure MySQL ใน Linux ไม่ได้
เริ่มหัวข้อโดย: somnuk ที่ มิถุนายน 30, 2007, 21:04:37 PM
ใช้ Trigger ด้วยเหรอครับ ถ้าใช้ trigger ต้องมีสิทธิ์ super ด้วยนะครับ ลองใช้คำสั่งนี้เพิ่มเติมลงไปนะครับ

mysql> grant super on *.* to sa@'192.168.%' identified by 'sa' ;
mysql> flush privileges;
หัวข้อ: Re: upgrade structure MySQL ใน Linux ไม่ได้
เริ่มหัวข้อโดย: วีระวัฒน์ (เอก) ที่ กรกฎาคม 01, 2007, 05:22:23 AM
ทำตามคำแนะนำแล้วครับใช้ไม่ได้เช่นเดิม
SQL Error: Access denied; you need the SUPER privilege for this operation
SQL Error: Access denied; you need the SUPER privilege for this operation
SQL Error: Access denied; you need the SUPER privilege for this operation
หัวข้อ: Re: upgrade structure MySQL ใน Linux ไม่ได้
เริ่มหัวข้อโดย: somnuk ที่ กรกฎาคม 01, 2007, 11:20:04 AM
ดูจาก error ที่แสดง มันร้องว่า "จำเป็นต้องใช้สิทธิ์ SUPER" ก็แสดงว่า การอนุญาตสิทธิ์ SUPER ยังไม่เป็นผล

ลองตรวจสอบดูนะครับว่า
1. sa มีสิทธิ์ SUPER จริงหรือไม่ แล้วมีสิทธิ์ SUPER ได้กับ IP ไหนบ้าง ลองตรวจสอบการอนุญาตดู

mysql > show grants for sa@'192.168.%';

2. เครื่องลูกที่เชื่อมต่อไปยัง Server ใช้ IP ชุด 192.168.x.x หรือเปล่า ? ใน Connection setting ของ HOSxP ใช้ชื่อ User ว่า sa หรือเปล่า ? รหัสผ่านตรงกัน ?