11-20-2002
/etc/services is not used to configure ports.
/etc/services is not (generally) used to change ports. It is simply (most often) a mapping between port number and friendly names... so when you do 'netstat' for example, there will be a name for the port versus a number.
There are very few (if any) programs (that I know of) that open and read /etc/services to determine what port to bind to. To change a listening port it would be necessary to either have a configuration file entry (like HTTP/Apache httpd.conf) or a command line switch that tells the forked process to listen on a certain (bind and listen) port.
It is a (very common) misconception that changing an entry in /etc/services changes how a program binds to a port/socket. There is also the misconception that commenting out these entries blocks ports (wrong!). Commenting out the entries simply insures that the name will not come up when you do a netstat, etc.
10 More Discussions You Might Find Interesting
1. Cybersecurity
Hello every one.
I work in a LAN with many application server.
Each one use a different port.
What command permit to obtain the number of these port.
thanks (2 Replies)
Discussion started by: hoang
2 Replies
2. Red Hat
If I change my SNMP strings from the default PUBLIC to something else.
Does this take effect right away or do i have to restart snmpd or HUP it or...something...?
this is RHEL 3 AS (1 Reply)
Discussion started by: BG_JrAdmin
1 Replies
3. UNIX for Dummies Questions & Answers
Hi expert,
I wanted to know in which port my apache is running in solaris box
thanks
Shaan (1 Reply)
Discussion started by: shaan_dmp
1 Replies
4. UNIX for Dummies Questions & Answers
hi all
i want to connect a system,
how can i know the port number of a system. (2 Replies)
Discussion started by: tukuna82
2 Replies
5. Programming
Hi all,
I need to change the source port number of an outgoing TCP packet. First I have to bind the socket to a particular port(suppose 9001) but when I send the TCP packet I want to change the source port number lets say to 9002 still letting the socket to be bound to the same old port (9001).... (0 Replies)
Discussion started by: anuragrai134
0 Replies
6. Shell Programming and Scripting
I have a txt file as database. when i run my program what it does is it ask me for 3 name and stored in the file as
name1:name2:name3:1
when u enter 3 name it add those in file as above format and add 1 at the end. I what i want is if i enter same names again it changes that 1 to 2 and so... (3 Replies)
Discussion started by: Learnerabc
3 Replies
7. Cybersecurity
Is there a software solution to stop intruders from changing my port addresses?
Causes IPmap to crash.
Platform is OS/X Leopard. (1 Reply)
Discussion started by: aleatory
1 Replies
8. IP Networking
Hi ,
Currently DELL OMSA SNMP sends data through default udp port 161.I want my custom SNMP MIB also to send data in the same udp port 161.Whether its possible.If yes where to configure .I tried starting my custom MIB in udp port 161,but it throws port already in use.Kindly guide. (0 Replies)
Discussion started by: prabakar4all
0 Replies
9. Red Hat
Hi ,
Currently DELL OMSA SNMP sends data through default udp port 161.I want my custom SNMP MIB also to send data in the same udp port 161.Whether its possible.If yes where to configure .I tried starting my custom MIB in udp port 161,but it throws port already in use.Kindly guide. (1 Reply)
Discussion started by: prabakar4all
1 Replies
10. Solaris
please find the below o/p for your reference
bash-3.00# fcinfo hba-port
HBA Port WWN: 21000024ff295a34
OS Device Name: /dev/cfg/c2
Manufacturer: QLogic Corp.
Model: 375-3356-02
Firmware Version: 05.03.02
FCode/BIOS Version: BIOS: 2.02; fcode: 2.01;... (3 Replies)
Discussion started by: sb200
3 Replies
LEARN ABOUT MOJAVE
cups-snmp
cups-snmp(8) Apple Inc. cups-snmp(8)
NAME
snmp - cups snmp backend
SYNOPSIS
/usr/lib/cups/backend/snmp ip-address-or-hostname
/usr/libexec/cups/backend/snmp ip-address-or-hostname
lpinfo -v --include-schemes snmp
DESCRIPTION
The CUPS SNMP backend provides legacy discovery and identification of network printers using SNMPv1. When used for discovery through the
scheduler, the backend will list all printers that respond to a broadcast SNMPv1 query with the "public" community name. Additional
queries are then sent to printers that respond in order to determine the correct device URI, make and model, and other information needed
for printing.
In the first form, the SNMP backend is run directly by the user to look up the device URI and other information when you have an IP address
or hostname. This can be used for programs that need to configure print queues where the user has supplied an address but nothing else.
In the second form, the SNMP backend is run indirectly using the lpinfo(8) command. The output provides all printers detected via SNMP on
the configured broadcast addresses. Note: no broadcast addresses are configured by default.
ENVIRONMENT
The DebugLevel value can be overridden using the CUPS_DEBUG_LEVEL environment variable. The MaxRunTime value can be overridden using the
CUPS_MAX_RUN_TIME environment variable.
FILES
The SNMP backend reads the /etc/cups/snmp.conf configuration file, if present, to set the default broadcast address, community name, and
logging level.
CONFORMING TO
The CUPS SNMP backend uses the information from the Host, Printer, and Port Monitor MIBs along with some vendor private MIBs and intelli-
gent port probes to determine the correct device URI and make and model for each printer.
SEE ALSO
backend(7), cups-snmp.conf(5), cupsd(8), lpinfo(8), CUPS Online Help (http://localhost:631/help)
COPYRIGHT
Copyright (C) 2007-2017 by Apple Inc.
10 June 2014 CUPS cups-snmp(8)