- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- disconnecting users from a TCP port
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 03:40 AM
01-31-2005 03:40 AM
disconnecting users from a TCP port
Eg: If I am unable to shutdown certain server service running on port 10000 and I have users connected on it, can I kill the user connection somehow?
Thanks in advance.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 03:47 AM
01-31-2005 03:47 AM
Re: disconnecting users from a TCP port
are You sure their connections still persist?
This should only happen if the server application didn't send them an RST or such.
the most reasonable step against this would be fixing the server or lowering tcp timeouts like CLOSE_WAIT using ndd.
(to answer Your question: it IS possible, but unsupported and I can only advise against doing it.
Ask hp for the documents on how to use ndd command to delete a TCP session out of the IP stack. repeat: they don't support it, if the server goes down, You're quite in trouble. We tested it two or three years ago, it worked and we decided not to use it on production systems.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 03:50 AM
01-31-2005 03:50 AM
Re: disconnecting users from a TCP port
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 04:06 AM
01-31-2005 04:06 AM
Re: disconnecting users from a TCP port
it is able to dynamically load and unload certain rule group, so You could have a 'logoff'-script that blocks user accesses from specific ip ranges.
don't forget to add a second one that removes the rules again.
I'd say go You could go with ndd if this is a one-time affair, otherwise ipfilter might be the better thing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 05:49 AM
01-31-2005 05:49 AM
Re: disconnecting users from a TCP port
Another option would be to use the lsof -i TCP:10000 command to determine the connections & kill those PIDs using them.
Probably want to grep -v LISTEN so as not to kill the listener if you want to leave it running and you script or one-line this.
My 2 cents,
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 05:57 AM
01-31-2005 05:57 AM
Re: disconnecting users from a TCP port
and unload of rules because IPFilter rules are
always matched top to bottom; so when you
unload and then load some rules, run "ipfstat -ioh"
to make sure that the rule order is what you intend it
to be.
Also, it might be a good idea to configure IPFilter
to send back a RST when you are loading rules
dynamically to block an existing connection.
Otherwise, the client will have no way of knowing
that the connection is blocked and will keep doing
retransmits for some time.
- Biswajit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 06:02 AM
01-31-2005 06:02 AM
Re: disconnecting users from a TCP port
script" and Jeff's "lsof followed by Kill" is a pretty
good solution to your problem. Ofcourse, as I
suggested, use return-RST in IPFilter block rules.
- Biswajit
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2005 06:09 AM
01-31-2005 06:09 AM