แก้ไขรหัสผ่าน User [root] ใน MySQL กันเถอะ

ตามตำราและวิธีการที่พวกไอ้หรั่งมันเขียนกันไว้ ก็เยอะครับ
แต่วันนี้ผม ขอทำในแบบที่ผมคิดว่าง่ายแล้วกันครับ
เออ!! ลืมบอกว่าทำบนเครื่องที่ติดตั้ง MySQL Server น่ะครับ เอิ๊กๆ

เตรียมตัวกันหน่อย..
ใช้ command prompt [DOS] หรือ กดปุ่ม win+r จะขึ้นหน้าต่าง run แล้ว พิมพ์  "cmd" จะขึ้นหน้าต่าง DOS แล้วใจเย็นๆ รอไว้ แล้วลุยตามด้านล่างโลดดดด...

วิธีที่ 1 ใช้ tool ที่เขามีมาให้ครับ mysqladmin
   กรณีที่เป็น "Windows Server"

  1. กรณีที่ ยังไม่ได้เซ็ตรหัสผ่าน root หรือ user ไว้ก่อน พิมพ์  "mysqladmin -u root password รหัสผ่านที่ต้องการกำหนด" [enter]
  2. กรณีที่ มีรหัสผ่านเดิมอยู่แล้วต้องการเปลี่ยนรหัสผ่านใหม่ พิมพ์ "mysqladmin -u root -p'รหัสผ่านเก่า' password รหัสผ่านใหม่"
เป็นอันว่าเสร็จเรียบร้อย!! :p

วิธีที่ 2 ไม่ใช้ tool แต่ใช้ ความรู้ด้าน ภาษา SQL สักนิดนึง!!

  1. พิมพ์ "mysql" [enter] แล้วจะเข้าสู่ MySQL console อัติโนมัติ (ส่วนมาก รันบนเครื่องที่ให้บริการ mysql server เองจะไม่ค่อยได้ใส่รหัสผ่านหรอก )
  2. พิมพ์ "use mysql;" [enter] เลือกฐานข้อมูล MySQL ฐานข้อมูลนี้จะเก็บรายละเอียดเครื่องแม่ข่ายเอาไว้ทั้งหมด (เฉพาะ mySQL server น่ะ)
  3. ตรงนี้แหล่ะ สำคัญ เป็นการเปลี่ยนรหัสผ่าน ด้วยภาษา SQL ต้องระวังนิดนึง พิมพ์ "update user set password=password("รหัสผ่านใหม่") where user='root'; " [enter] หากต้องการเปลี่ยน user อื่น เพียงแก้จาก root เป็น user ที่เราต้องการเปลี่ยนรหัสผ่าน แค่นั้นเอง
  4. ยังไม่เสร็จสมบูรณ์ดีครับ ต้อง run อีกสัก command เพื่อให้ MySQL server Apply คำสั่งที่เราสั่งการไปสักครู่ โดยพิมพ์ "flush privileges;" [enter]
  5. สุดท้าย "quit;" เพื่อออกจาก console ครับ
วิธีที่ 3 ทำก่อนวิธีที่ 2 55+ [ งง อ่ะดิ ]

  1. กดปุ่ม win+r แล้วพิมพ์ " mysqld -u root --skip-grant-tables " [enter]
  2. กดปุ่ม win+r แล้วพิมพ์ "mysql " [enter]
  3. พิมพ์คำสัง ตามวิธีที่ 2 ตั้งแต่ ข้อ 2. จนครบทุกข้อ.

แค่นี้เป็นอันว่าเสร็จเรียบร้อยแล้ว ;p


Command list
use mysql;
update user set password=password("รหัสผ่านใหม่") where user='ชื่อผู้ใช้ที่ต้องการเปลี่ยนรหัสผ่าน';
flush privileges; 
quit; 
source: http://www.cyberciti.biz/faq/mysql-change-root-password/

แก้ปัญหา ข้อความ "BMC Responding" ค้างตอนเปิดเครื่อง HP Proliant ML150 G5


Question

When starting my server I receive this message

BMC Responding
510-BMC Sel is Full

Then I accessed the BIOS but I didn't found the way to clear the BMC log.

How can I clear the log?

Answer

1. Boot the server and press the F10 key when prompted to run BIOS Setup.
2. Select the "Advanced" menu.
3. Scroll down to "IPMI" and press the ENTER key
4. Scroll down to the System Event Log and press the ENTER key.
5. At the "Clear System Event Log" selection, press the ENTER key to toggle between "Enable" and "Disable."
6. Select "Enable."
7. Press the F10 key to Save the changes and exit the BIOS Setup