10-28-2010
Thanks abinaya.
Yes, you are correct this code is zipping files which are older than 7 days individual but i need to compress all files which are pertain to one day in to one file as their respective directories.
And we have different types of file names and some of them i given below.
john_0_20100905_000028.xml
sam01013735.xml
test_2010092417071107.XML
kindly let me know if you need any further information.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi,
I'm new to using the sftp command prompt within the unix shell (usually I just use an FTP windows program).
I've successfully connected to a remote server from within ssh. I've also been able to copy multiple files using the mget command
e.g. mget *.html
How do I copy all files,... (3 Replies)
Discussion started by: robbieg
3 Replies
2. Shell Programming and Scripting
Hi Friends,
Can anyone help me out with compressing multiple files.
I have multiple files in directory , I have to compress these into a single file,
I tried using
gzip -r outfile.gz file1 file2 file3.
It is not working
Thanks in advance for your help
S :) (5 Replies)
Discussion started by: sbasetty
5 Replies
3. UNIX for Dummies Questions & Answers
I want to compress all the files which are three years older ..I have thousands of files...
1) This doesnt work
find ./ -type f -mtime +1176 -print | xargs -n1 -i tar -cvf {}
Errror
tar: Missing filenames
Probably because of -
find ./ -type f -mtime -1 -print returns -
"
./temp.txt"... (6 Replies)
Discussion started by: kedar.mehta
6 Replies
4. Shell Programming and Scripting
I want to concatenate multiple files recursively from sub-directories intoone file in Linux.
I saved the following script as script.sh in $HOME/testing1 where I have several subdirectories and .txt files into them. I ran script.sh from the command prompt of $HOME/testing1 as ./script.sh. But it... (3 Replies)
Discussion started by: raj284
3 Replies
5. Shell Programming and Scripting
I want to concatenate multiple files recursively from sub-directories intoone file in Linux.
I saved the following script as script.sh in $HOME/testing1 where I have several subdirectories and .txt files into them. I ran script.sh from the command prompt of $HOME/testing1 as ./script.sh. But it... (3 Replies)
Discussion started by: raj284
3 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I want to untar all log files from following tarred directory hierarchy
Log_files.tar.gz/subject*.tar.gz/project*/*.log
It means there are subject1.tar.gz to subject9.tar.gz and in those tarred subect directories there are project1 - project5 directories and in those directories there... (2 Replies)
Discussion started by: rv_trojan
2 Replies
7. Shell Programming and Scripting
I'd like to create simple bash script that, given a directory, compresses each directory by name, e.g.:
Contents of ~/Documents
Folder1
Folder2
Folder3
compress-subdirectoies.sh ~/Documents
Results:
Folder1.
Folder2.
Folder2.
Any advice would be appreciated (7 Replies)
Discussion started by: furashgf
7 Replies
8. Shell Programming and Scripting
Hey guys. I know pratically 0 about Linux, so could anyone please give me instructions on how to accomplish this ?
The distro is RedHat 4.1.2 and i need to find and replace a multiple lines string in several php files across subdirectories.
So lets say im at root/dir1/dir2/ , when i execute... (12 Replies)
Discussion started by: spfc_dmt
12 Replies
9. Shell Programming and Scripting
I would like to compress the files in multiple directories. For some reason, it only compress the first directory (/Sanbox/logs1) but not the rest of the other directories ("/Sanbox/logs2" "/Sanbox/logs3" "/Sanbox/logs4" ). Any help would be appreciated. Here's my code:
#!/bin/bash... (1 Reply)
Discussion started by: Loc
1 Replies
10. UNIX for Beginners Questions & Answers
Good afternoon friends.
I wanted to make a query, how to compress several files and leave them all in 1, for example
flat text files:
filename_1.csv
filename_2.csv
filename_3.csv
expected result
filename_end.gzip = (filename_1.csv
filename_2.csv
filename_3.csv)
please (2 Replies)
Discussion started by: tricampeon81
2 Replies