サービスのポート番号を確認する


無料Linux入門マニュアル無料ダウンロード

今だけ2,200円のLinux入門PDFマニュアルが【数量限定】で無料ダウンロードできます。
Linux入門マニュアル無料ダウンロードはこちらをクリック

Linuxで稼働するサービスは、デフォルトでサービス固有のポート番号が使用されます。
例えば、httpならTCPポートの80番、httpsなら443番などです。

これらのポート番号を把握するには、サービス独自の設定ファイルを確認しなければなりませんが、
一般的に想定されているポート番号は、/etc/servicesファイルに記載されています。

/etc/servicesファイルには、各行ごとにサービス名とポート番号/プロトコル名が記載されています。
[root@Tiger ~]# view /etc/services
# /etc/services:
# $Id: services,v 1.48 2009/11/11 14:32:31 ovasik Exp $
#
# Network services, Internet style
# IANA services version: last updated 2009-11-10
#
# Note that it is presently the policy of IANA to assign a single well-known
# port number for both TCP and UDP; hence, most entries here have two entries
# even if the protocol doesn't support UDP operations.
# Updated from RFC 1700, ``Assigned Numbers'' (October 1994). Not all ports
# are included, only the more common ones.
#
# The latest IANA port assignments can be gotten from
# http://www.iana.org/assignments/port-numbers
# The Well Known Ports are those from 0 through 1023.
# The Registered Ports are those from 1024 through 49151
# The Dynamic and/or Private Ports are those from 49152 through 65535
#
# Each line describes one service, and is of the form:
#
# service-name port/protocol [aliases ...] [# comment]

tcpmux 1/tcp # TCP port service multiplexer
tcpmux 1/udp # TCP port service multiplexer
rje 5/tcp # Remote Job Entry
rje 5/udp # Remote Job Entry
echo 7/tcp
echo 7/udp
discard 9/tcp sink null
discard 9/udp sink null

〜中略〜

ssh 22/tcp # The Secure Shell (SSH) Protocol
ssh 22/udp # The Secure Shell (SSH) Protocol
telnet 23/tcp
telnet 23/udp
# 24 - private mail system
lmtp 24/tcp # LMTP Mail Delivery
lmtp 24/udp # LMTP Mail Delivery
smtp 25/tcp mail
smtp 25/udp mail

〜中略〜

http 80/tcp www www-http # WorldWideWeb HTTP
http 80/udp www www-http # HyperText Transfer Protocol
http 80/sctp # HyperText Transfer Protocol
kerberos 88/tcp kerberos5 krb5 # Kerberos v5
kerberos 88/udp kerberos5 krb5 # Kerberos v5
supdup 95/tcp
supdup 95/udp
hostname 101/tcp hostnames # usually from sri-nic
hostname 101/udp hostnames # usually from sri-nic
iso-tsap 102/tcp tsap # part of ISODE.
csnet-ns 105/tcp cso # also used by CSO name server
csnet-ns 105/udp cso

以下省略

※但し、各種サービスの設定ファイルでポート番号を任意に変更できるため、
 ここに記載されているポートで実際にサービスが動いているとは限りません。
 そのため注意が必要です。



無料Linux入門マニュアル無料ダウンロード

今だけ2,200円のLinux入門PDFマニュアルが【数量限定】で無料ダウンロードできます。
Linux入門マニュアル無料ダウンロードはこちらをクリック


<<関連記事>>
・MIMEでエンコードされたテキストを読めるように変換する
・viエディタで文字をコピーする
・ハードディスクの使用状況を調べるには
・tar.bz2ファイルを解凍して展開するには
・tar.gz形式のファイルを解凍、展開するには

Linux入門マニュアル無料ダウンロード