Solved

Rebooted PC Sockets

Posted on 1997-05-23
4
222 Views
Last Modified: 2013-12-23
We have a SunOS 5.5.1 box running Oracle 7.2 that PCs connect to.  The users can submit ad-hoc queries.  When they enter a bad one, i.e. one that would finish well into the 21st century, they sometimes think the PC is hung and reboot and/or power off the PC.

This query then continues to run wasting even more resources since there would not even be a way for the results to be returned.  What parameters can be set using ndd so that the kernel would detect via the keep_alive packet process on the socket and clean it up?  Aside from the idle timer and keep alive stuff, are there any other options in TCP/IP?

The Oracle stuff that can be set up seems to just ping the IP address associated with the socket.  Unless you set this value to some very small period of time, it would only be luck that the PC was not back up and happily responding to the ICMP packets.
0
Comment
Question by:tgast
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 5

Expert Comment

by:julio011597
ID: 1582093
Hello,

i've never worked with Oracle, so don't know how effective could be setting a short interval for its ping call.

About TCP/IP in general, you usually should not play with kernel settings, since they affect any of your TCP/IP connections (even Netscape could start behaving strange).
Neither enabling KeepAlive would work, since the default timeout is about a couple of hours (unless, again, you change default kernel settings).

So it seems that you basically have two options:

1. see if setting up ping in Oracle would work;

2. if you have control on the client code, make a server program on the server box which works as a bridge between clients and Oracle server;
the server program should just pass incoming requests to the Oracle server, then send back answers to clients;
the advantage is that this program may send a few bytes to the client side, at specified intervals, and check for EPIPE or SIGPIPE in case the connection has been closed.
You need control on the client program to handle and skip these extra bytes.

If you would be happy with this, but don't know how to write the code, i could send you some sample on how to set up this 'custom_keep_alive' routine (C language).

Cheers, julio
0
 

Author Comment

by:tgast
ID: 1582094
I am not too much concerned with changing the kernel settings as they would just make socket cleanup of dead connections slightly more aggressive.  Going from the 2 hours or so I have seen as default on other UNIX variants to 15 minutes would help quite a bit.  I believe that with the relatively few number of socket connections to this system the additional overhead would be unnoticed.

I am really just looking for a good defintion of all the ndd paramters and exactly what they do.  Second to that, just a good definition and description of the ones to affect just this problem.

Also, the client software is embedded in PeopleSoft ...  Enough said?

Thanks for the input.  It is much appreciated.
0
 

Accepted Solution

by:
albertp earned 200 total points
ID: 1582095
Hi, if your server accepts requests via the inetd daemon, you
can determine connection's keep alive without modify the kernet
and without that ndd.

You can user tcp_wrappers, from Wietse Venema (ftp.win.tue.nl).
You can install this soft (is easy) and then you will  control
time-outs directly from hosts.allow and hosts.deny files,
individualy for any server (telnets too) without any complication.
By default, Linux has got it installed.

Rgds, albertp
0
 

Author Comment

by:tgast
ID: 1582096
That would indeed be a very nice way to isolate that socket number.  I will have to see if it is an option to put this into inetd.  It may not be as bringing up and down the Oracle server is maintained by a process scheduler and this very well may be unacceptable to operations.  It is probably possible to use the wrapper stuff outside of inetd though.
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Even if you have implemented a Mobile Device Management solution company wide, it is a good idea to make sure you are taking into account all of the major risks to your electronic protected health information (ePHI).
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question