Linux C database backup version fifth

Source: Internet
Author: User

Linux under the C implementation of the database backup program finally ushered in the fifth edition, so the program is temporarily over, a little excited ...
In the next week (maybe two weeks), I will use a small online game (99 multiplication) as my graduation to learn Linux C ...
The next step is to choose the path of "Linux Network Big Data Development" or "Linux-based micro-system" ...
Welcome to Linux C enthusiasts private communication ...

In the release of the last version of the time said that in this version will be added to open automatic and automatic background operation, after the Netizen proposed and their own thinking after thought there is no need to do this two things ...

This version and the previous version of the functionality of the same did not add there is no reduction, mainly the work is to put the file for a more reasonable collation:
Log files and programs running PID files are moved into the log folder;
The database backup generation file is moved into the data folder;
The structure used in the program is put into include/struct.h;
The function used by the program is put into include/functions.h.

Some optimizations for structures and functions:
The number of databases backed up is not limited (the last version is 20 databases), this time using the linked list structure to save the database name information;
Database link information and backup time information unified into the conf data structure;
The last version is to parse out the database link information and backup time information after reading the file, this version is to read the file information after parsing.

The next step is to compile and run:
"Download to this website: http://www.oschina.net/code/snippet_728481_49947"
Compiling: Make
Cleanup temp file: Make clean
Run:./batapp
Running in the background:./batapp &
Restart:./batapp restart
Close:./batapp stop

Linux C database backup version fifth

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.