Sponsored Content
Full Discussion: Gzip behavior on open files?
Top Forums Shell Programming and Scripting Gzip behavior on open files? Post 302800045 by jim mcnamara on Sunday 28th of April 2013 10:02:51 PM
Old 04-28-2013
FWIW - most "logging" processes that follow UNIX standards will close the current output file and then open another on receipt of a SIGHUP signal. Check your documentation.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

gzip, multiple files

Hello Everyone, Here is what I am trying to do. I have four text files, I want to gzip them under unix and mail the zipped file via outlook. I am able to do this easily enough, but using winzip or pkunzip to unzip the file, there is only one file. (In essence, all four files were... (2 Replies)
Discussion started by: smbodnar
2 Replies

2. UNIX for Dummies Questions & Answers

Need to gzip LARGE files

The windows version of gzip supports pretty much unlimited file sizes while the one we have in solaris only goes up to a set size, one or two gigs I think. Is there a new version of gzip I can put on our systems that supports massive file sizes? (2 Replies)
Discussion started by: LordJezo
2 Replies

3. UNIX for Dummies Questions & Answers

gzip all the files in a directory

Hi, There are multiple files in a directory with different names.How can they be gzipped such that the timestamp of the files is not changed. (2 Replies)
Discussion started by: er_ashu
2 Replies

4. Shell Programming and Scripting

unzip particular gzip files among the normal data files

Hello experts, I run Solaris 9. I have a below script which is used for gunzip the thousand files from a directory. ---- #!/usr/bin/sh cd /home/thousands/gzipfiles/ for i in `ls -1` do gunzip -c $i > /path/to/file/$i done ---- In my SAME directory there thousand of GZIP file and also... (4 Replies)
Discussion started by: thepurple
4 Replies

5. Shell Programming and Scripting

Gzip files as they are created

Hello. I have a scripting query that I am stumped on which I hope you can help with. Basically, I have a ksh script that calls a process to create n number of binary files. These files have a maximum size of 1Gb. The process can write n number of files at once (parallel operation) based on the... (4 Replies)
Discussion started by: eisenhorn
4 Replies

6. Shell Programming and Scripting

gzip the files with particular extension

Is there any way to compress only the files with .xml extension within a folder which in turn has many sub folders? gzip -r9 path/name/*.xml is not working This compression is done in the Windows server using Batch script. (2 Replies)
Discussion started by: Codesearcher
2 Replies

7. Shell Programming and Scripting

gzip files with extension

Hi, I have 1000 of files in a folder with the file extension as .csv In this some of the files are already zipped and its looks like filename.csv.gz Now i need to zip all the files in the folder to free some disk space. When i give gzip *.csv It prompts me to overwrite filename.csv.gz... (5 Replies)
Discussion started by: nokiak810
5 Replies

8. UNIX for Advanced & Expert Users

gzip vs pipe gzip: produce different file size

Hi All, I have a random test file: test.txt, size: 146 $ ll test.txt $ 146 test.txt Take 1: $ cat test.txt | gzip > test.txt.gz $ ll test.txt.gz $ 124 test.txt.gz Take 2: $ gzip test.txt $ ll test.txt.gz $ 133 test.txt.gz As you can see, gzipping a file and piping into gzip... (1 Reply)
Discussion started by: hanfresco
1 Replies

9. Shell Programming and Scripting

help with a script to gzip/move files

Hi Please can you help me in writing a script to find files on a specific directory, and of extension "tap" but only of the month of september, gzip and move them to another directory. Your help will be appreciated. (4 Replies)
Discussion started by: fretagi
4 Replies

10. Shell Programming and Scripting

tar and gzip files

Hi Guys, I am using RHEL5 and Solaris 9 & 10. I want to tar and gzip my files then remove them after a successful tar command... Lets say I have files with extension .arc then I want to tar and gzip these files. After successful tar command I want to remove all these files (i.e .arc). ... (3 Replies)
Discussion started by: Phuti
3 Replies
waitid(2)							System Calls Manual							 waitid(2)

NAME
waitid - Wait for child process to change state SYNOPSIS
#include <sys/wait.h> int waitid( idtype_t idtype, id_t id, siginfo_t *infop, int options ); STANDARDS
Interfaces documented on this reference page conform to industry standards as follows: waitid(): XPG4-UNIX Refer to the standards(5) reference page for more information about industry standards and associated tags. PARAMETERS
Identifies the type of process to be affected. Used with the id parameter, it suspends execution for the specified child process. Speci- fies either the process ID or process group ID of the child process. Used with the idtype parameter, it suspends execution for the speci- fied process. Specifies a pointer to a siginfo_t structure. Specifies the conditions that must occur before a wait operation is performed by the waitid() function. DESCRIPTION
The waitid() function holds a calling process until the state of a child process changes. The current state of the child is recorded in a structure pointed to by the infop parameter. If a child process changed state prior to the call to the waitid() function, the waitid() function returns immediately. The idtype and id parameters determine which child process the waitid() function is to act upon. If the idtype parameter is P_PID, the waitid() function waits for the child with a process ID equal to (pid_t)id. If the idtype parameter is P_PGID, the waitid() function waits for any child with a process group ID equal to (pid_t)id. If the idtype parameter is P_ALL, the waitid function waits for any child and the id parameter is ignored. The options parameter specifies the conditions that must occur before a wait operation is performed by the waitid() function. To specify a condition, use at least one of the following flags in a logical OR operation: Return the status for any child that was stopped and has been continued. Wait for processes to exit. Return immediately if no child processes in the requested state are present. Keep the child process whose status is returned in infop in a waitable state. Another wait for that child may occur with the same results. Wait for and return the process status of any child that has stopped upon receipt of a signal. [Tru64 UNIX] Wait for traced processes to become trapped or reach a breakpoint (see ptrace(2)). The infop parameter must point to a siginfo_t structure as defined in siginfo(5). This structure contains the status explaining why a process is in a wait state. The waitid() function returns if a child process is found that satisfies the conditions defined by the idtype and options parameters. In this case, the system fills in the structure pointed to by the infop parameter with the process status. The system always sets the si_signo structure member to SIGCHLD. RETURN VALUE
If the waitid() function returns because the state of a child process changes, it returns a value of zero (0). Otherwise, a value of -1 is returned and errno is set to indicate the error. ERRORS
The waitid() function sets errno to the specified values for the following conditions: The calling process has no unwaited-for child pro- cesses. [Tru64 UNIX] The infop parameter points to an invalid address. The waitid() function was interrupted due to the receipt of a signal by the calling process. An invalid value was used with the options parameter, or the idtype and id parameters specify an invalid set of processes. SEE ALSO
Functions: intro(2), exec(2), exit(2), fork(2), pause(3), ptrace(2), sigaction(2), signal(2), wait(2) Routines: pause(3) Files: siginfo(5) Standards: standards(5) waitid(2)
All times are GMT -4. The time now is 10:41 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy