The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Escape space in for loop Tuxidow Shell Programming and Scripting 3 3 Weeks Ago 09:08 AM
The command for Unassigned Space shahid khan UNIX for Dummies Questions & Answers 1 07-01-2009 04:41 AM
space in output from awk command lalelle Shell Programming and Scripting 7 08-14-2007 08:51 AM
SED command to change ./ to a space bobk544 Shell Programming and Scripting 11 04-05-2007 09:46 AM
Command to list used space in VG? Stephan UNIX for Dummies Questions & Answers 2 11-03-2005 03:34 PM

 
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1 (permalink)  
Old 3 Weeks Ago
shantanuo shantanuo is offline
Registered User
  
 

Join Date: Aug 2008
Location: Mumbai
Posts: 79
Question Escape Space in a ssh command

The following statement does work. But the second command does not work as expected.

Code:
ssh root@123.123.123.123 \\"mysqldump -h localhost -u root -pPassWord dbName -d | gzip -cf\\" | gunzip -c > database1.sql 


ssh root@123.123.123.123 \\"mysqlbinlog /var/log/mysql/mysql-bin.* --start-datetime=\\"`date -d"1 day ago" +'%Y-%m-%d 00:00:00'`\\" --stop-datetime=\\"`date +'%Y-%m-%d 00:00:00'`\\" > tos1.txt
Incorrect date and time argument: 2009-11-06

_____

update: The problem was solved by escaping the space in the date command.

Last edited by shantanuo; 3 Weeks Ago at 02:52 AM.. Reason: resolved
 

Bookmarks

Tags
ssh

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On




All times are GMT -4. The time now is 09:25 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0