LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 02-15-2005, 07:41 AM   #1
sys7em
Member
 
Registered: Oct 2004
Location: Germany
Distribution: Slackware
Posts: 158

Rep: Reputation: 30
How to kill an inet (specific) connection ?


When I do netstat I get:

tcp 0 0 195.39.198.199:1647 weber.techno-link.:ircd ESTABLISHED
tcp 0 5 195.39.198.199:iad3 baym-cs370.msgr.ho:1863 ESTABLISHED
tcp 0 0 195.39.198.199:8000 host73.kuzelnet.:mloadd ESTABLISHED
tcp 0 0 192.168.0.1:3128 nfs.srv.net:3481 ESTABLISHED
tcp 0 0 192.168.0.1:netbios-ssn nfs.srv.net:3685 ESTABLISHED

and I want to kill the baym-cs370.msgr.ho connection ...howto do that ?

Thanks in advance..

Last edited by sys7em; 02-15-2005 at 07:46 AM.
 
Old 02-15-2005, 07:54 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405Reputation: 2405
Hi,

Use netstat -p to get the PID, kill the PID.

lsof -i,if installed, can also be used to get the PID (better layout, just my opinion)

Hope this helps.
 
Old 02-15-2005, 08:00 AM   #3
masand
LQ Guru
 
Registered: May 2003
Location: INDIA
Distribution: Ubuntu, Solaris,CentOS
Posts: 5,522

Rep: Reputation: 69
i ahve made a program for my project

have a look here
currently we are in the process of genralizing it to any server/cleint setup

have a look at
masand.sourceforge.net
i haven't uploaded the full code,if you would like to have that i can send u personlly


regards
 
Old 02-15-2005, 05:22 PM   #4
LordDark
LQ Newbie
 
Registered: Feb 2005
Location: Ecuador
Distribution: Red Hat, Fedora Core
Posts: 15

Rep: Reputation: 0
Sure, if you want more information... write netstat -pela and this describe all that your machine is in execute... select the process that you want and write
kill it (kill 32197 for example)
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Kill Connection pr4nk Linux - Networking 2 08-22-2005 04:42 AM
Kill connection keep process?? julious_dean Linux - Networking 2 08-01-2005 06:22 AM
Certain web sites kill my wireless connection ekolis Linux - Wireless Networking 2 07-04-2005 12:46 AM
How to kill a connection zWaR Linux - Networking 4 05-04-2004 09:28 PM
Kppp: script to kill Licq on closed connection? el_felipe Linux - General 5 12-14-2001 04:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration