Sponsored Content
Top Forums UNIX for Advanced & Expert Users What is the cause of file truncation? Post 85248 by venkatmyname on Tuesday 4th of October 2005 04:52:10 AM
Old 10-04-2005
Quote:
Originally Posted by jim mcnamara
Make sure you call fflush() after every write to your temp files.

This sounds like a program design issue more than a problem with the filesystem.
No. I think it cannot be. Because, it is working well on other environments. It's the problem only on my system/environment. Moreover, it has fflush() after every write.
 

10 More Discussions You Might Find Interesting

1. Solaris

solaris 2.5.1 /usr/ucb/ps truncation problems

we aheva couple of old sun OS boxes, that we are trying to parse /usr/ucb/ps output. However it seems that something is occuring that is causeing th output of "/usr/ucb/ps -auxwww" to cut short the process name, whereas "ps -eaf" can display the entire process name. It will work for a while... (2 Replies)
Discussion started by: adralph
2 Replies

2. UNIX for Advanced & Expert Users

truncation when vi a file

Hi, I'm using the vi that comes with Solaris 2.8. When vi a file with lines that have long continuous characters e.g. more than 256 chars, these lines got truncated. This is a known limitation of the out of the box Solaris vi, and there is a suggestion to get another vi. Is there an... (0 Replies)
Discussion started by: selur-xinu
0 Replies

3. AIX

PS output truncation in AIX

folks; i need help with a truncation problem in AIX when running "ps" command. when i run ps in SUN, i got the full output but when i run it in AIX the output is truncated. is there any arguments i can pass to give longer output so i can overcome the issue? here's the details:(please note the... (2 Replies)
Discussion started by: moe2266
2 Replies

4. UNIX for Advanced & Expert Users

STDOUT truncation

Operating system - Solaris 8, Korn shell, xterm Command /usr/proc/bin/ptree outputs the process tree exactly as I want with all detail However, /usr/proc/bin/ptree | more truncates the process descriptions at an 80 character point. If the process tree has marched enough to the right,... (3 Replies)
Discussion started by: JerryHone
3 Replies

5. UNIX for Advanced & Expert Users

Syslog Truncation / Size Limit?

I searched and could not find an answer to this, and am having difficulty, so I would appreciate any assistance that can be offered. We're experiencing logs that are having all characters after the 850th one written being truncated. I am wondering if there is a default limit to the syslog... (1 Reply)
Discussion started by: Puck
1 Replies

6. Post Here to Contact Site Administrators and Moderators

SCO 5.6 File truncation

Sir, my apologies for not being able to correspond for a long time. I am running an appliction in SCO 5.6. If the records are more than one lakh, the output file is getting truncated to one lakh. Please help me in rectifying the issue whereby it allows creation of output with more than one lakh... (0 Replies)
Discussion started by: chssastry
0 Replies

7. Filesystems, Disks and Memory

SCO 5.6 + file truncation

Sir, my apologies for I had put this question in a different forum earlier. I am running an appliction in SCO 5.6. If the records are more than one lakh, the output file is getting truncated to one lakh. Please help me in rectifying the issue whereby it allows creation of output with more than... (0 Replies)
Discussion started by: chssastry
0 Replies

8. UNIX for Advanced & Expert Users

Truncation Occurs When Outputting Shell Script to stderr

Operating System: Solaris 10, Shell We are outputting the results of our scripts to the stderr file. However we have encountered a problem where some of the lines in the file are truncated. Is there a way to increase the terminal or column size within the script so that this does not... (4 Replies)
Discussion started by: fazzasx
4 Replies

9. UNIX and Linux Applications

Space truncation

HI All- We have script like the followinga='h1 ' b='12434 ' c=' fagkasdbkZ<M' output=$a$b$c echo $output > /home/dsomasun/fil_concat.txtBut in the output file spaces are truncated and Output is coming like the belowh1 1234 fagkasdbkZ<M please advise Please wrap all code,... (4 Replies)
Discussion started by: dhilipans1988
4 Replies

10. Shell Programming and Scripting

Shell script (sh file) logic to compare contents of one file with another file and output to file

Shell script logic Hi I have 2 input files like with file 1 content as (file1) "BRGTEST-242" a.txt "BRGTEST-240" a.txt "BRGTEST-219" e.txt File 2 contents as fle(2) "BRGTEST-244" a.txt "BRGTEST-244" b.txt "BRGTEST-231" c.txt "BRGTEST-231" d.txt "BRGTEST-221" e.txt I want to get... (22 Replies)
Discussion started by: pottic
22 Replies
FFLUSH(3)						     Linux Programmer's Manual							 FFLUSH(3)

NAME
fflush - flush a stream SYNOPSIS
#include <stdio.h> int fflush(FILE *stream); DESCRIPTION
For output streams, fflush() forces a write of all user-space buffered data for the given output or update stream via the stream's underly- ing write function. For input streams, fflush() discards any buffered data that has been fetched from the underlying file, but has not been consumed by the application. The open status of the stream is unaffected. If the stream argument is NULL, fflush() flushes all open output streams. For a nonlocking counterpart, see unlocked_stdio(3). RETURN VALUE
Upon successful completion 0 is returned. Otherwise, EOF is returned and errno is set to indicate the error. ERRORS
EBADF Stream is not an open stream, or is not open for writing. The function fflush() may also fail and set errno for any of the errors specified for write(2). ATTRIBUTES
Multithreading (see pthreads(7)) The fflush() function is thread-safe. CONFORMING TO
C89, C99, POSIX.1-2001, POSIX.1-2008. The standards do not specify the behavior for input streams. Most other implementations behave the same as Linux. NOTES
Note that fflush() only flushes the user-space buffers provided by the C library. To ensure that the data is physically stored on disk the kernel buffers must be flushed too, for example, with sync(2) or fsync(2). SEE ALSO
fsync(2), sync(2), write(2), fclose(3), fopen(3), setbuf(3), unlocked_stdio(3) COLOPHON
This page is part of release 3.53 of the Linux man-pages project. A description of the project, and information about reporting bugs, can be found at http://www.kernel.org/doc/man-pages/. GNU
2013-07-15 FFLUSH(3)
All times are GMT -4. The time now is 08:38 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy