05-22-2008
advice on managing files between two systems
I am looking for some guidance to see if this is the most efficient solution.
I have a piece of software that updates a directory every night at 2am. The directory contains xml files so at 2am any new files are written, any modified files are modified and any deleted files are removed from the directory.
I need to send new and modified files to a different system. I also need to send a list of deleted files.
I had thought about using rsynch but the system I am feeding doesn't want to upload all files every day as it is a drain. That is why they want new/amended files only and a list of deleted files.
Here's my plan;
- directory on main server (let's call is 'a') is refreshed at 2.00am
- i can run rscnch on 'a' and a new folder 'b' at 4.00am
- between 2.00am and 4.00am folder 'a' and 'b' will be different.
- at 2.30am i can run a chron job on directory 'a' to send the new/amended files to the other system.
- at 3.00am i can run a script to cmpare the difference between 'a' and 'b' and output a list of files that are in 'b' but not 'a'. this can then be sent to the other system.
It seems a bit long winded but I am not aware of another way to do this. Does anyone have any suggestions for a better approach?
Thanks
10 More Discussions You Might Find Interesting
1. Filesystems, Disks and Memory
Hello,
When I am logged on a Unix machine, I would like get a maximum of informations related to the number of disks used, the space available, the description of the different files systems.
I'm using Unix OSF1 V4.0.
Thanks in advance for your help.
Geoffrey (2 Replies)
Discussion started by: geogeo
2 Replies
2. UNIX for Dummies Questions & Answers
Hi...
I have build a program for the Velleman K8000 interface card, in java, which works just fine in windows, but now I want to use the program on a Unix-System.
Is it possible to somehow convert the dll file to a format that Unix supports, or do I have to find another way?
Dll-file:... (3 Replies)
Discussion started by: Scorp-D
3 Replies
3. UNIX for Advanced & Expert Users
I am currently using Samba to access remote Unix file systems from Windows. However, it is slow, and I presume insecure in the sense that file contents are transmitted unencrypted. I also wonder if passwords are transmitted in plain text in this protocol or not. For these reasons I am looking for... (2 Replies)
Discussion started by: Bilge
2 Replies
4. HP-UX
Hi All
IN HPUX 11
How to delete an unwanted "core" file with a single command
which is being generated in different locations of the system
the command should be able to free up the space occupied by all "core" file
which is present in different folders and filesytems in a system
... (5 Replies)
Discussion started by: sidharthmellam
5 Replies
5. Solaris
Hi Gurus
I am facing a problem, there is a folder called /a where there are lots of files which are occupying space anything between 30 GB to 100 GB as I am not able to check the space occupied by that folder through "du -sh /a" command as I don't see any output after more than 1 hour of... (4 Replies)
Discussion started by: amity
4 Replies
6. UNIX for Dummies Questions & Answers
Hi
I have to move files between file systems but files in new file system must have the same attributes as in old one (privileges, time stamp etc).
Which tool is best :
- ufsdump / ufsrestore
- tar
- cpio
- pax
- dd
- mv
Or maybe there is sth else, you suggest to use.
Thx for help (5 Replies)
Discussion started by: presul
5 Replies
7. SCO
I have a SCO Unix server from 1999 running SCO 5.0.5 and some ancient accounting software called Real World
A report writer program on the system is used to generate CSV files from accounting that we write with DOSCOPY commands to 3.5" floppies
In the next 60 days we will be decommissioning... (11 Replies)
Discussion started by: magnetman
11 Replies
8. Red Hat
Hi All,
I have a CentOS operating system installed. I work with really huge number of files which are not only huge in number but some of them really huge in size. Minimum number of files could be 1 million to 2 million in one directory itself. Some of the files are even several Gigabytes in... (2 Replies)
Discussion started by: shoaibjameel123
2 Replies
9. Shell Programming and Scripting
so, every 5 minutes, i monitor some data files based on their line numbers.
so if i checked now and there are 100 lines in the file, i will scan the 100 lines for specific errors.
if i check again 5 minutes later and there are 150 lines in the file, i will monitor the file from line 100 to... (2 Replies)
Discussion started by: SkySmart
2 Replies
10. UNIX for Dummies Questions & Answers
Hi All,
Problem Statement:Find all log files under all file systems older than 2 days and zip them. Find all zip files older than 3days and remove them. Also this has to be set under cron.
I have a concerns here
find . -mtime +2 -iname "*.log" -exec gzip {}
Not sure if this will work as... (4 Replies)
Discussion started by: saurabh.mishra
4 Replies
LEARN ABOUT OPENSOLARIS
cachefspack
cachefspack(1M) System Administration Commands cachefspack(1M)
NAME
cachefspack - pack files and file systems in the cache
SYNOPSIS
cachefspack [-h] [-i | -p | -u] [-f packing-list]
[-U cache-directory] [file]...
DESCRIPTION
The cachefspack utility is used to set up and maintain files in the cache. This utility affords greater control over the cache, ensuring
that the specified files are in the cache whenever possible.
cachefspack does not pack files when the backfileystem type for the cachefs mount is NFSv4. This is because only pass-through support is
available for cachefs with NFSv4.
OPTIONS
The following options are supported:
-f packing-list Specify a file containing a list of files and directories to be packed. Options within subdirectories and files can
also be specified. The format and rules governing packing-list are described on the packingrules(4) manual page.
Directories are packed recursively. Symlinks that match a regular expression on a LIST command are followed. Symlinks
encountered while recursively processing directories are not followed.
-h Help. Print a brief summary of all the options.
-i View information about the packed files.
-p Pack the file or files specified by file. This is the default behavior.
-u Unpack the file or files specified by file.
-U cache-directory Unpack all files in the specified cache directory.
OPERANDS
The following operands are supported:
file A path name of a file to be packed or unpacked.
USAGE
See largefile(5) for the description of the behavior of cachefspack when encountering files greater than or equal to 2 Gbyte ( 2^31 bytes).
EXAMPLES
Example 1 Packing a File in the Cache
The following example packs the file projects in the cache:
% cachefspack -p projects
Example 2 Packint Files in the Cache
The following example packs the files projects, updates, and master_plan in the cache:
% cachefspack -p projects updates master_plan
Example 3 Unpacking a File From the Cache
The following example unpacks the file projects from the cache:
% cachefspack -u projects
Example 4 Unpacking Files From the Cache
The following example unpacks the files projects, updates, and master_plan from the cache:
% cachefspack -u projects updates master_plan
Example 5 Unpacking All Files From in a Cache Directory
The following example unpacks all files in the cache directory cache1:
% cachefspack -U /cache/cache1
Example 6 Using a Packing List
The following example illustrates the use of a packing list to specify files to be packed in the cache.
The contents of lists.pkg are as follows:
IGNORE SCCS BASE /src/junk LIST *.c LIST *.h
The following command packs all files in the /src/junk directory which have .c and .h extensions, and do contain the string SCCS in the
file's path name:
% cachefspack -f lists.pkg
EXIT STATUS
0 Successful completion.
>0 An error occurred.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsu |
+-----------------------------+-----------------------------+
SEE ALSO
cfsadmin(1M), mount_cachefs(1M), packingrules(4), attributes(5), largefile(5)
SunOS 5.11 18 Mar 2004 cachefspack(1M)