Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Trouble managing ports from the command line Post 302840219 by csorhand on Monday 5th of August 2013 03:05:25 AM
Old 08-05-2013
syregnar86,


is this more on firewall(opening ports/closing ports) or more into UNIX sockets ports? Are your question related to ports like (ftp / ssh / sftp)

You have to make it clear.

Ports are open and closed by applications ( like ftp / ssh / http). If you close the applicaiton it will also close the port.


To view what ports is intended to what application is it located in /etc/services that file specify some of the known ports. some applications are not there but those who are common are indicated in the mentioned file.

To view any existing ports ( ESTABLISHED / LISTENING ports on your unix machine. you can use the unix command NETSTAT

ex:
netstat -an | grep ESTAB

hope that helps.
 

7 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

trouble using mailx command

Hi. I have been trying to send mail using the mailx command. I also tryed to use the mail command. The thing is that when I try to send the email, i receive automatically to my mailbox a DAEMON response sayng that the mailhost is unknown... The syntax I am using is this: $mailx -s "this... (2 Replies)
Discussion started by: ldrojasm
2 Replies

2. UNIX for Dummies Questions & Answers

command to view ports being used

Is there a command that will show me all ports being used? I thought maybe the "lsof" command would show me, but I'm not seeing anything. Thanks, Jeff (2 Replies)
Discussion started by: lawadm1
2 Replies

3. Shell Programming and Scripting

Command to set ports

Hi to everyone here, I have wrote a script to install and set up parental controls with dansguardian and tinyproxy,(fedora) it works quite well except that i have to manually set http proxy to 127.0.0.1 and port 8080 in firefox, is there a way to do this by command line/script? Id appeciate any... (2 Replies)
Discussion started by: dave123
2 Replies

4. Shell Programming and Scripting

sed multiple line trouble

Hello, im writing a script that validates a URL (the parameter) using http://validator.w3.org first it downloads the site (the output line I want is stored in the h2 field of the site's html. wget http://validator.w3.org/check?url=$1 2> /dev/null sed -n '/<h2/p' check?uri=$1 | sed 's/... (5 Replies)
Discussion started by: drareeg
5 Replies

5. Shell Programming and Scripting

Managing awk return code over SSH command

Hello all, This bellow code works. I'm just trying to find a simplified way to achieve this. I'm sure there is an easier way and it must be to simple for me to find. Verify that the OS version is 6.1. If not exit the script. Of course if i just put a && exit 1 at the end of the ssh... (11 Replies)
Discussion started by: maverick72
11 Replies

6. Homework & Coursework Questions

trouble understanding file option and command line arguments

Hi, I am creating a program with the C language that simulates the WC command in Unix. My program needs to count lines, bytes and words. I have not added the code to count bytes and words yet. I am having trouble understanding what the file option/flag '-' does. I can not visualize how it moves... (1 Reply)
Discussion started by: heywoodfloyd
1 Replies

7. Shell Programming and Scripting

Trouble with awk command

Hi, I need to read a string with ; separated using loop one filed by one field and perform some operation. Can you please check and let me know how to print command parameterised. key=phani;ravi;kiran number_of_keys=`echo $key|awk '{print NF}' FS=';'` for (( i = 1; i <= $number_of_keys;... (4 Replies)
Discussion started by: Ravindra Swan
4 Replies
UHSO(4) 						   BSD Kernel Interfaces Manual 						   UHSO(4)

NAME
uhso -- support for several HSxPA devices from Option N.V. SYNOPSIS
The module can be loaded at boot time by placing the following line in loader.conf(5): uhso_load="YES" DESCRIPTION
The uhso driver provides support for several HSxPA devices from Option N.V. that are based on their packet interface. Each device has a set of serial ports and a raw IP packet interface. The serial ports of the device are accessed through the ucom(4) driver which makes them behave like tty(4) devices. The packet interface is exposed as a network interface. Establishing a connection on the packet interface is achieved by using the proprietary AT commands ``AT_OWANCALL'' and ``AT_OWANDATA'' on any of the available serial ports. The network interface must be configured manually using the data obtain from these calls. Each device usually have at least two or more serial ports, their individual purpose can be identified through sysctl(8). Ports identified as ``Modem'' features a normal modem interface that can be used with PPP. Ports identified as ``Diagnostic'' uses a proprietary binary interface used for firmware upgrades, this port does not have a AT command interface and can not be used to control the device. Other ports features an AT command interface that can be used for normal device control. HARDWARE
The uhso driver should work with most devices from Option. The following devices have been verified to work o Option GlobeSurfer iCON 7.2 (new firmware) o Option GlobeTrotter Max 7.2 (new firmware) o Option iCON 225 o Option iCON 452 o Option iCON 505 The device features a mass storage device referred to as ``Zero-CD'' which contains drivers for Microsoft Windows; this is the default mode for the device. The uhso driver automatically switches the device from ``Zero-CD'' mode to modem mode. This behavior can be disabled by setting hw.usb.uhso.auto_switch to 0 using sysctl(8). FILES
/dev/cuaU?.? EXAMPLES
Establishing a packet interface connection using the AT command interface available at one of the serial ports AT+CGDCONT=1,,"apn.provider" AT_OWANCALL=1,1,1 OK _OWANCALL=1,1 AT_OWANDATA=1 _OWANDATA: 1, 10.11.12.13, 0.0.0.0, 10.2.3.4, 10.2.3.5, 0.0.0.0, 0.0.0.0, 72000 Configuring the interface ifconfig uhso0 10.11.12.13 up route add default -interface uhso0 echo "nameserver 10.2.3.4" > /etc/resolv.conf echo "nameserver 10.2.3.5" >> /etc/resolv.conf The connection can be terminated with AT_OWANCALL=1,0,1 SEE ALSO
uhsoctl(1), ucom(4), usb(4) AUTHORS
The uhso driver was written by Fredrik Lindberg <fli@shapeshifter.se>. BSD
July 20, 2010 BSD
All times are GMT -4. The time now is 05:47 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy