• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    backup of mysql database

    Scheduled Pinned Locked Moved
    FOG Problems
    2
    4
    522
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      robertkwild
      last edited by

      hi all,

      it says to run this command to backup the fog database

      mysqldump --allow-keywords -x -v fog > fogbackup.sql

      but looking elsewhere it says the way you backup databases is like so

      mysqldump -u [username] -p[password] [database_name] > [backup_file_name].sql

      so what do the options mean ie allow keywords and x and v

      thanks,
      rob

      Tom ElliottT 1 Reply Last reply Reply Quote 0
      • Tom ElliottT
        Tom Elliott @robertkwild
        last edited by

        @robertkwild https://linux.die.net/man/1/mysqldump

        --allow-keywords - Permit creation of column names that are keywords. This works by prefixing each column name with the table name. (So group/groups is a column name that is also known as a keyword)

        -x - Lock all tables across all databases. This is achieved by acquiring a global read lock for the duration of the whole dump. This option automatically turns off --single-transaction and --lock-tables. (So when you’re backing up the database data can’t accidentally be injected.

        -v - Verbose mode. Print more information about what the program does. (So when you’re runnning the backup you can see what’s going on.)

        The information that tells you this is just assuming basic information. If you need to enter username/password you can do:

        mysqldump -u[username] -p --allow-keywords -x -v fog > fogbackup.sql if you so choose.

        By not introducing the password it will prompt you for it rather than you putting it in while you run the command. (Keeping the password hidden from history commands)

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

        Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

        Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

        R 1 Reply Last reply Reply Quote 0
        • R
          robertkwild @Tom Elliott
          last edited by

          @tom-elliott thank you

          so really, i should run the command shown in the fog backup as its a better way

          Tom ElliottT 1 Reply Last reply Reply Quote 0
          • Tom ElliottT
            Tom Elliott @robertkwild
            last edited by

            @robertkwild “better” is a relative term. I suggest following the command because we know it will do what it needs to do properly.

            Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

            Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

            Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

            1 Reply Last reply Reply Quote 0
            • 1 / 1
            • First post
              Last post

            233

            Online

            12.0k

            Users

            17.3k

            Topics

            155.2k

            Posts
            Copyright © 2012-2024 FOG Project