Tuesday 14 May 2013

Reset Mysql root Password using my.ini


Follow the below given steps to reset the Mysql root password :

1.Browse to your MySQL installation directory.

2. In there, go to "Data" directory. 

3. Find and Open the file named "my.ini"

4. Please ensure that you take a backup of the file "my.ini" prior making any changes. Between the 1st line "[MySQLD]" and 2nd "PORT=" enter "skip-grant-tables"

5. Restart MySQL Service.

You should now be able to login to MySQL prompt without Password.

Once you are at MySQL Prompt,its time to reset the existing password.

Type in
"UPDATE mysql.user SET Password=PASSWORD('New_password') WHERE User='root';"

This will give something like "Query OK, 0 rows affected (0.04 sec)
Rows matched: 1 Changed: 0 Warnings: 0"

7. Type "FLUSH PRIVILEGES;" and hit enter.

You have just reset your MySQL root password.

Now,Do not Forget to undo the changes made in "my.ini" file.

8. Remove "skip-grant-tables" from "my.ini" and restart MySQL Service.

Now you are ready to use your MySQL Service with New Password.


Remove logs or Entries from the Remote Desktop Connection


I found that most people have no idea how to delete a cached entries from Remote Desktop Connection (RDC) on a Windows OS based computer. In fact, I had no clue how to do this. Even after you log out and select delete profile from the RDC, it will still show up in the Connections drop down next time someone open it. This is a problem because if a user with wrong intent to attack your computer or server open the RDC, it will provide them with half of the solution to hack your system, the IP or domain name!
 I have no idea why a great user friendly software company like Microsoft doesn't explain well on their help sites on registry editing for intermediate to advance users. May be because they don’t want novice users to pick up that information from their site and damage the OS in the process of regedit. Yes, it include the path and how to edit it, but there are no clear cut step by step instructions on how to properly do it.
The following method is the easiest way to delete an entry from Remote Desktop Connection:
-Open regedit: Type regedit on the general search (on the start menu) of the computers running Windows Vista and up. If you have a older OS, then open Run, and type regedit.exe.
-Find this parth: Go in to the Terminal Server Client using, HKEY_CURRENT_USER–>Software–>Microsoft–>Terminal Server Client–>Default
-Delete the entry: You will see all the entries with their respective IP address or domain names recorded on the system history. Pick the one you want to delete and hit delete on your keyboard OR right click and delete it.
Make sure you close the regedit.exe BEFORE you open the RDC because this change may not reflect on the client.
Now you will not see the entry in the RDC client when you open it the next time.