Hi,

Does any one have a shell script to ftp a file to another location, so that I can 
schedule to run this file with cron.

Many thanks,
Hasan

----- Original Message -----
From: +ACI-Gerald R. Jensen+ACI- +ADw-gjensen+AEA-autodatasys.com+AD4-
To: +ACI-Impex Holidays Maldives / Hasan+ACI- +ADw-hasan+AEA-impex.com.mv+AD4AOw- 
+ADw-mysql+AEA-lists.mysql.com+AD4-
Sent: Sunday, February 24, 2002 10:56 PM
Subject: Re: backup


+AD4- We us a shell script that calls a cronjob (root) at 3am daily.
+AD4-
+AD4- The line in the cronjob is:
+AD4- +ACo- 3 +ACo- +ACo- +ACo- /usr/local/bin/dbbakup.sh username password
+AD4-
+AD4- The shell script:
+AD4-
+AD4- 
++ACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIw-
+AD4- +ACMAIQ-/bin/sh
+AD4- +ACM- +ACQ-1 +AD0- Unix/MySQL Username
+AD4- +ACM- +ACQ-2 +AD0- Unix/MySQL Password
+AD4-
+AD4- if +AFs- +ACE- -e /dbbakup +AF0-
+AD4-  then
+AD4-   mkdir /dbbakup
+AD4- fi
+AD4-
+AD4- mysqldump -u+ACQ-1 -p+ACQ-2 -c --add-drop-table --add-locks --flush-logs 
+--databases
+AD4- account+AD4-/dbbakup/account.sql
+AD4- mysqldump -u+ACQ-1 -p+ACQ-2 -c --add-drop-table --add-locks --flush-logs 
+--databases
+AD4- payroll+AD4-/dbbakup/payroll.sql
+AD4- mysqldump -u+ACQ-1 -p+ACQ-2 -c --add-drop-table --add-locks --flush-logs 
+--databases
+AD4- contact+AD4-/dbbakup/contact.sql
+AD4-
+AD4- 
++ACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIwAjACMAIw-
+AD4-
+AD4- If you wanted to ftp the resulting scripts to another server, you could add
+AD4- code to the shell script to run ncftpput, etc.
+AD4-
+AD4- Gerald Jensen
+AD4-
+AD4- ----- Original Message -----
+AD4- From: +ACI-Impex Holidays Maldives / Hasan+ACI- +ADw-hasan+AEA-impex.com.mv+AD4-
+AD4- To: +ADw-mysql+AEA-lists.mysql.com+AD4-
+AD4- Sent: Sunday, February 24, 2002 10:31 AM
+AD4- Subject: backup
+AD4-
+AD4-
+AD4- Hello everyone,
+AD4-
+AD4- I am trying to do backups using the crond daemon on my Linux server.
+AD4-
+AD4- Can I write a similar line as below on my crontab file. Any examples would
+AD4- be appreciated.
+AD4-
+AD4- mysqldump impex  +AD4- siteroot/home/hasan/backup/backup.sql
+AD4-
+AD4- Alternatively i am thinking of running a perl file ...which will find access
+AD4- to the database and then do the backing and add this
+AD4- file to the crontab.
+AD4- Has anyone got a file pre-written for this purpose.
+AD4-
+AD4- thank you so much.
+AD4- Hasan
+AD4-
+AD4-
+AD4-
+AD4- ---------------------------------------------------------------------
+AD4- Before posting, please check:
+AD4-    http://www.mysql.com/manual.php   (the manual)
+AD4-    http://lists.mysql.com/           (the list archive)
+AD4-
+AD4- To request this thread, e-mail +ADw-mysql-thread100889+AEA-lists.mysql.com+AD4-
+AD4- To unsubscribe, e-mail
+AD4- +ADw-mysql-unsubscribe-autodata+AD0-execpc.com+AEA-lists.mysql.com+AD4-
+AD4- Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
+AD4-
+AD4-
+AD4-
+AD4-
+AD4-
+AD4- ---------------------------------------------------------------------
+AD4- Before posting, please check:
+AD4-    http://www.mysql.com/manual.php   (the manual)
+AD4-    http://lists.mysql.com/           (the list archive)
+AD4-
+AD4- To request this thread, e-mail +ADw-mysql-thread100894+AEA-lists.mysql.com+AD4-
+AD4- To unsubscribe, e-mail 
++ADw-mysql-unsubscribe-hasan+AD0-impex.com.mv+AEA-lists.mysql.com+AD4-
+AD4- Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
+AD4-
+AD4-


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to