LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-26-2009, 11:11 AM   #1
krisrae675
LQ Newbie
 
Registered: Jul 2009
Posts: 10

Rep: Reputation: 0
rsync command problems


Hi using rsync within our bluetooth software to control and update a network. We have 14 client servers all building data and sending bluetooth messages and all connected to an enterprise master server on an internal network.
The client servers each have there own IP and need to send obex data reports to the enterprise which also has its own IP. The enterprise then sends data back to the clients like content updates and configuration settings.
Our software currently has the following configuration:

OBEX UPDATE (page)
Data Source rsync://192.168.1.60/ccobex-data/
Sync Options -f :_.rsync-filter --delete-after

RSYNC- FILTER
- /download/**/.lock*
- /download/**/.log*
+ /download
+ /download/**
+ /selfile
+ /selfile/**
+ .rsync-filter
: .rsync-filter
- *

RSYNC CONFIG
uid =nobody
gid =nobody
use chroot =yes
read only =yes
max verbosity =1
timeout =600
transfer logging =yes

[ccobex-data]
path = /var/opt/ccobex
comment = ccobex data files
filter = . /var/opt/ccobex/ .rsync-filter

The data in the ccobex folder contains
selfile,download,obexfilel.log,obexscan.log
At present only the download and selfile is changed but the obexfile.log and obexscan.log does not change.
We really need the file and scan logs to come over also
Can anyone offer any advice as we have been on this an eternity trying to solve

Last edited by krisrae675; 07-26-2009 at 11:59 AM. Reason: missed a bit
 
Old 07-27-2009, 09:17 AM   #2
Meson
Member
 
Registered: Oct 2007
Distribution: Arch x86_64
Posts: 606

Rep: Reputation: 67
Is this the config file for a wrapper you wrote to rsync? Is there any way you can post the actual rsync command that is run?
 
Old 07-27-2009, 01:54 PM   #3
micxz
Senior Member
 
Registered: Sep 2002
Location: CA
Distribution: openSuSE, Cent OS, Slackware
Posts: 1,131

Rep: Reputation: 75
is there possibly a filter excluding the logs in ccobex folder in .rsync-filter?
 
Old 07-28-2009, 04:08 AM   #4
krisrae675
LQ Newbie
 
Registered: Jul 2009
Posts: 10

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by micxz View Post
is there possibly a filter excluding the logs in ccobex folder in .rsync-filter?

There is a .rsync-filter in ccobex but that is the filter listed above
 
Old 07-28-2009, 04:09 AM   #5
krisrae675
LQ Newbie
 
Registered: Jul 2009
Posts: 10

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by micxz View Post
is there possibly a filter excluding the logs in ccobex folder in .rsync-filter?
There is a .rsync-filter in ccobex but that is the filter listed above
 
Old 07-28-2009, 04:13 AM   #6
krisrae675
LQ Newbie
 
Registered: Jul 2009
Posts: 10

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by Meson View Post
Is this the config file for a wrapper you wrote to rsync? Is there any way you can post the actual rsync command that is run?
Sorry not quite sure what you mean the rsync command is listed above is that the command you mean
 
Old 07-28-2009, 12:51 PM   #7
micxz
Senior Member
 
Registered: Sep 2002
Location: CA
Distribution: openSuSE, Cent OS, Slackware
Posts: 1,131

Rep: Reputation: 75
Code:
+ /download
+ /selfile
Seems like this is matching the download file and the selfile. But this part:
Code:
- *
Doesn't this match everything else. Excluding the logs you want.

Last edited by micxz; 07-28-2009 at 02:59 PM. Reason: spelling
 
Old 07-28-2009, 02:49 PM   #8
Meson
Member
 
Registered: Oct 2007
Distribution: Arch x86_64
Posts: 606

Rep: Reputation: 67
Quote:
Originally Posted by krisrae675 View Post
Sorry not quite sure what you mean the rsync command is listed above is that the command you mean
What I mean is that it looks like what you posted is just a configuration file. So my guess is that you have some program that parses the configuration file and turns it into a single rsync command. I was hoping you could post that command.
 
Old 07-28-2009, 03:11 PM   #9
micxz
Senior Member
 
Registered: Sep 2002
Location: CA
Distribution: openSuSE, Cent OS, Slackware
Posts: 1,131

Rep: Reputation: 75
Quote:
Originally Posted by Meson View Post
What I mean is that it looks like what you posted is just a configuration file. So my guess is that you have some program that parses the configuration file and turns it into a single rsync command. I was hoping you could post that command.
He posted the source and the options and the filter stated in the options. The exact command can be built from that something like:

rsync -f .rsync-filter --delete-after rsync://192.168.1.60/ccobex-data/ destination/
 
Old 07-28-2009, 07:58 PM   #10
Meson
Member
 
Registered: Oct 2007
Distribution: Arch x86_64
Posts: 606

Rep: Reputation: 67
Quote:
Originally Posted by micxz View Post
He posted the source and the options and the filter stated in the options. The exact command can be built from that something like:

rsync -f .rsync-filter --delete-after rsync://192.168.1.60/ccobex-data/ destination/
I don't like to make assumptions =)
 
Old 07-28-2009, 08:00 PM   #11
micxz
Senior Member
 
Registered: Sep 2002
Location: CA
Distribution: openSuSE, Cent OS, Slackware
Posts: 1,131

Rep: Reputation: 75
good point'
 
Old 07-29-2009, 09:24 AM   #12
krisrae675
LQ Newbie
 
Registered: Jul 2009
Posts: 10

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by micxz View Post
good point'
Hi Guys
I tried the command
rsync -f .rsync-filter --delete-after rsync://192.168.1.60/ccobex-data/ destination/
in data source but did not like the command and did not work.

Do you have any further ideas on this i could try please ask if you require me to send any further settings
thanks
chris
 
Old 07-29-2009, 07:20 PM   #13
micxz
Senior Member
 
Registered: Sep 2002
Location: CA
Distribution: openSuSE, Cent OS, Slackware
Posts: 1,131

Rep: Reputation: 75
Woops' you were right meson he is on a different page.

krisrae675:
I was guessing above at what command you were trying I was not suggesting you use the above command I should have explained myself better. Please post the command you where trying.
If you have ssh I would suggest you setup keys for logins and use the command:
Code:
rsync -ave ssh --delete user@192.168.1.60:/path/to/ccobex-data/ /path/to/destination/
(maybe skip to --delete flag until you know it's working. delete flag will remove files on the destination side that are missing from the src) This is done from the destination computer. If you are on the 192.168.1.60 machine you would use:
Code:
rsync -ave ssh --delete /path/to/ccobex-data/ user@192.168.1.xx:/path/to/destination/
Where xx is your IP or destination IP.

And of course add your filter with the -f flag.

Last edited by micxz; 07-29-2009 at 07:25 PM. Reason: adding note about filter I forgot he was using.
 
Old 07-30-2009, 02:33 AM   #14
krisrae675
LQ Newbie
 
Registered: Jul 2009
Posts: 10

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by micxz View Post
Woops' you were right meson he is on a different page.

krisrae675:
I was guessing above at what command you were trying I was not suggesting you use the above command I should have explained myself better. Please post the command you where trying.
If you have ssh I would suggest you setup keys for logins and use the command:
Code:
rsync -ave ssh --delete user@192.168.1.60:/path/to/ccobex-data/ /path/to/destination/
(maybe skip to --delete flag until you know it's working. delete flag will remove files on the destination side that are missing from the src) This is done from the destination computer. If you are on the 192.168.1.60 machine you would use:
Code:
rsync -ave ssh --delete /path/to/ccobex-data/ user@192.168.1.xx:/path/to/destination/
Where xx is your IP or destination IP.

And of course add your filter with the -f flag.
Hi Thanks for your reply again !
I did try the command you originally posted i did change the paths to the correct ones
Regarding the command I was using to run rsync it was
rsync://192.168.1.60/ccobex-data/
 
Old 07-30-2009, 08:16 AM   #15
micxz
Senior Member
 
Registered: Sep 2002
Location: CA
Distribution: openSuSE, Cent OS, Slackware
Posts: 1,131

Rep: Reputation: 75
And what was the result?
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Rsync problem: command not found j_70 Linux - Software 17 09-23-2016 01:28 PM
Find command and rsync combine b-RAM Linux - General 21 05-29-2009 02:37 AM
Rsync Command Skips Directories? carlosinfl Linux - General 1 12-10-2008 11:28 AM
Rsync Command Destroyed my Server = :( carlosinfl Linux - General 2 02-21-2008 10:27 AM
Exclude function On rsync command its_joy Linux - Server 5 01-18-2008 04:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:51 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration