Bash/Port/Forward: Difference between revisions
Jump to navigation
Jump to search
(Created page with "'''Check Port is not used''' <syntaxhighlight lang="bash"> # check port 22200 fuser 22200/tcp # check port 55500 fuser 55500/tcp </syntaxhighlight> '''Enable Specific Port''...") |
No edit summary |
||
Line 1: | Line 1: | ||
==Check Port is not used== | |||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
# check port 22200 | # check port 22200 | ||
Line 8: | Line 8: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
==Enable Specific Port== | |||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
firewall-cmd --zone=public --permanent --add-port=22200/tcp | firewall-cmd --zone=public --permanent --add-port=22200/tcp | ||
Line 16: | Line 16: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
==Enable Range of Port== | |||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
firewall-cmd --zone=public --permanent --add-port=22200-22290/tcp | firewall-cmd --zone=public --permanent --add-port=22200-22290/tcp |
Revision as of 23:03, 10 June 2018
Check Port is not used
# check port 22200
fuser 22200/tcp
# check port 55500
fuser 55500/tcp
Enable Specific Port
firewall-cmd --zone=public --permanent --add-port=22200/tcp
firewall-cmd --zone=public --permanent --add-port=55500/tcp
firewall-cmd --reload
netstat
Enable Range of Port
firewall-cmd --zone=public --permanent --add-port=22200-22290/tcp
firewall-cmd --zone=public --permanent --add-port=55500-55590/tcp
firewall-cmd --reload
netstat