#1  
Old 4th September 2008, 11:37
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
Default Mysql question

Hi folks,


On typing following lines granting privilege;

mysql> GRANT SELECT ON mailserver.*
-> TO mailuser@localhost
-> IDENTIFIED BY 'password; [Enter]
Query OK, 0 rows affected (0.00 sec)


I discovered later miss-typing "mailuser" as "maluser". Please advise how can I rectify it. Or how to delete that privilege and then recreate another one.



Besides what command shall I run to show virtual users

mysql> show virtual_user

doesn't work.


TIA


B.R.
satimis

Last edited by satimis; 4th September 2008 at 11:40.
Reply With Quote
Sponsored Links
  #2  
Old 4th September 2008, 15:42
jon jon is offline
Member
 
Join Date: Jan 2007
Location: Canada
Posts: 87
Thanks: 12
Thanked 5 Times in 5 Posts
Send a message via Skype™ to jon
Default

You can use the DROP USER statement as described here ... http://dev.mysql.com/doc/refman/5.0/en/drop-user.html

Then just add the right user after.
Reply With Quote
  #3  
Old 4th September 2008, 17:02
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
Default

Quote:
Originally Posted by jon View Post
You can use the DROP USER statement as described here ... http://dev.mysql.com/doc/refman/5.0/en/drop-user.html

Then just add the right user after.
Hi jon,


Thanks for your advice and link.


Tried follows. Non of them works;
Code:
mysql> DROP USER maluser@localhost;
ERROR 1396 (HY000): Operation DROP USER failed for 'maluser'@'localhost'
mysql> DROP USER maluser;
ERROR 1396 (HY000): Operation DROP USER failed for 'maluser'@'%'
mysql> DROP USER 'maluser'@'localhost';
ERROR 1396 (HY000): Operation DROP USER failed for 'maluser'@'localhost'
mysql> DROP USER maluser;
ERROR 1396 (HY000): Operation DROP USER failed for 'maluser'@'%'
mysql> DROP USER maluser ;
ERROR 1396 (HY000): Operation DROP USER failed for 'maluser'@'%'
mysql> DROP USER 'maluser';
ERROR 1396 (HY000): Operation DROP USER failed for 'maluser'@'%'
mysql> DROP USER maluser@localhost ;
ERROR 1396 (HY000): Operation DROP USER failed for 'maluser'@'localhost'
mysql Ver 14.12 Distrib 5.0.51a,


satimis
Reply With Quote
  #4  
Old 5th September 2008, 12:11
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
Default

Try this:
Code:
use mysql;
update user set User = "mailuser" where User = "maluser";
flush privileges;
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 5th September 2008, 17:27
satimis satimis is offline
Senior Member
 
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
 
Default

Quote:
Originally Posted by falko View Post
Try this:
Code:
use mysql;
update user set User = "mailuser" where User = "maluser";
flush privileges;
Hi falko,


I got it. My problem fixed now. Thanks.


A side question;

If on typing;
Code:
mysql > line 1
      > line 2
      > line 3
      > line 4
      etc.
Suddenly I found there is a typing mistake on line 2. How can I jump back to line 2 making correction? Thanks.


B.R.
satimis
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Management/system config/settings & /server/settings not working!! dactor Installation/Configuration 9 6th February 2008 09:11
MYSQL; setting/updating the root password question... rh-penguin HOWTO-Related Questions 2 30th January 2007 18:47
Messed up ISPConfig-2.2.8 Upgrade Morons Installation/Configuration 4 29th November 2006 12:17
Quick question about Postfix + MySQL asterix HOWTO-Related Questions 5 12th September 2006 16:45
Mandriva 10.2 Perfect Setup Install Problems... ctroyp Installation/Configuration 12 30th December 2005 16:04


All times are GMT +2. The time now is 12:13.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.