Find Jobs
Hire Freelancers

Remote MySQL Database Backup and Encrypt

$10-30 USD

Completed
Posted over 4 years ago

$10-30 USD

Paid on delivery
1) Connect to remote mysql database using mysqli 2) Backup database 3) Transfer backup file and save as encrypted compressed file 4) Delete stored backup files older than 5 days Here is sample code that can be modified to work as decribed above. <?php $dbhost = '[login to view URL]'; $dbuser = 'my_user'; $dbpass = 'my_pwd'; $dbname = 'database_name'; $tables = '*'; backup_tables($dbhost, $dbuser, $dbpass, $dbname, $tables); function backup_tables($host, $user, $pass, $dbname, $tables = '*') { $link = mysqli_connect($host,$user,$pass, $dbname); // Check connection if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); exit; } mysqli_query($link, "SET NAMES 'utf8'"); //get all of the tables if($tables == '*') { $tables = array(); $result = mysqli_query($link, 'SHOW TABLES'); while($row = mysqli_fetch_row($result)) { $tables[] = $row[0]; } } else { $tables = is_array($tables) ? $tables : explode(',',$tables); } $return = ''; //cycle through foreach($tables as $table) { $result = mysqli_query($link, 'SELECT * FROM '.$table); $num_fields = mysqli_num_fields($result); $num_rows = mysqli_num_rows($result); $return.= 'DROP TABLE IF EXISTS '.$table.';'; $row2 = mysqli_fetch_row(mysqli_query($link, 'SHOW CREATE TABLE '.$table)); $return.= "\n\n".$row2[1].";\n\n"; $counter = 1; //Over tables for ($i = 0; $i < $num_fields; $i++) { //Over rows while($row = mysqli_fetch_row($result)) { if($counter == 1){ $return.= 'INSERT INTO '.$table.' VALUES('; } else{ $return.= '('; } //Over fields for($j=0; $j<$num_fields; $j++) { $row[$j] = addslashes($row[$j]); $row[$j] = str_replace("\n","\\n",$row[$j]); if (isset($row[$j])) { $return.= '"'.$row[$j].'"' ; } else { $return.= '""'; } if ($j<($num_fields-1)) { $return.= ','; } } if($num_rows == $counter){ $return.= ");\n"; } else{ $return.= "),\n"; } ++$counter; } } $return.="\n\n\n"; } //save file $fileName = 'db-backup-'.time().'-'.(md5(implode(',',$tables))).'.sql'; $handle = fopen($fileName,'w+'); fwrite($handle,$return); if(fclose($handle)){ echo "Done"; exit; } }
Project ID: 23592364

About the project

21 proposals
Remote project
Active 4 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
Hi, I represent Cidrec Technologies Pvt. Ltd. We are a closed group of dynamic and versatile young individuals of different skill sets to make a complete team. For this particular project I want to briefly describe about our Senior Software Engineer, Nikhil. “Nikhil is a Senior Software Engineer having 9.4 years of experience in multiple programming languages with cross domains. Possess excellent query writing and optimization skills. Team man, quick and self-learner, always open to gel with new languages. He has vast experience in development and support role with different working areas like telecom, e-commerce, retail. He is well versed in different programming methodologies like SQL Server, Oracle, PL/SQL, T-SQL, PHP, Angular JS, Shell Scripting, .Net, MVC. He is a keen learner of new technologies by his own and that's how he has worked with different programming languages in all his previous projects. Efficient at visualizing and mapping software solutions to mundane tasks, Nikhil is passionate about automation through technology. Working in start-up culture, he has proved his worth in taking challenging roles and delivering projects with 100% project goal within defined timeline.” Please try us once to know our potential.
$20 USD in 7 days
4.9 (20 reviews)
5.4
5.4
21 freelancers are bidding on average $45 USD for this job
User Avatar
I can make this database backup script in PHP. My average project completion time is within 3-5 hours on the same day. The skills I have include PHP, HTML5, CSS3, JavaScript, jQuery, WordPress Themes & Plugins, Web Scrapers & Automation Bots, User Scripts, Macros, and much more. If you have any questions or concerns. Feel free to message me via chat to clarify any details.
$30 USD in 1 day
5.0 (217 reviews)
6.9
6.9
User Avatar
Hello, This is quite easy to complete within 1 day. I am available to start working on it now...please do not hesitate to contct me, Regards.
$25 USD in 2 days
5.0 (45 reviews)
6.1
6.1
User Avatar
Hi greetings of the day I am a Experienced PHP Developer based out in Chennai,India. My experience revolves around development of web and mobile applications,Ecommerce websites. I believe that I am well qualified to undertake the task at hand and deliver a good solution. I would like to discuss this project and your exact requirements. I am confident that I can develop you based on your requirements. looking forward to hear from you soon so that we can get started on this one. Thanking you, All the very best, Cheers!!! Saurav
$50 USD in 1 day
4.9 (98 reviews)
5.8
5.8
User Avatar
Hi, I'd love to do Remote MySQL Database Backup and Encrypt for u on time as per your project details along with 100% satisfactory work. Website design and development work portfolio: https://www.freelancer.com/u/webdroid Skills and expertise: HTML5 , CSS3, JAVASCRIPT,Jquery ,Bootstrap,ajax,PHP ,Mysql ,Laravel ,Codignator,ecommerce ,UI UX, API integration, payment module integration,Web scrapping. Let's connect in chat
$50 USD in 2 days
4.8 (32 reviews)
5.8
5.8
User Avatar
Hi, I am a preferred freelancer and expert of PHP/MYSQL, I can provide you the solution for this. Let's get connect via CHAT and discuss the requirement. BR - Syed Usama
$50 USD in 2 days
5.0 (40 reviews)
5.4
5.4
User Avatar
Hi, nice to meet you. Can I suggest using a cron job for it? no matters if it on shared hosting, it can be configured. Also I'm available for this work
$25 USD in 1 day
5.0 (44 reviews)
5.3
5.3
User Avatar
We specialize in some of the most cutting-edge technologies in Web Development like PHP, Javascript, AJAX, Joomla, MySQL, HTML, HTML5, jQuery / Prototype & all other aspects of coding for the e-commerce market. We have worked with clients across the world from Asia to Africa & America to Europe. We will do hassle free coding and deployment for your project with keen focus on deadlines. Our in-house development team boasts a combined experience of more than 15yrs among them along with a dedicated marketing team as well. Experts in E commerce & other web Development technologies. we are offering: Web development / Web Design services for: Core PHP, MySql, Joomla, HTML, CSS, HTML5, Bootstrap, Jquery, Javascript, AJAX, Media Queries etc. 1) Web Services/Customization 2) Web Services/Social Netwoking (login, share, post ) 3) Website Design/Development 4) eCommerce Services/Customization
$20 USD in 7 days
4.9 (34 reviews)
5.5
5.5
User Avatar
Hey, Would love to discuss this in detail. We have been working since last 4 years and have a team of 21 people. We work on technologies like Java, Salesforce, Angular, Node, React, React Native, PHP, Laravel, AWS, Lua, Redis, MongoDB, HTML, CSS, UX/UI, etc. Thanks,
$70 USD in 2 days
5.0 (5 reviews)
4.0
4.0
User Avatar
Hello Greetings, my name is Asha I am Head of Client Relations and a web-developer myself. I would love to have an opportunity to discuss your project with you. With over 5 years of experience in mobile/web design and development we are certain we will not only execute this job but exceed your expectations. Our Development Standards & Practices:- We develop Retina Ready and responsive designs across all platforms (Mobile, Tablets & Desktop) + We make sure that we follow the latest coding standards. We do not want to bore you with a copy-paste proposal and because we believe in the saying "Actions speak louder than words", we will let our work do the talking, so feel free to look at our portfolio and if you like our projects, feel free to reach out to us.
$20 USD in 7 days
5.0 (5 reviews)
3.3
3.3
User Avatar
Hello, I can safely backup your MySql database via mysqli since I'm experienced with databases. Kindly initiate chat so we can discuss more.
$45 USD in 3 days
5.0 (6 reviews)
2.7
2.7
User Avatar
Hey There, You need Remote MySQL Database Backup and Encrypt I have 3+ years of expeirnece in web development. Let's have a chat. Looking forward to working with you.
$30 USD in 1 day
5.0 (2 reviews)
0.9
0.9
User Avatar
Dear team, Greetings, This is vanaja, I have gone through description. Having a good knowledge with mysql will fit for this job. I am very much familiar with db activities like taking backups.
$25 USD in 1 day
0.0 (0 reviews)
0.0
0.0
User Avatar
Hello,Sir I have read your project description several times carefully,I think, it is very reasonable project for me. I have no pending projects now, so I can do my best for you. I am looking forward to your project. Please expect perfect result from me. Thanks for spending your valuable time to review my bid.
$30 USD in 1 day
0.0 (0 reviews)
0.0
0.0
User Avatar
Hi I've experienced with native php script and cron job linux server. Hope we can work together, regards, diwan
$30 USD in 7 days
0.0 (0 reviews)
0.0
0.0
User Avatar
Dear Sir/Madam, I came across the project posted on Freelancer.com and I am perfect for this project for the following reasons: ✪ 100% Client Satisfaction on ALL Projects – see my portfolios. ✪ Glowing Client Reviews on ALL Projects. ✪ Native English Speaker. ✪ Advanced English Grammar and Punctuation. ✪ I produce HIGH-QUALITY, error-free content, in a clear, concise and engaging format. ✪ Published Author for paid-subscription magazines, blogs and journals (see portfolio). ✪ Master and bachelor’s degree in Information Technology. ✪ CISSP certified (certificate ID: 450848). ✪ 15 years working in IT for multi-national corporations. Thank you for considering my application. I look forward to speaking to you about how I can deliver your project successfully. Best Regards, Cecilia McGuire
$30 USD in 7 days
0.0 (0 reviews)
0.0
0.0

About the client

Flag of UNITED STATES
Englewood, United States
4.9
39
Payment method verified
Member since Jun 5, 2009

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.