nixCraft Linux Forum

nixCraft

Linux / UNIX Tech Support Forum

Small Issue : please help resolvinig it

This is a discussion on Small Issue : please help resolvinig it within the Shell scripting forums, part of the Development/Scripting category; Hi all In my linux machine, i made some script to take the backup of one table of database after ...


Go Back   nixCraft Linux Forum > Development/Scripting > Shell scripting

Linux answers from nixCraft.


Shell scripting You can discuss the shell scripting, request shell scripts and scripting techniques

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-10-2008, 03:33 AM
Junior Member
User
 
Join Date: Jul 2008
Location: New Delhi, India
OS: Redhat
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
ermunishanand is on a distinguished road
Default Small Issue : please help resolvinig it

Hi all
In my linux machine, i made some script to take the backup of one table of database after each hour as :
#!/bin/bash
/usr/mysql/local/bin/mysqldump -u root db --tables table1 > > /file.dmp

When i run this script manually it is working like
./abc.sh

But when i am putting it in cron it is not working as giving me error as no such file or directory. I also mention the path of this script in $PATH variable but still no results. I have faced such problem no. of times. please help me resolving this issue asap as i have to apply this on server. Thanks.
Reply With Quote
  #2 (permalink)  
Old 11-10-2008, 01:54 AM
rockdalinux's Avatar
Is that all you got?
User
 
Join Date: May 2005
Location: Planet Vegeta
OS: Redhat
Posts: 705
Thanks: 15
Thanked 19 Times in 18 Posts
Rep Power: 10
rockdalinux is a glorious beacon of light rockdalinux is a glorious beacon of light rockdalinux is a glorious beacon of light rockdalinux is a glorious beacon of light rockdalinux is a glorious beacon of light rockdalinux is a glorious beacon of light
Default

Should be as follows:
Code:
/usr/mysql/local/bin/mysqldump -u root -p 'Password' db --tables table1 >> /file.dmp
The -p will add password (if you have one) and there should be no gap between > and >
__________________
Rocky Jr.
What's wrong? I hope I am not making you uncomfortable...

Never send a boy to do a mans job.
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
squid configuration issue kathy79 CentOS / RHEL / Fedora 0 04-07-2008 05:06 PM
Issue During MRTG Installation???/ ajeetraina CentOS / RHEL / Fedora 0 02-06-2008 06:14 PM
Change /tmp path on KDE as it is too small for KDE marccarter0 Ubuntu / Debian 2 26-05-2008 09:34 PM
Small handy one liners digen Getting started tutorials 0 07-02-2007 03:40 PM
Log Off Issue tkinsella Linux software 1 30-08-2005 03:03 PM


All times are GMT +5.5. The time now is 09:18 AM.


Powered by vBulletin® Version 3.8.5 - Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2
©2005-2010 nixCraft. All rights reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38