Netout: write returned 0?


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users Netout: write returned 0?
# 1  
Old 03-21-2013
Netout: write returned 0?

Hi Am Using unix Aix
When i ftp the zero size file getting the netout: write returned 0?

Quote:
My question was why its getting the alerts netout: write returned 0? ftp zero size file
what is netout means in unix ?

Can anybody tell me ?

Thanks in advance

# 2  
Old 03-21-2013
From man 2 write:

Code:
RETURN VALUE
       On  success,  the  number  of bytes written is returned (zero indicates
       nothing was written).  On error, -1  is  returned,  and  errno  is  set
       appropriately.

       If  count  is  zero  and  fd refers to a regular file, then write() may
       return a failure status if one of the errors below is detected.  If  no
       errors  are  detected,  0  will  be  returned without causing any other
       effect.  If count is zero and fd refers to a file other than a  regular
       file, the results are not specified.

So FTP is assuming the 0 is because of an error, but it's actually because the file is supposed to be empty -- it must have blindly done a write(fd, ... 0); instead of just not writing.

So it's not an error.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Emergency UNIX and Linux Support

How to ignore Netout Error.?

Hi All , Am using unix KSH . I would like to clarify two doubts. Whenever am transfering the zero size file am getting the warning message netout. files will be transferred to target server or not? I have used the code as if then VAR="ftp.sh -c put ${FILE} ${FILE}... (2 Replies)
Discussion started by: Venkatesh1
2 Replies

2. Shell Programming and Scripting

Sed - using value returned by W+

Hi, In a file old.txt containing (for example) a series.. #limerick There was a young lady from Nantucket.. \images\Blank.jpg :end #joke A horse walked into a bar... \images\Blank.jpg end I would like to achieve new.txt containing #limerick There was a young lady from Nantucket..... (5 Replies)
Discussion started by: Nigel_R
5 Replies

3. UNIX for Dummies Questions & Answers

What is returned when using 'find . -ls'

Hi all, I tried to find the reply using google, yet did not find a conclusive answer. When I use 'find . -ls', I get something like: 3423297 8 -rw-r--r-- 1 useradmin staff 135 4 apr 09:46 ./.~lock.dir-file-list.csv# I know that 3423297 is the inode -rw-r--r-- ... (2 Replies)
Discussion started by: dakke
2 Replies

4. IP Networking

read/write,write/write lock with smbclient fails

Hi, We have smb client running on two of the linux boxes and smb server on another linux system. During a backup operation which uses smb, read of a file was allowed while write to the same file was going on.Also simultaneous writes to the same file were allowed.Following are the settings in the... (1 Reply)
Discussion started by: swatidas11
1 Replies

5. Shell Programming and Scripting

netout: write returned 0?

Hi , When i try to ftp a zero byte file across through a shell script It gives me the mesaage netout: write returned 0? Is there any way i can supress this message as it does not affect the execution of the script Thanks (1 Reply)
Discussion started by: lifzgud
1 Replies

6. UNIX for Dummies Questions & Answers

Delete files returned by ls

I need to delete the files that are returned by this ls command: root@16:06:37@whci03:/var/log/whci# ls -ltrhS | grep "Apr " -rw-r--r-- 1 whci users 180M Apr 4 00:00 20090403_whci_Access.txt -rw-r--r-- 1 whci users 185M Apr 4 00:00 20090403_whci_Access.txt -rw-r--r-- 1 whci users 189M... (3 Replies)
Discussion started by: whci98
3 Replies

7. UNIX for Dummies Questions & Answers

Delete files returned by ls

I need to delete the files that are returned by this ls command: root@16:06:37@whci03:/var/log/whci# ls -ltrhS | grep "Apr " -rw-r--r-- 1 whci users 180M Apr 4 00:00 20090403_whci_Access.txt -rw-r--r-- 1 whci users 185M Apr 4 00:00 20090403_whci_Access.txt -rw-r--r-- 1 whci users 189M... (1 Reply)
Discussion started by: whci98
1 Replies

8. HP-UX

about the value returned from oracle

Hi all can i use unix variable holds the data returned by oracle in a shell script? x=sqlplus -s u/p@h <<! >>fg.log whenever sqlerr exit 1 select count(*) from schema.mat_view; exit ! echo $x Will the $x return the value of count(*)? thanks megh (1 Reply)
Discussion started by: megh
1 Replies

9. HP-UX

ridst returned

The rdist command script is called in the program to synchronize the updated files, I wonder whether the rdist returned can be fetched or not from the program? (0 Replies)
Discussion started by: Frank2004
0 Replies

10. Shell Programming and Scripting

-1 returned from fetchall_arrayraf

Hi all, below is my PERL script $ids = $dbh->prepare ("select * from tableA"); $ids->execute(); $names = $ids->fetchall_arrayref(); print " Total valid ids is $#names \n"; Table only has 1 column, approx 400 rows the value of $#names is -1. Would anyone point out what could have caused the... (1 Reply)
Discussion started by: new2ss
1 Replies
Login or Register to Ask a Question