Sponsored Content
Top Forums UNIX for Advanced & Expert Users How to Force a File Handle to Point to a New File? Post 302970867 by Don Cragun on Tuesday 12th of April 2016 07:12:53 PM
Old 04-12-2016
You can't force a running program to flush its internal buffers, close a file, and open a new file unless the code for that program was written with code to make that happen. Some system monitoring programs are designed to rotate log files when they receive a certain signal. The documentation for your system monitoring program should describe any such mechanism it provides. If your developer didn't provide such a mechanism and you need it to satisfy your users, file an enhancement request.
This User Gave Thanks to Don Cragun For This Post:
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

NFS file handle

How can I kill mount connection(NFS , made by automount) if remote filesystem is down? I tried: fuser -ku /auto /auto: umount /auto nfs umount: ERROR: /auto is busy If I try cd /auto - I get - /auto: Stale remote file handle. I know that reboot will help but I cannot reboot this... (2 Replies)
Discussion started by: kazimir
2 Replies

2. UNIX for Advanced & Expert Users

Stale NFS file handle

Hi, I get an error saying "Stale NFS file handle" how can I solve this? Is it possible to do this with a umount/ mount command? (5 Replies)
Discussion started by: rein
5 Replies

3. Programming

deleting a file name by its handle

All, I am having three function 1.open 2.process 3.close. Open will open a file and process will process a file and close will close the file .. I can able to close the file by its filehandler.Is there is anyway that i can get the file name by filehandle and remove it after... (5 Replies)
Discussion started by: arunkumar_mca
5 Replies

4. Shell Programming and Scripting

How to handle multiple rows in a file

I have a FILE a.txt which has the following data 113901.94,113901.94,56950.97,56950.97,NOT MATCHING,NOT MATCHING 10693.04,10693.04,5346.52,5346.52,NOT MATCHING,NOT MATCHING 1901.94,1901.94,550.97,550.97,NOT MATCHING,NOT MATCHING 103.04,103.04,53.52,53.52,NOT MATCHING,NOT MATCHING #### This... (2 Replies)
Discussion started by: ksmbabu
2 Replies

5. UNIX for Dummies Questions & Answers

How to change the file modification time of a file on nfs mount point

Hi I am accessing a file on nfs mounted device, after completing using of the file, i am tring to restore the access time and modification times of the file. So i got the previous modified time of the file using stat() function and trying to set the date and time for the file, To set these... (6 Replies)
Discussion started by: deepthi.s
6 Replies

6. Shell Programming and Scripting

handle file by month

Hi, I want to write a shell script which handle an oracle alert log so that when it changes month, the script generates a new file with month in the filename. Thanks in advance. Leim (4 Replies)
Discussion started by: leim
4 Replies

7. Solaris

Before I delete any file in Unix, How can I check no open file handle is pointing to that file?

I know how to check if any file has a unix process using a file by looking at 'lsof <fullpath/filename>' command. I think using lsof is very expensive. Also to make it accurate we need to inlcude fullpath of the file. Is there another command that can tell if a file has a truely active... (12 Replies)
Discussion started by: kchinnam
12 Replies

8. Shell Programming and Scripting

How to force csh to not use floating point?

Hi, I'm using csh, grep, and awk to sum up the third field from a file. Unfortunately, this results in a very large number and csh creates a floating point value such as 3.11745e+06. I was hoping to get 3117450. I get this error when I run this portion of the csh script and I suspect the... (5 Replies)
Discussion started by: daffy
5 Replies

9. Shell Programming and Scripting

Grepping from a point in a file to the end of the file

does any one know how to turn the equivalent of this command: awk '/2011 John Doe 8344/,0' /tmp/ops.log | egrep -c "received request" to something that would use egrep instead of awk? What the awk command does is, it searches the ops.log file for "2011 John Doe 8344". When it finds it,... (4 Replies)
Discussion started by: SkySmart
4 Replies

10. Red Hat

Force ssl/ssh to use the hosts file

does anyone know how to force ssh/ssl to use the hosts file instead of DNS? I have disabled the DNS servers but ssh still will not resolve a host in the hosts file. thanks in advance for the help! DS (3 Replies)
Discussion started by: derrell simpson
3 Replies
SYSTEMD-TIMEDATED.SERVICE(8)                                 systemd-timedated.service                                SYSTEMD-TIMEDATED.SERVICE(8)

NAME
systemd-timedated.service, systemd-timedated - Time and date bus mechanism SYNOPSIS
systemd-timedated.service /lib/systemd/systemd-timedated DESCRIPTION
systemd-timedated is a system service that may be used as a mechanism to change the system clock and timezone, as well as to enable/disable NTP time synchronization. systemd-timedated is automatically activated on request and terminates itself when it is unused. The tool timedatectl(1) is a command line client to this service. See the developer documentation[1] for information about the APIs systemd-timedated provides. SEE ALSO
systemd(1), timedatectl(1), localtime(5), hwclock(8) NOTES
1. developer documentation https://www.freedesktop.org/wiki/Software/systemd/timedated systemd 237 SYSTEMD-TIMEDATED.SERVICE(8)
All times are GMT -4. The time now is 11:49 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy