sendto failing "resource temporarily unavailable"


 
Thread Tools Search this Thread
Operating Systems Solaris sendto failing "resource temporarily unavailable"
# 1  
Old 03-15-2007
sendto failing "resource temporarily unavailable"

Well, I am not even sure if its failing, cause at the other end I have a select call and it wakes up and reads the data I sent fine.

Ok here is the issue, I have a UDP socket(non blocking) through which I push some data to another port. At the other end I have select loop, waiting for this data.

But time and again, my sendto keeps failing saying "Resource Temporarily Unavailable". I am not sure if it fails, cause I see the data at the other end and it turned out fine!!!

I am dazed and confused. Any clue?
Btw, the sendto() code is inside a thread continuosly running while the select()/recfrom is in my main program.

Could anyone help?
# 2  
Old 03-15-2007
could anyone help please?!?
# 3  
Old 03-16-2007
Could anyone please help?

Let me put it in a different way. What do I do with an EAGAIN returned from UDP sendto socket?

Is it due to system load(I really doubt that, cause its just stray messages once in a few seconds)?

And to top it all, the message actually gets sent!!
# 4  
Old 03-16-2007
Please read our rules, bumping posts is NOT allowed. It is worth noting that it also makes it less likely that anyone will respond, not more likely.

How large are the buffers? Are the messages actually fully intact? Have you looked up what EAGAIN means and what the various causes are, if you have you will probably understand why I have asked the two previous questions.
# 5  
Old 03-16-2007
Sorry Reborg. The intention to bump was two fold.
To show my desperation and the other to rephrase my question.
Pardon a rookie.
Buffer is sufficiently big enough. the sokcet is non blocking. What would cause an operation blocking? Even if it turns out to be blocking, why did the operation succeed and the message sent out?
This will be my last attempt to bump the thread and solicit answers. Thanks in advance.
# 6  
Old 03-16-2007
I assume you mean it is returning -1 and setting errno to EAGAIN? not that it is retuning EAGAIN

The error in fact seems to indicate that your buffers are either not large enough, or that you are writing to them too quickly and the data cannot be cleared from them before you rewrite.

Last edited by reborg; 03-16-2007 at 06:35 PM..
# 7  
Old 03-16-2007
Yes Reborg.
By buffer do you mean the tempbuf that we pass to the sendto() or is it the memory buffers associated with the socket. For the latter one, how do I find whats assigned and how much is being used?
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Fork: Resource temporarily unavailable

Hi friends, Working on a linux X86-64 bit system, I suddenly started getting this error (mentioned in subject) from various scripts. I googled, found that there are couple of reason which causes this issue. - less memory I am pretty sure, memory seems to be stable on my system and at the... (15 Replies)
Discussion started by: clx
15 Replies

2. Programming

[ERROR:Resource temporarily unavailable!] Serial writing by termios library

Hello, I am using the termios library to write data that I get from a Bluetooth device to a modem via serial. The data arrive from the Bluetooth device correctly every 50ms and I have to bypass them on the serial ttyUSB3 where it is connected to a modem connected to a socket with static IP. The... (10 Replies)
Discussion started by: enaud
10 Replies

3. UNIX for Dummies Questions & Answers

Fork: Resource Temporarily Unavailable

I wrote a script that works most of the time but gave me fork: resource temporarily unavailable some of the time. I restarted my computer and now it runs fine but googling "fork: resource temporarily unavailable" and looking on the forums has not actually helped me figure out what exactly I... (3 Replies)
Discussion started by: monstrousturtle
3 Replies

4. UNIX for Advanced & Expert Users

fork: Resource temporarily unavailable , server unexpectedly unavailable network connection

Solaris 10 Server refuse to connect :wall: fork: Resource temporarily unavailable , server unexpectedly unavailable network connection , refuse error, disconnect message, fatal error type2, (protocol error type2) Issue has been resolved after taken few steps :b: First of all need to check... (1 Reply)
Discussion started by: taherahmed
1 Replies

5. UNIX for Dummies Questions & Answers

UNIX rm -rf error "rm: cannot remove `filename' : Device or resource busy"

Hi Everyone, I am trying to remove a directory: $ rm -rf directory_name/ rm: cannot remove `directory_name/filename': Device or resource busy What does this mean, and why can't I remove these files? I already tried moving into the directory, and removing the files individually, but I... (7 Replies)
Discussion started by: Anna_Z
7 Replies

6. Shell Programming and Scripting

awk command to replace ";" with "|" and ""|" at diferent places in line of file

Hi, I have line in input file as below: 3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL My expected output for line in the file must be : "1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL" Can someone... (7 Replies)
Discussion started by: shis100
7 Replies

7. Shell Programming and Scripting

grep - search after line containing "unavailable"

Hi everybody; I have a file status.txt: Following 163 ports are up: ----------------------------------------------------- MOD PORT PORTNAMES ABCDEFG1 ABCDEFG2 STA TYPE 1 Prt122 port323-1/2/3 11111 11111 1111 A 1 Prt126 port328-1/2/3 11111 11111 ... (7 Replies)
Discussion started by: gc_sw
7 Replies

8. Red Hat

cannot set user id: Resource temporarily unavailable (not open file/open process related)

First post, sorry to be a bother but this one has been dogging me. I have a process user (java application server) that trips a resource limit every couple weeks and need help finding what limit we're hitting. First, this is what's running: This is the error when jobs are run or the... (0 Replies)
Discussion started by: Katahdin
0 Replies

9. UNIX for Dummies Questions & Answers

Resource temporarily unavailable Error In Socket

Hi, Now I am programming to communicate with some network printer through TCP Socket program.By sending command "\033E 1\r" to printer,causes, check the port for error normally. In my case i used following code bytesSent = send( sockfd, "\033E 1\r",sizeof("\033E 1\r"), 0); ... (1 Reply)
Discussion started by: kavinsivakumar
1 Replies

10. Solaris

fork: Resource temporarily unavailable - What can I check ?

Hi everybody, I have an Unix box running Solaris and every day for 1 hour or 2 the box is stuck and I can only get this error message when trying to type a command : bash-3.00$ vmstat 5 bash: fork: Resource temporarily unavailable How can I trace what's is going wrong with this box ?... (5 Replies)
Discussion started by: unclefab
5 Replies
Login or Register to Ask a Question