Subject: Re: Server Port?
From: "Daniel Adams" <[email-masked]>
To: [email-masked]
Date: Fri, 19 Jul 2002 11:37:36 -0700
Newsgroups: gmane.os.cygwin

Resolution is now found and I have a feeling it may apply to both my
original FTP and TELNET questions. I still have other issues with my FTP
server setup  so I am unable to test the idea. I have tested the idea and it
works successfully:

I tried changing the standard telnet entry in that file to an odd port
number. As a result not only did the server in question for telnet change to
a different port, but an undesired an unwanted problem occurred. When I
tried to telnet to a server that runs on port 23 which is standard, it gave
me a connection refused error, then I tried the telnet to that server with
port 23 specified and that did work.

The solution I thought of thanks to Jason's mentioning of that he added his
own (possibly made-up) services to the list that I had found in the services
file that I found in my WinNT directory. What I did was to add a
"telnetserv" service to the bottom of that file with the desired port and
the tcp protocol which is the same protocol as normal telnet. Then I went
into my "/etc/inetd.conf" file and changed the name of the service that is
for my telnet server to the made-up name of "telnetserv". I also made sure
to keep the original entry in the services file for telnet on port 23 so
that my normal telnet needs are issued into port 23 (standard) and if I want
to telnet to my own machine I have to use my IP number and the port.

All in all this whole description of a method to get this to work, worked
perfectly for me. I will probably write out a description of how to do this
configuration in my website. Also if anyone has questions, I will at least
try to help them understand what I did.

Thank you for the help on this issue,
Daniel Adams - [email-masked]
http://dana.ucc.nau.edu/~dpa3

1 Peter 4:10 (NIV)-  Each one should use whatever gift he has received to
serve others, faithfully administering God's grace in its various forms.

<[email-masked]> wrote in message
news:[email-masked]...
> The services file you found in C:\WINNT\system32\drivers\etc is indeed the
file
> you would want to edit--it affects both Cygwin and vanilla Windows
applications.
>
> My personal preference is to symlink /etc/services to the Windows one...
> (Hmm... who's for making this part of the install process?)
>
> To do that: ln -s /cygdrive/c/WINNT/system32/drivers/etc/services
/etc/services
> (Note that this works on Win NT/2K/XP only.  On ME???/95/98 the file is
> C:\WINDOWS\services... I think.  It might be in the system directory.)
>
> Changing standard port numbers is something that I have not tried.  If you
> change the port assignment for FTP, you may suddenly find that your better
> written Windows apps ("better written" implies "well abstracted" implies
"few
> hard-coded numbers") will no longer be able to find FTP servers without an
> explicit port specification.  I leave it to the reader to find out if IE
falls
> into that category.
>
> I add entries to my services file at the drop of a hat, though.
>
> I hope this helps.
>
> Jason Alonso
>
> Quoting Nicholas Wourms <[email-masked]>:
>
> >
> > --- Daniel Adams <[email-masked]> wrote:
> > > Will editing this file alter the port numbers for telnet or FTP used
by
> > > cygwin telnet and ftp clients, also some other windows clients? The
file
> > > that I found that could be edited was at
C:\WINNT\system32\drivers\etc.
> > > I am
> > > on a windows NT system. I figured that the method would involve this
> > > file
> > > since my Dad's redhat machine uses the same thing, but I also figured
> > > there
> > > would a file in my cygwin directory not the WINNT directory. Do you
have
> > > any
> > > knowledge about these questions?
> >
> > Why not experiment and see what happens?  I mean its not like it will
take
> > your machine down.
> >
> > Cheers,
> > Nicholas
> >
> > __________________________________________________
> > Do You Yahoo!?
> > Yahoo! Autos - Get free new car price quotes
> > http://autos.yahoo.com
> >
> > --
> > Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> > Bug reporting:         http://cygwin.com/bugs.html
> > Documentation:         http://cygwin.com/docs.html
> > FAQ:                   http://cygwin.com/faq/
> >
> >
>
>
>
>
> --
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
> Bug reporting:         http://cygwin.com/bugs.html
> Documentation:         http://cygwin.com/docs.html
> FAQ:                   http://cygwin.com/faq/
>
>

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/