Sponsored Content
Full Discussion: compress Directory
Top Forums Shell Programming and Scripting compress Directory Post 302147540 by deep_kol on Tuesday 27th of November 2007 11:33:24 AM
Old 11-27-2007
Hi Vgersh99,
Thanks for your quick response.

I can make .zip fies like the following way

tar -cvf sales_mkt.zip M2_Sales.
But when I FTP it and try to unzip it in windows through winzip .It gives me error.


But the reverse way is possible .I can unzip the folder in windows.
Then ftp it (bin mode)into unix server .then I can unzip it like

$unzip filename.zip
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to compress a directory on a Sun Solaris 5.7 ?

Hi, Is there any utility to compress an entire directory on a Sun Solaris 5.7 ? Something like "compressdir" on other flavours of Unix ? Thanks (4 Replies)
Discussion started by: sameerdes
4 Replies

2. Shell Programming and Scripting

How to Compress files before moving them in a directory

I need a shell script that zips a file before moving them..please help (3 Replies)
Discussion started by: godalle
3 Replies

3. UNIX for Dummies Questions & Answers

Compress command

compress /var/opt/l2/amer/art2/USFINUM0200_.CSV compress /var/opt/l2/amer/art2/USFINUM200_.CSV compress /var/opt/l2/amer/art2/USFINUM020_.CSV compress /var/opt/l2/amer/art2/USFINUM20_.CSV Is there a way to shorten this or write it in a script. The file to be compressed will be USFINUM but... (5 Replies)
Discussion started by: indira
5 Replies

4. Shell Programming and Scripting

compress files

Could someone give me an idea how to compress all files from a given directory that are not of type .z (compressed). Please help. (2 Replies)
Discussion started by: lesstjm
2 Replies

5. Shell Programming and Scripting

Compress the contents of a directory while copying data into it

Hi guys I have a need to compress the contents of a directory while I am copying data into it. I was able to do this when it was only one file by doing as below: STEP1: mknod myfile p STEP2: chmod 777 myfile STEP3: compress -v < myfile > myfile.Z & STEP4: cp -p xyz_file myfile... (2 Replies)
Discussion started by: user1602
2 Replies

6. UNIX for Dummies Questions & Answers

Need help to compress

People i have files.arc i need to compress one by one...but they need to have the same date for example jan 30 1234.arc jan 30 12334.arc jan 30 rejrne.arc jan 30 e423e4.arc jan 30 afdhnfhd.arc jan 31 aresdfds.arc I need to compres the jan 30 .arc only thank you very much (1 Reply)
Discussion started by: enkei17
1 Replies

7. UNIX for Dummies Questions & Answers

Issue: Compress in unix server and FTP to windows and open the compress file using Winzip

Hi All ! We have to compress a big data file in unix server and transfer it to windows and uncompress it using winzip in windows. I have used the utility ZIP like the below. zip -e <newfilename> df2_test_extract.dat but when I compress files greater than 4 gb using zip utility, it... (4 Replies)
Discussion started by: sakthifire
4 Replies

8. Shell Programming and Scripting

Archive directory script with tar/compress

Hi all I need to write a script that archives all files with a certain date in the filename, to another location. It has to run on a AIX using tar/compress or another standard AIX tool. The directory will have x files, each prefixed with a date like yyyymmdd_desc.csv. I need all to... (7 Replies)
Discussion started by: AIXfrog
7 Replies

9. Shell Programming and Scripting

script to compress files in directory that changes its name every day

Hi all I have the following script that should compress a file in a directory: # compress log files older than 2 days find /u01/easydone/DBDUMPS/*.dmp -mtime +2 -exec gzip {} \; BUT the problem is that these files that I want to compress are inside a directory with following format: ... (5 Replies)
Discussion started by: fretagi
5 Replies

10. UNIX for Dummies Questions & Answers

How do I compress all files in a directory?

the problem states "Write a script that compresses all the files in the directory. Make a directory and put some files in it. Also make a sub directory in your directory and put files in it also. Once you have this basic ability to compress all files within a directory, add to your script a menu of... (1 Reply)
Discussion started by: Brittany
1 Replies
ftpconversions(4)						   File Formats 						 ftpconversions(4)

NAME
ftpconversions - FTP Server conversions database SYNOPSIS
/etc/ftpd/ftpconversions DESCRIPTION
When the FTP Server, in.ftpd(1M), receives the retrieve (RETR) command, if the specified file does not exist, it looks for a conversion to change an existing file or directory of the same base name into the format requested, subject to the ftpaccess(4) compress and tar capabil- ities. The conversions and their attributes known by in.ftpd(1M) are stored in an ASCII file of the following format. Each line in the file pro- vides a description for a single conversion. The fields in this file are separated by colons (:). %s:%s:%s:%s:%s:%s:%s:%s 1 2 3 4 5 6 7 8 The fields are described as follows: 1 Strip prefix. 2 Strip postfix. 3 Addon prefix. 4 Addon postfix. 5 External command. 6 Types. 7 Options. 8 Description. The Strip prefix and Addon prefix fields are not currently supported. The Strip postfix and addon postfix fields are extensions to be added to or removed from the requested filename in attempting to produce the name of an existing file or directory. When the attempt succeeds, the FTP Server runs the external command associated with the conver- sion. The magic cookie %s in the argument is passed to the command, replaced with the name of the existing file or directory. External command is the absolute pathname of a command to run followed by the appropriate options to carry out the conversion. The standard output of the command is sent back in response to the RETR (retrieve) command. For anonymous and guest users to be able to execute the com- mand, it must be present in their chroot'd hierarchy along with any necessary dynamic libraries. Types specifies the conversion type. The following values are recognized: T_ASCII ASCII transfers are allowed of a file produced by the conversion. T_DIR Directories can be converted. T_REG Regular files can be converted. Options are checked against the ftpaccess(4) compress and tar capabilities and are recorded in the special-action-flag field that is writ- ten to the FTP Server logfile. See xferlog(4). The following options are supported: O_COMPRESS conversion compresses O_TAR conversion archives O_UNCOMPRESS conversion uncompresses You can specify more than one option by using "|" to separate options. For example, O_TAR|O_COMPRESS specifies that the conversion archives and compresses. Description is a one word description of the conversion that is used in error messages returned to the FTP client. Lines that begin with a # sign are treated as comment lines and are ignored. EXAMPLES
Example 1: Compressing a Regular File for Transfer The following example specifies a conversion which generates filename.Z by compressing an existing file filename. The conversion can only be applied to regular files, not directories, and the absence of T_ASCII prevents the resulting file from being transferred in ASCII mode. : : :.Z:/usr/bin/compress -c %s:T_REG:O_COMPRESS:COMPRESS Example 2: Uncompressing and Transferring in ASCII Mode The following example specifies a conversion that takes filename.Z and uncompresses it to produce filename, which then can be transferred in ASCII mode. :.Z: : :/usr/bin/compress -cd %s:T_REG|T_ASCII:O_UNCOMPRESS:UNCOMPRESS FILES
/etc/ftpd/ftpconversions ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWftpr | +-----------------------------+-----------------------------+ SEE ALSO
ldd(1), in.ftpd(1M), ftpaccess(4), xferlog(4), attributes(5) SunOS 5.10 1 May 2003 ftpconversions(4)
All times are GMT -4. The time now is 06:13 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy