'netstat' info on Solaris


 
Thread Tools Search this Thread
Operating Systems Solaris 'netstat' info on Solaris
# 1  
Old 10-29-2009
MySQL 'netstat' info on Solaris

Hello All

I just wanted to know if on solaris ,below two commands need to be run separately unlike AIX where "/usr/bin/netstat -an -f inet " gives tcp as well as udp info.

Code:
/usr/bin/netstat -an -f inet -P tcp
/usr/bin/netstat -an -f inet -P udp

Also is there any way i can make these two commands effectively one and use it ? I do not wish to use 2 separate commands.

Regards
Abhi
# 2  
Old 10-29-2009
not according to the 'man' pages.
Why cannot you use 2 commands?
# 3  
Old 10-29-2009
MySQL

I am using these commands in a fingerprinting tool and this tool would work only on one command at a time.

My code works fine for AIX and Linux but for Solaris i am stuck due to two separate commands.

Regards
Abhi
# 4  
Old 10-29-2009
Then check for the OS (man uname) and implement accordingly.
# 5  
Old 10-29-2009
MySQL

We know "/usr/bin/netstat -an -f inet" gives all the data but it has diffrent formats of displaying reports for TCP and UDP.

Its certainly a tricky need.
# 6  
Old 10-29-2009
did you try install wireshark

and then filter TCP and UDP

CaptureFilters - The Wireshark Wiki
# 7  
Old 10-29-2009
Quote:
Originally Posted by ak835
Code:
/usr/bin/netstat -an -f inet -P tcp
/usr/bin/netstat -an -f inet -P udp

Also is there any way i can make these two commands effectively one and use it ? I do not wish to use 2 separate commands.
Just create a shell script that call both of them sequentially and run that single script.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

Solaris 10 Sparc. How to change Vendor info of SAN disks reported in "format" command?

Greetings! After block level migration using an external appliance, the luns are getting reported as DGC-RAID5 and these luns are infact from the new storage. I have a query on changing the device Vendor info from DGC-RAID5 to HP3par in the format o/p only. AVAILABLE DISK SELECTIONS: ... (3 Replies)
Discussion started by: n_Bhaskar
3 Replies

2. OS X (Apple)

netstat

When running netstat -i from the Command Terminal, It returns with 21 different connections.. The addresses all look like this: ::1 fe80:1::1 10:dd:b1:a5:c4:ba with Network names like Linke#2 fe80::8e2d How can I delve deeper into this to clarify what is going on with my network?... (0 Replies)
Discussion started by: dwfiedler
0 Replies

3. UNIX for Advanced & Expert Users

Amount of Network Traffic info from netstat output

Hi, I'm trying to figure out how much traffic has been generated and received from netstat -s output (using Linux). I can see the output shows packet counts and Octet values, how would I correctly calculate how much traffic in and how much out? My output below: Ip: 88847576 total... (1 Reply)
Discussion started by: wilsonee
1 Replies

4. Solaris

ufs slices info in solaris

how do you get start and end sector of a UFS slice? (2 Replies)
Discussion started by: orange47
2 Replies

5. Solaris

Solaris raw disks info

Hi, I need the following information. 1. We have raw disks but how to identify raw disks. Is there any command to identify its type and size. 2. How to differentiate between disks which are used as file system and that are still available to be used as raw. I know we can use df -n to... (7 Replies)
Discussion started by: malikshahid85
7 Replies

6. Solaris

solaris I/O devices info

Hi, can anyone help in finding the hardware related details of I/O devices of remote solaris machine .Thanks in advance. (7 Replies)
Discussion started by: pratheepv
7 Replies

7. Solaris

Info required zones in solaris

Can anyone explain me what is the use of zones in solaris. Also how to find whether it is a local or global zone. (1 Reply)
Discussion started by: rogerben
1 Replies

8. Solaris

Solaris patching info

SOLUTION: You'll want to download the Solaris patches from: http://sunsolve.sun.com/show.do?target=home - get yourself an account, and you'll want to at least download the 'Sun Alert Patch Cluster' for your OS, as well as the 'Recommended' patch archive, which usually has a generic title like... (2 Replies)
Discussion started by: b1f30
2 Replies

9. UNIX for Dummies Questions & Answers

Solaris netstat. Newbie.

Hi, I currently have two processes running on my Solaris server that are hogging the cpu. I am confident that these two processes are caused by remote users logged into the oracle database on the server. What I need to know is how to get the corresponding ip address associated with the... (2 Replies)
Discussion started by: gwhelan
2 Replies

10. UNIX for Dummies Questions & Answers

Info Needed in Seting up An apache Web Server on A Sun Sparc with Solaris 8

I need help in the form of the complete procedures necessary in setting up an Apache web server on a Sun Sparc running Solaris 8 David Johnston P.S New to the Unix arena (1 Reply)
Discussion started by: David Johnston
1 Replies
Login or Register to Ask a Question