Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Member
    Join Date
    Aug 2001
    Posts
    158

    Default how to copy all mysql users manually?

    If a drive is too full and I can't run backups, I want to copy the entire /var/lib/mysql directory but that doesn't copy db users and permissions.

    Where is the db user data located?

  2. #2
    Member
    Join Date
    Dec 2003
    Location
    France
    Posts
    300
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    db users and privileges are in the database "mysql".
    Marie - Co-Owner
    Need Further Assistance ? Here you go !
    English, french and spanish support

  3. #3
    cPanel Staff cPanelJared's Avatar
    Join Date
    Feb 2010
    Location
    Houston, TX
    Posts
    1,066

    Default Make a dump of the MySQL database

    As yapluka mentioned, these data are in the mysql database. The best way to preserve these data is to make a dump of the mysql database, which will create a file that contains all of the commands needed to create the database again. A very basic use of the mysqldump command would be the following:

    Code:
    # mysqldump mysql > /root/mysql.sql
    This will create a dump file in /root, mysql.sql, that contains all of the SQL statements needed to create the mysql database again. To import the database in the future, simply redirect the dump file into MySQL:

    Code:
    # mysql mysql < /root/mysql.sql
    If you need to move the MySQL data directory due to lack of disk space, there are several threads in our forums that describe how to do this. A couple of good suggestions are the following:

    http://forums.cpanel.net/f5/move-mys...ases-6655.html
    cPanel Forums - View Single Post - Move MySQL Databases
    http://forums.cpanel.net/f5/how-move...er-110481.html
    For hands-on assistance, please reference our new support information page: Where should I go for support?
    cPResources: Support Options - Submit a ticket here - Additional Support Options - Forums Search - Mailing Lists(Alt) - Documentation


    -- Jared Ryan, Technical Analyst, cPanel Technical Support

Similar Threads & Tags
Similar threads

  1. Manually upgrading MySQL 5.0
    By testlog_4u in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 09-08-2009, 12:47 PM
  2. how to allow users to update awstats manually ?
    By doridori in forum New User Questions
    Replies: 1
    Last Post: 12-23-2008, 04:09 AM
  3. Allow users to manually update stats programs
    By 4hosted in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 04-08-2008, 12:16 PM
  4. Copy Domain log files manually
    By nsusa in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 07-19-2007, 02:52 PM
  5. Manually Adding Users & Groups
    By brendanrtg in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 12-07-2006, 04:45 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube