Results 1 to 3 of 3

Thread: How to connect with MySQL in Ubuntu?

  1. #1
    Join Date
    Jul 2012
    Location
    Dhaka
    Beans
    271
    Distro
    Ubuntu 16.04 Xenial Xerus

    How to connect with MySQL in Ubuntu?

    Hi,

    I've installed XAMPP on my Ubuntu machine successfully. Everything is running fine. I can start all services by issuing the following command:

    Code:
    sudo /opt/lampp/lampp start
    All services starts successfully.

    Now I need to test MySQL from terminal, but when I'm giving the following command:

    Code:
    mysql -u root
    to set root password. Or

    Code:
    mysql -u root -p
    it's showing the following message:

    Code:
    The program 'mysql' is currently not installed. You can install it by typing:sudo apt-get install mysql-client-core-5.5
    I can't understand where the problem is. Please help me on this regard.

    Thanks in advance.

  2. #2
    Join Date
    Nov 2008
    Location
    S.H.I.E.L.D. 6-1-6
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: How to connect with MySQL in Ubuntu?

    try
    Code:
    /opt/lampp/bin/mysql -u root
    afaik, it is best to install mysql/php/apache from the Ubuntu repositories directly because security updates are provided automatically
    Don't waste your energy trying to change opinions ... Do your thing, and don't care if they like it.

  3. #3
    Join Date
    Jul 2012
    Location
    Dhaka
    Beans
    271
    Distro
    Ubuntu 16.04 Xenial Xerus

    Re: How to connect with MySQL in Ubuntu?

    Really thanks Sandyd. Your solution works perfectly for me. I can connect to MySQL now.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •