How to change the port number for any service? [on hold]

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP





.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;







up vote
-2
down vote

favorite












I know how to change the port number through the config file of sshd but I want to know how do you change any port number for any service without going into the sshd condfig file or for any service in any case. Thanks.







share|improve this question











put on hold as too broad by Jesse_b, user4556274, Jeff Schaller, slm♦ Aug 3 at 22:43


Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.














  • This is an overly broad question. There are neither magical formulas nor shortcuts.
    – Rui F Ribeiro
    Aug 3 at 21:37










  • I was going to recommend using an ssh tunnel but it seems like you're trying to change the ssh port itself?
    – Jesse_b
    Aug 3 at 21:45










  • @Jesse_b Have you read it? A general guide/magical formula to change any port in any existent service in Unix. ssh is just an example.
    – Rui F Ribeiro
    Aug 3 at 22:05

















up vote
-2
down vote

favorite












I know how to change the port number through the config file of sshd but I want to know how do you change any port number for any service without going into the sshd condfig file or for any service in any case. Thanks.







share|improve this question











put on hold as too broad by Jesse_b, user4556274, Jeff Schaller, slm♦ Aug 3 at 22:43


Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.














  • This is an overly broad question. There are neither magical formulas nor shortcuts.
    – Rui F Ribeiro
    Aug 3 at 21:37










  • I was going to recommend using an ssh tunnel but it seems like you're trying to change the ssh port itself?
    – Jesse_b
    Aug 3 at 21:45










  • @Jesse_b Have you read it? A general guide/magical formula to change any port in any existent service in Unix. ssh is just an example.
    – Rui F Ribeiro
    Aug 3 at 22:05













up vote
-2
down vote

favorite









up vote
-2
down vote

favorite











I know how to change the port number through the config file of sshd but I want to know how do you change any port number for any service without going into the sshd condfig file or for any service in any case. Thanks.







share|improve this question











I know how to change the port number through the config file of sshd but I want to know how do you change any port number for any service without going into the sshd condfig file or for any service in any case. Thanks.









share|improve this question










share|improve this question




share|improve this question









asked Aug 3 at 21:19









King

1




1




put on hold as too broad by Jesse_b, user4556274, Jeff Schaller, slm♦ Aug 3 at 22:43


Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.






put on hold as too broad by Jesse_b, user4556274, Jeff Schaller, slm♦ Aug 3 at 22:43


Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.













  • This is an overly broad question. There are neither magical formulas nor shortcuts.
    – Rui F Ribeiro
    Aug 3 at 21:37










  • I was going to recommend using an ssh tunnel but it seems like you're trying to change the ssh port itself?
    – Jesse_b
    Aug 3 at 21:45










  • @Jesse_b Have you read it? A general guide/magical formula to change any port in any existent service in Unix. ssh is just an example.
    – Rui F Ribeiro
    Aug 3 at 22:05

















  • This is an overly broad question. There are neither magical formulas nor shortcuts.
    – Rui F Ribeiro
    Aug 3 at 21:37










  • I was going to recommend using an ssh tunnel but it seems like you're trying to change the ssh port itself?
    – Jesse_b
    Aug 3 at 21:45










  • @Jesse_b Have you read it? A general guide/magical formula to change any port in any existent service in Unix. ssh is just an example.
    – Rui F Ribeiro
    Aug 3 at 22:05
















This is an overly broad question. There are neither magical formulas nor shortcuts.
– Rui F Ribeiro
Aug 3 at 21:37




This is an overly broad question. There are neither magical formulas nor shortcuts.
– Rui F Ribeiro
Aug 3 at 21:37












I was going to recommend using an ssh tunnel but it seems like you're trying to change the ssh port itself?
– Jesse_b
Aug 3 at 21:45




I was going to recommend using an ssh tunnel but it seems like you're trying to change the ssh port itself?
– Jesse_b
Aug 3 at 21:45












@Jesse_b Have you read it? A general guide/magical formula to change any port in any existent service in Unix. ssh is just an example.
– Rui F Ribeiro
Aug 3 at 22:05





@Jesse_b Have you read it? A general guide/magical formula to change any port in any existent service in Unix. ssh is just an example.
– Rui F Ribeiro
Aug 3 at 22:05











1 Answer
1






active

oldest

votes

















up vote
1
down vote













In short, you can't. A service will run on the port decreed in its configuration file or, if absent, generally a default.



This can be worked around with firewall shenanigans (e. g. listening for an incoming request on TCP/8080 and redirecting it to TCP/80), but that does not change the port the actual service itself is listening on.






share|improve this answer




























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    1
    down vote













    In short, you can't. A service will run on the port decreed in its configuration file or, if absent, generally a default.



    This can be worked around with firewall shenanigans (e. g. listening for an incoming request on TCP/8080 and redirecting it to TCP/80), but that does not change the port the actual service itself is listening on.






    share|improve this answer

























      up vote
      1
      down vote













      In short, you can't. A service will run on the port decreed in its configuration file or, if absent, generally a default.



      This can be worked around with firewall shenanigans (e. g. listening for an incoming request on TCP/8080 and redirecting it to TCP/80), but that does not change the port the actual service itself is listening on.






      share|improve this answer























        up vote
        1
        down vote










        up vote
        1
        down vote









        In short, you can't. A service will run on the port decreed in its configuration file or, if absent, generally a default.



        This can be worked around with firewall shenanigans (e. g. listening for an incoming request on TCP/8080 and redirecting it to TCP/80), but that does not change the port the actual service itself is listening on.






        share|improve this answer













        In short, you can't. A service will run on the port decreed in its configuration file or, if absent, generally a default.



        This can be worked around with firewall shenanigans (e. g. listening for an incoming request on TCP/8080 and redirecting it to TCP/80), but that does not change the port the actual service itself is listening on.







        share|improve this answer













        share|improve this answer



        share|improve this answer











        answered Aug 3 at 21:25









        DopeGhoti

        39.5k54679




        39.5k54679












            Popular posts from this blog

            How to check contact read email or not when send email to Individual?

            Bahrain

            Postfix configuration issue with fips on centos 7; mailgun relay