Configure ONC RPC clnt_create Timeout


 
Thread Tools Search this Thread
Top Forums Programming Configure ONC RPC clnt_create Timeout
# 1  
Old 02-12-2010
Configure ONC RPC clnt_create Timeout

Do you guys know of a way to limit the amount of time will be spent attempting to create a ONC RPC client?

I am currently using the function clnt_create() to create my clients. However, if the remote RPC IP address is not reachable (on different network and unplugged) the GETPORT for portmapper can take 30+ seconds to timeout.

After searching online I found, what I thought was promising, functions like clnt_create_timed() which have a timeout value included but it doesn't appear to affect client creation, just sets the RPC communication timeout. I believe clntudp_create() works in a similar manner.

If you have any suggestions, I would love to hear them.

Thanks,

CoryC
# 2  
Old 02-14-2010
Which ONC are you using? TS-RPC or TI-RPC? If you are unsure, the following shows the differences between the two: http://www.fpmurphy.com/public_html/...Survey2001.pdf
# 3  
Old 02-14-2010
I am using TS_RPC.
# 4  
Old 02-15-2010
Unfortunately, then there is no way to set timeout on clnt_create(). The only thing I can suggest is to programatically ping the remote host prior to calling clnt_create(). However this check will not work if the remote host is configured to ignore ICMP ECHO requests.
# 5  
Old 02-16-2010
You cut me real deep just now, fpmurphy.

I will consider the ping approach.

I haven't heard of the TI version of RPC but might considering revising my approach. Would an issue arise if a client were TS and server TI (or vice versa)?

Thanks for your help! Smilie
# 6  
Old 02-16-2010
clnt_create_timed() ?
# 7  
Old 02-16-2010
Jim,

I attempted that without luck, although I may not have possessed the necessary libraries. I took the source code from a website and it worked the same as clnt_create. The website that contains the source is listed below. I suspect that the function may be of the TI variety.

clientlib: clnt_create_timed.c Source File
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. HP-UX

RPC Error

Hi All, I am receiving RPC-Error 5 and sometimes RPC-Error 2 in my Hp-Ux servers. I have tried to kill and restart again.. Again same errors. Sometimes RPC process going down. Due to this other applications are not working in Hp ux servers. Kindly share some ideas for root cause... Or... (2 Replies)
Discussion started by: jakmani
2 Replies

2. Solaris

nfs mount: RPC: Rpcbind failure - RPC: Timed out

Fails to mount the server (10.125.224.22) during installation of a software on client, throwing the below error: nfs mount: 10.125.224.22: : RPC: Rpcbind failure - RPC: Timed out nfs mount: retrying: /cdrom This happened after complete shutdown of the lab. The server came up fine but most... (1 Reply)
Discussion started by: frintocf
1 Replies

3. Solaris

RPC: Rpcbind failure - RPC: Timed out error (solaris)

C: Rpcbind failure - RPC: Timed out error (solaris) hello an nfs server on my sun fire v440 is not responding , i get the error bellow and lots of my networking services are not reponding, please helppppp its an emergency RPC: Rpcbind failure - RPC: Timed out i also get NFS server... (2 Replies)
Discussion started by: feg
2 Replies

4. Solaris

Error : "RPC: Rpcbind failure - RPC: Timed out"

Hello I am having an issue with a server SUN FIRE T2000 (Solaris 10). First of all the server didn't boot normaly so I did a full restoration of the file systems. Now the server boot, most of the services are available (not all the services), but I keep on seeing RPC: Rpcbind failure -... (4 Replies)
Discussion started by: feg
4 Replies

5. Solaris

Solaris: clnt_create fails on solaris x86

Hi, I am facing an issue with Solaris x86 machine Machine Details: uname -a SunOS sol10-64 5.10 Generic_137138-09 i86pc i386 i86pc .............................. Description: I am trying to register a programm with proramm ID 300760 with version number 1, and tryint to create a... (0 Replies)
Discussion started by: DivakarAdari
0 Replies

6. Solaris

RPC: Rpcbind failure - RPC: Timed out

while i trying to mount from NAS i have this messages mount -F nfs -o rw 172.16.110.13:/tremabkup /tremabkup nfs mount: 172.16.110.13: : RPC: Rpcbind failure - RPC: Timed out nfs mount: retrying: /tremabkup nfs mount: 172.16.110.13: : RPC: Rpcbind failure - RPC: Timed out nfs mount:... (2 Replies)
Discussion started by: thecobra151
2 Replies

7. Programming

C Shell RPC help

Hello everyone, I am writing a rpc program, I have put the server program on a directory in another computer and i run the client program from my computer. I want that when i call a function in the server program it will have to execute a shell script and the retruning of the shell script be... (6 Replies)
Discussion started by: ermalguni
6 Replies

8. Red Hat

RPC Timeout

I have a RHEL 2.1 machine that I am trying to get to mount a remote nfs filesystem. Both servers have 2 network interfaces. My linux machine can mount the filesystem through one interface with no problems but if I switch over and try to mount it through the other interface using a totally... (1 Reply)
Discussion started by: darren.wyatt
1 Replies

9. UNIX for Dummies Questions & Answers

RPC service

Hi All, How can I add RPC service in SCO 5.0.7. I did not find in the sco cd please help me Alice (0 Replies)
Discussion started by: alisevA3
0 Replies

10. Programming

Rpc

Hello, I would like to do a program (in C) on which I would have to call 3 or more executables using execl command. But if the executables are situated on another machine say Y and I do a programe on the machine X, is it possible to invoke those executables (binaries) from the other machine... (1 Reply)
Discussion started by: driki
1 Replies
Login or Register to Ask a Question