Re: [SOLVED] Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-14 Thread Carlo Florendo
Brian Dessent wrote:
Carlo Florendo wrote:
 

On a curious note, why do the inetutils  apps like ftp, telnet, etc.
still use getservbyname() and the other getserv  functions when, as you
said,
these apps could just have the port and protocol hardcoded or specified
in a config file?
   

As far as I know that traces back to the original TCP/IP networking code
in unix, 4.2BSD circa 1983 from what a quick google shows.  Back then
things were a lot simpler and I suppose it was more straightforward to
have one config file that defined all the services the box was running
and what ports they were to listen on, and to have each daemon query
that file through getservbyname().  As far as I know the tools in
inetutils are the direct descendents of the original BSD commands from
way back, so the code still uses those methods.
 

Great info. 

Thank you very much.
Best Regards,
Carlo
--
Carlo Florendo
Astra Philippipnes Inc,
www.astra.ph
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: [SOLVED] Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-14 Thread Brian Dessent
Carlo Florendo wrote:

> On a curious note, why do the inetutils  apps like ftp, telnet, etc.
> still use getservbyname() and the other getserv  functions when, as you
> said,
> these apps could just have the port and protocol hardcoded or specified
> in a config file?

As far as I know that traces back to the original TCP/IP networking code
in unix, 4.2BSD circa 1983 from what a quick google shows.  Back then
things were a lot simpler and I suppose it was more straightforward to
have one config file that defined all the services the box was running
and what ports they were to listen on, and to have each daemon query
that file through getservbyname().  As far as I know the tools in
inetutils are the direct descendents of the original BSD commands from
way back, so the code still uses those methods.

Brian

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



[SOLVED] Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Carlo Florendo
Hello Brian,
What we had was *not* a cygwin problem after all...
Brian Dessent wrote:
Carlo Florendo wrote:
 

Anyway, I got this error:
getservbyname() returned NULL: win32 error 11004
   

Googling shows that this is consistent with trying to run a
program/server that tries to look up its port in the services file when
no such matching line exists.
 

I also read the message regarding the \r\n and \n line endings (still
not in my mailbox) and Corinna's reply.  I've checked the services file
and confirmed that the line endings are \r\n  (with the simple test of
^M showing up when invoking `vim -b'.  Notepad also views the file
correctly, thus it's really \r\n.).
I'm confident we're getting close!
   

Closer yes, 

Yes.  In fact, ftp is working perfectly well now.   Thank you very 
much.  More below...

but I'm afraid I don't have much else coming to mind. 
Everything indicates that it's not finding what it's looking for in the
services file.  

Correct.  That is because the services file wasn't present in the first 
place.  Let me explain...

Since the `services' file  was involved, I thought of having a way to 
monitor which files the ftp client accesses to make sure that it really 
accesses the `services' file.  I then remembered that I  had  this copy 
of sysinternal's (www.sysinternals.com) filemonitor program filemon.exe 
which displays file access on a system in real time.   Thus, I simply 
fired up filemon.exe, then fired up ftp, and poof, got the answer right 
smack in my face.

ftp was trying to access c:\winnt\nsdb\services.  I then checked my 
system and c:\winnt\nsdb\ really existed but c:\winnt\nsdb\services did 
not.   Then, I wondered why it was looking at that directory and not 
c:\winnt\system32\drivers\etc.   I had no way of finding out where the 
system got c:\winnt\nsdb but I first assumed that it got that location 
from the registry.  I fired up regedit and looked for all instances of 
`nsdb'.  Interestingly, I got this registry key/value:

\HKLM\SYSTEM\ControlSet001\Services\Tcpip\Parameters\DataBasePath = 
%SystemRoot%\nsdb

I changed the registry entry value to
%SystemRoot%\system32\drivers\etc
then fired up ftp.  Whew!  It worked perfectly.
I searched on the cause of a modification of this registry entry and it 
was a virus (which has long been removed from the system).

One thing is clear though, this is not a Cygwin problem.  The mingw
example shows a minimal testcase that involves no Cygwin code at all,
just direct calls to the Winsock functions.  I'm willing to bet if you
found a regular windows application that tried to look up a port using
getservbyname() it would fail in the same way.
Correct again.  In fact, I made a simple program in VC++ that used 
getservbyname() and it failed exactly the same way as
your *.c codes.

 This is a relatively
rare/antiquated thing to do as most apps either have the port
configurable via a URL or a config file, or they just hard-code it.
If you want a quick and dirty solution, comment out the call to
getservbyname in the ftp source code and modify it to assume port 21. 
But that's admitting defeat, really.

 

We won't, we didn't and we won.  Thanks Brian and to everyone for the 
valuable comments which led us to lay this problem to rest.
On a curious note, why do the inetutils  apps like ftp, telnet, etc. 
still use getservbyname() and the other getserv  functions when, as you 
said,
these apps could just have the port and protocol hardcoded or specified 
in a config file?

In any case, this is what I like with cygwin the cygwin mailing list.  
They're the best!  Cygwin...It Rocks!

Best Regards,
Carlo
--
Carlo Florendo
Astra Philippines Inc.
www.astra.ph
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Reini Urban
Dave Korn schrieb:
  Time to start suspecting LSP problems, which I think are known to
sometimes damage the getXbyY functions.  Maybe "netsh winsock reset catalog"
(sp2 only) or http://www.cexx.org/lspfix.htm could help?
Thanks. This saved my day!
(Babylon was my culprit, but gDivx is also very common)
--
Reini Urban
http://xarch.tu-graz.ac.at/home/rurban/
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


RE: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Dave Korn
> -Original Message-
> From: cygwin-owner On Behalf Of Corinna Vinschen
> Sent: 13 October 2004 09:43

> On Oct 13 00:05, Brian Dessent wrote:
> > Carlo Florendo wrote:
> > 
> > > Here's what I got:
> > > 
> > > getservbyname() returned NULL: Operation not permitted
> 
> Not good.


  Time to start suspecting LSP problems, which I think are known to
sometimes damage the getXbyY functions.  Maybe "netsh winsock reset catalog"
(sp2 only) or http://www.cexx.org/lspfix.htm could help?


cheers, 
  DaveK
-- 
Can't think of a witty .sigline today


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Brian Dessent
Carlo Florendo wrote:

> Anyway, I got this error:
> 
> getservbyname() returned NULL: win32 error 11004

Googling shows that this is consistent with trying to run a
program/server that tries to look up its port in the services file when
no such matching line exists.

> I also read the message regarding the \r\n and \n line endings (still
> not in my mailbox) and Corinna's reply.  I've checked the services file
> and confirmed that the line endings are \r\n  (with the simple test of
> ^M showing up when invoking `vim -b'.  Notepad also views the file
> correctly, thus it's really \r\n.).
> 
> I'm confident we're getting close!

Closer yes, but I'm afraid I don't have much else coming to mind. 
Everything indicates that it's not finding what it's looking for in the
services file.  Maybe some spaces got replaced by tabs and windows
cannot cope?  Maybe your cat walked across the keyboard when you had the
file open in an editor?  :-)  Try the minimal services file necessary:

cd `cygpath -u $SYSTEMROOT/system32/drivers/etc`
mv services services.bak
echo "ftp 21/tcp" >services   # according to corinna there's no need for
\r here

If that fixes the testcase then gradually add back the rest of the stuff
in the file until you figure out what it is that's causing it to fail.

One thing is clear though, this is not a Cygwin problem.  The mingw
example shows a minimal testcase that involves no Cygwin code at all,
just direct calls to the Winsock functions.  I'm willing to bet if you
found a regular windows application that tried to look up a port using
getservbyname() it would fail in the same way.  This is a relatively
rare/antiquated thing to do as most apps either have the port
configurable via a URL or a config file, or they just hard-code it.

If you want a quick and dirty solution, comment out the call to
getservbyname in the ftp source code and modify it to assume port 21. 
But that's admitting defeat, really.

Brian

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Carlo Florendo
Brian Dessent wrote:
Brian Dessent wrote:
 

cat 

Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Corinna Vinschen
On Oct 13 00:05, Brian Dessent wrote:
> Carlo Florendo wrote:
> 
> > Here's what I got:
> > 
> > getservbyname() returned NULL: Operation not permitted

Not good.

> Perhaps the line endings got screwed up in your services file at some
> point?  They should be DOS (\r\n) not unix (\n).

AFAIK and AFAICS, the line endings shouldn't affect NT systems (tested
on NT4sp6 and XPsp2).


Corinna

-- 
Corinna Vinschen  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader  mailto:[EMAIL PROTECTED]
Red Hat, Inc.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Brian Dessent
Carlo Florendo wrote:

> >Correction: add "-lws2_32" to the gcc options.
>
> Oh, thank you.  I've actually done it and my previous post actually
> shows the output of the executable compiled with
> 
> gcc -mno-cygwin -lws2_32  getservbyname-mingw.c
> 
> There's something definitely wrong here.  I know that doing the compile
> should work.

The order that you specify the options matters.  Put the "-lws2_32"
after the .c filename argument.

Brian

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Carlo Florendo
Brian Dessent wrote:
Brian Dessent wrote:
 

cat 

Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-13 Thread Brian Dessent
Carlo Florendo wrote:

> Here's what I got:
> 
> getservbyname() returned NULL: Operation not permitted

Hmm.  That's the same thing I get if I rename my "services" file to
something else so that it's not found.  But it seems we've already
thoroughly checked that.  If you also get win32 error 11004 ("The
requested name is valid and was found in the database, but it does not
have the correct associated data being resolved for") for the mingw
version then that strongly suggests something is still not right with
the services file.  However, an error when running the mingw version at
least tells us that it's not Cygwin, since the Cygwin DLL is not loaded
for that one.

Perhaps the line endings got screwed up in your services file at some
point?  They should be DOS (\r\n) not unix (\n).

Brian

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Carlo Florendo
Hello Brian,
Brian Dessent wrote:
Carlo Florendo wrote:
 

File:  inetutils-1.3.2-28 /ftp/main.c  (line numbers preceed each line)
147 sp = getservbyname("ftp", "tcp");
148 if (sp == 0)
149 errx(1, "ftp/tcp: unknown service");
   

Okay, so the 'SYSTEM' thing was a red herring, and you're just running
this from a normal command prompt.  Your SYSTEMROOT is set 

absolutely.
and nothing
seems odd in your cygcheck, and permissions on the "services" file seem
okay.  Although I think your reasoning there is a little off-base:
Cygwin itself does not attempt to access that file at all.  Cygwin's
getservbyname() just a straight passthru to the Winsock function of the
same name which does the actual lookup.
 

Ok. thanks for the info.
Try the following and see what happens:
cat s_port));
   else
   printf( "getservbyname() returned NULL: %s\n",
   strerror(errno));
}
ENDL
 

Here's what I got:
getservbyname() returned NULL: Operation not permitted

Also try the following variant that will create a mingw version of the
same test:
cat s_port));
   else
   printf( "getservbyname() returned NULL: win32 error %u\n",
   WSAGetLastError());
}
ENDL

 

This one didn't link properly.  Anyway, here's the output:
/cygdrive/c/DOCUME~1/Carlo/LOCALS~1/Temp/ccYVHUNc.o(.text+0x3f):getservbyname-mingw.c: 
undefined reference to [EMAIL PROTECTED]'
/cygdrive/c/DOCUME~1/Carlo/LOCALS~1/Temp/ccYVHUNc.o(.text+0x87):getservbyname-mingw.c: 
undefined reference to [EMAIL PROTECTED]'
/cygdrive/c/DOCUME~1/Carlo/LOCALS~1/Temp/ccYVHUNc.o(.text+0xa2):getservbyname-mingw.c: 
undefined reference to [EMAIL PROTECTED]'
/cygdrive/c/DOCUME~1/Carlo/LOCALS~1/Temp/ccYVHUNc.o(.text+0xbf):getservbyname-mingw.c: 
undefined reference to [EMAIL PROTECTED]'
collect2: ld returned 1 exit status

Both of those should say "getservbyname() returned port 21".  If either
fails, paste the output.  I suppose it's remotely possible that
something's wrong with wsock32.dll or ws2_32.dll on your system, but if
that was the case you'd have many more problems I'd think.
 

Hmmm.  There's something fishy of my system
Thanks a lot!
Best Regards,
Carlo
--
Carlo Florendo
Astra Philippines Inc.
www.astra.ph

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Brian Dessent
Brian Dessent wrote:

> cat   getservbyname-mingw.c -o getservbyname-mingw && ./getservbyname-mingw

Correction: add "-lws2_32" to the gcc options.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Brian Dessent
Carlo Florendo wrote:

> File:  inetutils-1.3.2-28 /ftp/main.c  (line numbers preceed each line)
> 
> 147 sp = getservbyname("ftp", "tcp");
> 148 if (sp == 0)
> 149 errx(1, "ftp/tcp: unknown service");

Okay, so the 'SYSTEM' thing was a red herring, and you're just running
this from a normal command prompt.  Your SYSTEMROOT is set and nothing
seems odd in your cygcheck, and permissions on the "services" file seem
okay.  Although I think your reasoning there is a little off-base:
Cygwin itself does not attempt to access that file at all.  Cygwin's
getservbyname() just a straight passthru to the Winsock function of the
same name which does the actual lookup.

Try the following and see what happens:

cat s_port));
else
printf( "getservbyname() returned NULL: %s\n",
strerror(errno));
}
ENDL

Also try the following variant that will create a mingw version of the
same test:


cat s_port));
else
printf( "getservbyname() returned NULL: win32 error %u\n",
WSAGetLastError());
}
ENDL

Both of those should say "getservbyname() returned port 21".  If either
fails, paste the output.  I suppose it's remotely possible that
something's wrong with wsock32.dll or ws2_32.dll on your system, but if
that was the case you'd have many more problems I'd think.

Brian

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Carlo Florendo
Brian Dessent wrote:
Carlo Florendo wrote:
 

Thank you so much for your comments!However, updating the relevant
directories to have +x, and updating all the relevant files to have +rx
still didn't solve the issue.  I've tried to track down the problem via
the source code of inetutils-1.3.2-28 and it seems the actual error
message is produced by the following code:
   

I can't tell from your message but since your prompts contain the
username 'SYSTEM' I am assuming that you're testing this from a sysbash
prompt in the context of something that's being run from a service, CGI,
cronjob, etc... If that's the case then it sounds awfully like the
problem of SYSTEMROOT being removed from the environment.  Check that
this variable is set for the process that is trying to run ftp.  There's
lots of recent threads about it in the archives if you need more
background.
Brian
 

Oh, and by the way, I'm not testing from a sysbash prompt in the context 
of something being run from a service. 
I'm testing the system on an ordinary user account.  My shell is not 
started from a cron job nor a service.  I click my rxvt shortcut, and poof,
use the shell.

Thanks!
Best Regards,
Carlo
--
Carlo Florendo
Astra Philippines Inc.
www.astra.ph
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Carlo Florendo
Christopher Faylor wrote:
On Tue, Oct 12, 2004 at 08:14:50PM -0700, Brian Dessent wrote:
 

Carlo Florendo wrote:
   

Thank you so much for your comments!However, updating the relevant
directories to have +x, and updating all the relevant files to have +rx
still didn't solve the issue.  I've tried to track down the problem via
the source code of inetutils-1.3.2-28 and it seems the actual error
message is produced by the following code:
 

I can't tell from your message but since your prompts contain the
username 'SYSTEM' I am assuming that you're testing this from a sysbash
prompt in the context of something that's being run from a service,
CGI, cronjob, etc...  If that's the case then it sounds awfully like
the problem of SYSTEMROOT being removed from the environment.  Check
that this variable is set for the process that is trying to run ftp.
There's lots of recent threads about it in the archives if you need
more background.
   

And, if you aren't already, try the most recent cygwin snapshot:
http://cygwin.com/snapshots/
 

I tried the latest snapshot and it still doesn't work.  Attached is 
cygcheck's output after installing the latest snapshot.

Thanks!
Best Regards,
Carlo
--
Carlo Florendo
Astra Philippines Inc.
www.astra.ph



Cygwin Configuration Diagnostics
Current System Time: Wed Oct 13 12:18:36 2004

Windows 2000 Professional Ver 5.0 Build 2195 Service Pack 4

Path:   D:\cygwin\usr\local\bin
D:\cygwin\bin
D:\cygwin\bin
D:\cygwin\sbin
D:\cygwin\usr\sbin
D:\cygwin\usr\X11R6\bin
c:\WINNT\system32
c:\WINNT
c:\WINNT\System32\Wbem
d:\Microsoft Visual Studio\Common\Tools\WinNT
d:\Microsoft Visual Studio\Common\MSDev98\Bin
d:\Microsoft Visual Studio\Common\Tools
d:\Microsoft Visual Studio\VC98\bin
f:\Program Files\INUS Technology\RapidForm2004\Exchange
f:\Program Files\INUS Technology\RapidForm2004\Exchange\intel_a\code\bin
.\

Output from D:\cygwin\bin\id.exe (nontsec)
UID: 1000(Carlo) GID: 513(None)
513(None)

Output from D:\cygwin\bin\id.exe (ntsec)
UID: 1000(Carlo) GID: 513(None)
0(root)  513(None)
544(Administrators)  545(Users)

SysDir: C:\WINNT\system32
WinDir: C:\WINNT

CYGWIN = `server'
HOME = `D:\cygwin\home\Carlo'
MAKE_MODE = `unix'
PWD = `/home/Carlo'
USER = `Carlo'

ALLUSERSPROFILE = `C:\Documents and Settings\All Users'
APPDATA = `C:\Documents and Settings\Carlo\Application Data'
CATDEFAULTENVIRONMENT = `InterOpB11'
COLORFGBG = `15;default;0'
COLORTERM = `rxvt-xpm'
COMMONPROGRAMFILES = `C:\Program Files\Common Files'
COMPUTERNAME = `THORIN'
COMSPEC = `C:\WINNT\system32\cmd.exe'
CVS_RSH = `/bin/ssh'
DISPLAY = `:0'
HOMEDRIVE = `C:'
HOMEPATH = `\Documents and Settings\Carlo'
HOSTNAME = `thorin'
INCLUDE = `D:\Microsoft Visual Studio\VC98\atl\include;D:\Microsoft Visual 
Studio\VC98\mfc\include;D:\Microsoft Visual Studio\VC98\include'
INFOPATH = 
`/usr/local/info:/usr/info:/usr/share/info:/usr/autotool/devel/info:/usr/autotool/stable/info:'
LIB = `D:\Microsoft Visual Studio\VC98\mfc\lib;D:\Microsoft Visual Studio\VC98\lib'
LOGONSERVER = `\\THORIN'
MANPATH = 
`/usr/local/man:/usr/man:/usr/share/man:/usr/autotool/devel/man::/usr/ssl/man:/usr/X11R6/man'
MSDEVDIR = `D:\Microsoft Visual Studio\Common\MSDev98'
NUMBER_OF_PROCESSORS = `1'
OLDPWD = `/usr/bin'
OS2LIBPATH = `C:\WINNT\system32\os2\dll;'
OS = `Windows_NT'
OSDS = `intel_a'
PATHEXT = `.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH'
PKG_CONFIG_PATH = `/usr/X11R6/lib/pkgconfig'
PROCESSOR_ARCHITECTURE = `x86'
PROCESSOR_IDENTIFIER = `x86 Family 15 Model 1 Stepping 2, GenuineIntel'
PROCESSOR_LEVEL = `15'
PROCESSOR_REVISION = `0102'
PROGRAMFILES = `C:\Program Files'
PS1 = `\[\033]0;\w\007
[EMAIL PROTECTED] \[\033[33m\w\033[0m\]
$ '
SHLVL = `1'
SYSTEMDRIVE = `C:'
SYSTEMROOT = `C:\WINNT'
TEMP = `c:\DOCUME~1\Carlo\LOCALS~1\Temp'
TERM = `xterm'
TEXMF = `{/usr/share/lilypond/2.2.5,/usr/share/texmf}'
TMP = `c:\DOCUME~1\Carlo\LOCALS~1\Temp'
USERDOMAIN = `THORIN'
USERNAME = `Carlo'
USERPROFILE = `C:\Documents and Settings\Carlo'
WINDIR = `C:\WINNT'
WINDOWID = `168114296'
_ = `/usr/bin/cygcheck'
POSIXLY_CORRECT = `1'

HKEY_CURRENT_USER\Software\Cygnus Solutions
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\mounts v2
HKEY_CURRENT_USER\Software\Cygnus Solutions\Cygwin\Program Options
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2
  (default) = `/cygdrive'
  cygdrive flags = 0x0022
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/
  (default) = `D:\cygwin'
  flags = 0x000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/usr/bin
  (default) = `D:\cygwin/bin'
  flags = 0x000a
HKEY_LOCAL_MACHINE\SOFTWARE\Cygnus Solutions\Cygwin\mounts v2\/usr/lib
  (default) = `D:\cygwin/lib'
  flags = 0x000a
HKEY_LOC

Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Carlo Florendo
Hello Brian,
Brian Dessent wrote:
Carlo Florendo wrote:
 

Thank you so much for your comments!However, updating the relevant
directories to have +x, and updating all the relevant files to have +rx
still didn't solve the issue.  I've tried to track down the problem via
the source code of inetutils-1.3.2-28 and it seems the actual error
message is produced by the following code:
   

I can't tell from your message but since your prompts contain the
username 'SYSTEM' I am assuming that you're testing this from a sysbash
prompt in the context of something that's being run from a service, CGI,
cronjob, etc... If that's the case then it sounds awfully like the
problem of SYSTEMROOT being removed from the environment.  Check that
this variable is set for the process that is trying to run ftp.  There's
lots of recent threads about it in the archives if you need more
background.
 

You really have a keen eye!  However, the string "SYSTEM" doesn't have 
anything to do with the problem since I just
set the PS1 environment variable to "SYSTEM" since I don't want it 
printing my name.

My PS1 is set to:  PS1="SYSTEM \w\n$ "
And of course, if I change PS1 to the cygwin default (as shown below), 
ftp still won't work.

SYSTEM /
$ export   PS1='\[\033]0;\w\007
> [EMAIL PROTECTED] \[\033[33m\w\033[0m\]
> $ '
[EMAIL PROTECTED] /
$ ftp
ftp: ftp/tcp: unknown service
Thanks!
Best Regards,
Carlo
--
Carlo Florendo
Astra Philippines Inc.
www.astra.ph
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Christopher Faylor
On Tue, Oct 12, 2004 at 08:14:50PM -0700, Brian Dessent wrote:
>Carlo Florendo wrote:
>>Thank you so much for your comments!However, updating the relevant
>>directories to have +x, and updating all the relevant files to have +rx
>>still didn't solve the issue.  I've tried to track down the problem via
>>the source code of inetutils-1.3.2-28 and it seems the actual error
>>message is produced by the following code:
>
>I can't tell from your message but since your prompts contain the
>username 'SYSTEM' I am assuming that you're testing this from a sysbash
>prompt in the context of something that's being run from a service,
>CGI, cronjob, etc...  If that's the case then it sounds awfully like
>the problem of SYSTEMROOT being removed from the environment.  Check
>that this variable is set for the process that is trying to run ftp.
>There's lots of recent threads about it in the archives if you need
>more background.

And, if you aren't already, try the most recent cygwin snapshot:

http://cygwin.com/snapshots/

cgf

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Carlo Florendo
Hello Igor,
Igor Pechtchanski wrote:
Carlo,
See comments inline below.
Thank you so much for your comments!However, updating the relevant 
directories to have +x, and updating all the relevant files to have +rx  
still didn't solve the issue.  I've tried to track down the problem via 
the source code of inetutils-1.3.2-28 and it seems the actual error 
message is produced by the following code:

File:  inetutils-1.3.2-28 /ftp/main.c  (line numbers preceed each line)
147 sp = getservbyname("ftp", "tcp");
148 if (sp == 0)
149 errx(1, "ftp/tcp: unknown service");
I compiled and run ftp from source.   I get the same result.  sp is 
always 0 (NULL).   Thus, there's something not correct about my system.  
To test whether the relevant files under /etc are really readable, I've 
made this short test code which tries to open the files hosts, networks, 
protocols and services and print their corresponding handles to show 
that they're readable.  In addition, I've also placed a file 
/cygdrive/c/testfile which has permissions 000 to make sure that it's 
unreadable by anyone. 

#include 
#include 
/* file name: test.c */
int main()
{
   FILE *handle_hosts = NULL,
   *handle_networks = NULL,
   *handle_protocols = NULL,
   *handle_services = NULL,
   *handle_testfile = NULL;
   struct servent *sp = NULL;
   handle_hosts = fopen
   ("/cygdrive/c/WINNT/system32/drivers/etc/hosts", "r");
   handle_networks= fopen
   ("/cygdrive/c/WINNT/system32/drivers/etc/networks", "r");
   handle_protocols= fopen
   ("/cygdrive/c/WINNT/system32/drivers/etc/protocol", "r");
   handle_services= fopen
   ("/cygdrive/c/WINNT/system32/drivers/etc/services", "r");
   handle_testfile = fopen("/cygdrive/c/testfile", "r");
   printf("%s: %#x\n", "hosts handle", handle_hosts);
   printf("%s: %#x\n", "networks handle", handle_networks);
   printf("%s: %#x\n", "protocols handle", handle_protocols);
   printf("%s: %#x\n", "servies handle", handle_services);
   printf("%s: %#x\n", "/cygdrive/c/testfile", handle_testfile);
   sp = getservbyname("ftp","tcp");
   printf("%s: %#x\n", "servent handle", sp);
   fcloseall();
   return 0;
}
The following is the output:
SYSTEM  /tmp/ftp/inetutils-1.3.2-28/ftp
$ gcc test.c
SYSTEM /tmp/ftp/inetutils-1.3.2-28/ftp
$ ./a.exe
/etc/hosts handle: 0xa0501e4
/etc/networks handle: 0xa05024c
/etc/protocol handle: 0xa0502b4
/etc/servies handle: 0xa05031c
/cygdrive/c/testfile: 0
servent handle: 0
As you can see, all the relevant files have their respective handles.  
Thus, they were opened successfully.  On the other hand, 
/cygdrive/c/testfile gets a 0 (NULL) handle (logically) since its 
permissions are 000.

Here's the /cygdrive/c/testfile listing:
SYSTEM  /tmp/ftp/inetutils-1.3.2-28/ftp
$ ls -l /cygdrive/c/testfile
--1 CarloNone0 Oct 13 09:19 /cygdrive/c/testfile
I hope that takes care of the files. 

Now, a curious thing to note is that the servent handle sp returned 0 
(NULL).  It's suppose to read /etc/services.   A cat of /etc/services 
(I'll just use the symlinks since I want to save time not typing the 
entire FQN (e.g. /cygdrive/c/winnt etc. )) give me:

$ cat /etc/services
# Copyright (c) 1993-1999 Microsoft Corp.
#
# This file contains port numbers for well-known services defined by IANA
#
# Format:
#
#   /  [aliases...]   [#]
#
echo7/tcp
echo7/udp
discard 9/tcpsink null
discard 9/udpsink null
systat 11/tcpusers  #Active users
systat 11/tcpusers  #Active users
daytime13/tcp
daytime13/udp
qotd   17/tcpquote  #Quote of the day
qotd   17/udpquote  #Quote of the day
chargen19/tcpttytst source  #Character generator
chargen19/udpttytst source  #Character generator
ftp-data   20/tcp   #FTP, data
ftp21/tcp   #FTP. control
telnet 23/tcp
smtp   25/tcpmail   #Simple Mail 
Transfer Protocol


FWIW, the cat of  protocol gives me:
$ cat /etc/protocols
# Copyright (c) 1993-1999 Microsoft Corp.
#
# This file contains the Internet protocols as defined by RFC 1700
# (Assigned Numbers).
#
# Format:
#
# [aliases...]   [#]
ip   0 IP   # Internet protocol
icmp 1 ICMP # Internet control message protocol
ggp  3 GGP  # Gateway-gateway protocol
tcp  6 TCP  # Transmission control protocol

The cat of /etc/hosts gives:
$ cat /etc/hosts
# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the cor

Re: other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-12 Thread Igor Pechtchanski
Carlo,
See comments inline below.
On Tue, 12 Oct 2004, Carlo Florendo wrote:
Hello,
I've recently searched the archives for problems regarding cygwin unable
to do ftp and came across the thead entitled "1.5.11 - tcp problems"
which was started on September 14. I've replied to the last message in
the thread (since the problem seemed not to be solved on the mailing
list.)
I'm encountering exactly the same problem where invoking /usr/bin/ftp
gives a:
ftp: ftp/tcp: unknown service.
On my system, /etc/services is indeed a symlink to the Windows services
file:
/etc/services -> C:\WINNT\system32\drivers\etc\services
I've followed the advice on one of the message replies stating that
there should at least be +r access on services by users.  I also made
sure the parent directories containing `service' to be readable by all.
Here's how the permissions look like now:
SYSTEM /cygdrive/c
$ ls -ld winnt
drwxrwxr-x+  40 Administ SYSTEM  32768 Oct  6 11:17 winnt
SYSTEM /cygdrive/c
$ cd winnt
SYSTEM /cygdrive/c/winnt
$ ls -ld system32
drwxrwxr-x+  29 Administ SYSTEM 319488 Oct 12 08:29 system32
SYSTEM /cygdrive/c/winnt
$ cd system32
SYSTEM /cygdrive/c/winnt/system32
$ ls -ld drivers
drwxrwxr--+   4 Administ SYSTEM  28672 Sep 20 15:34 drivers
^^^
SYSTEM /cygdrive/c/winnt/system32
$ cd drivers
SYSTEM /cygdrive/c/winnt/system32/drivers
$ ls -ld etc
drwxrwxr--+   2 Administ SYSTEM   4096 Jun 22 00:09 etc
 ^^^
They have to be executable, not readable.  The readable bit controls
listing the contents of the directory, but accessing the files requires
the directory to be executable.
SYSTEM /cygdrive/c/winnt/system32/drivers
$ cd etc
SYSTEM /cygdrive/c/winnt/system32/drivers/etc
$ ls -l
total 15
-rwxrwx---+   1 Administ SYSTEM   1757 Apr 11  2004 hosts
^^^
-rwxrwx---+   1 Administ SYSTEM   3683 Jul 14  2003 lmhosts.sam
-rwxrwx---+   1 Administ SYSTEM407 Jul 14  2003 networks
^^^
-rwxrwx---+   1 Administ SYSTEM799 Jul 14  2003 protocol
^^^
-rwxrwxr--+   1 Administ SYSTEM   7116 Jul 14  2003 services
All of the above have to be readable, too.
However, I stll get the same error:
SYSTEM /cygdrive/c/winnt/system32/drivers/etc
$ ftp
ftp: ftp/tcp: unknown service
Then, I copied the services file itself and temporarily renamed the
symlink. After invoking ftp, it still didn't work.
Of course it wouldn't.  Cygwin uses Winsock, which looks for the files in
the above directory, not in /etc.  The /etc links are simply to make
Cygwin look more like Linux.
Trying the windows ftp program bundled with the OS works fine, but,
FWIW, I guess this is irrelevant on this issue.
Attached is the output of cygcheck -svr.   Any hints?
Thanks a lot!
Carlo
HTH,
Igor
--
http://cs.nyu.edu/~pechtcha/
 |\  _,,,---,,_ [EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
|,4-  ) )-,_. ,\ (  `'-'Igor Pechtchanski, Ph.D.
   '---''(_/--'  `-'\_) fL  a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!
"Happiness lies in being privileged to work hard for long hours in doing
whatever you think is worth doing."  -- Dr. Jubal Harshaw
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


other services ok, ftp not (was 1.5.11 - tcp problems)

2004-10-11 Thread Carlo Florendo
Hello,
I've recently searched the archives for problems regarding cygwin unable 
to do ftp and came across the thead entitled "1.5.11 - tcp problems" 
which was started on September 14. I've replied to the last message in 
the thread (since the problem seemed not to be solved on the mailing list.)

I'm encountering exactly the same problem where invoking /usr/bin/ftp 
gives a:

ftp: ftp/tcp: unknown service.
On my system, /etc/services is indeed a symlink to the Windows services 
file:

/etc/services -> C:\WINNT\system32\drivers\etc\services
I've followed the advice on one of the message replies stating that 
there should at least be +r  access on services by users.   I also made 
sure the parent directories containing `service' to be readable by all.  
Here's how the permissions look like now:

SYSTEM /cygdrive/c
$ ls -ld winnt
drwxrwxr-x+  40 Administ SYSTEM  32768 Oct  6 11:17 winnt
SYSTEM /cygdrive/c
$ cd winnt
SYSTEM /cygdrive/c/winnt
$ ls -ld system32
drwxrwxr-x+  29 Administ SYSTEM 319488 Oct 12 08:29 system32
SYSTEM /cygdrive/c/winnt
$ cd system32
SYSTEM /cygdrive/c/winnt/system32
$ ls -ld drivers
drwxrwxr--+   4 Administ SYSTEM  28672 Sep 20 15:34 drivers
SYSTEM /cygdrive/c/winnt/system32
$ cd drivers
SYSTEM /cygdrive/c/winnt/system32/drivers
$ ls -ld etc
drwxrwxr--+   2 Administ SYSTEM   4096 Jun 22 00:09 etc
SYSTEM /cygdrive/c/winnt/system32/drivers
$ cd etc
SYSTEM /cygdrive/c/winnt/system32/drivers/etc
$ ls -l
total 15
-rwxrwx---+   1 Administ SYSTEM   1757 Apr 11  2004 hosts
-rwxrwx---+   1 Administ SYSTEM   3683 Jul 14  2003 lmhosts.sam
-rwxrwx---+   1 Administ SYSTEM407 Jul 14  2003 networks
-rwxrwx---+   1 Administ SYSTEM799 Jul 14  2003 protocol
-rwxrwxr--+   1 Administ SYSTEM   7116 Jul 14  2003 services
However, I stll get the same error:
SYSTEM /cygdrive/c/winnt/system32/drivers/etc
$ ftp
ftp: ftp/tcp: unknown service
Then, I copied the services file itself and temporarily renamed the 
symlink.  After invoking ftp, it still didn't work.

Trying the windows ftp program bundled with the OS works fine, but, 
FWIW, I guess this is irrelevant on this issue.

Attached is the output of cygcheck -svr.   Any hints?
Thanks a lot!
Best Regards,
Carlo
--
Carlo Florendo
Astra Philippines Inc.
www.astra.ph
Marcus Davage wrote:
Sorry about the compressed file! :-)
PATH='/opt/qt/3.2/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/sbin:/cygdrive/c/DmiNT40/Win32/bin:/cygdrive/c/DMI/bin:/cygdrive/c/WINNT/system32:/cygdrive/c/WINNT:/cygdrive/c/Program
Files/Personal
Communications:/cygdrive/d/MSSQL7/BINN:/cygdrive/d/program
files/IBM/DB2 Extenders/bin:/cygdrive/d/Program Files/IBM/DB2 XML
Extenders/bin:/usr/bin:/usr/sbin:/usr/X11R6/bin:/sbin:/opt/gnome/bin:/home/9763207/bin:/cygdrive/d/PROGRA~1/SQLLIB/BIN:/cygdrive/d/PROGRA~1/SQLLIB/FUNCTION:/cygdrive/d/PROGRA~1/SQLLIB/SAMPLES/REPL:/cygdrive/d/objrexx:/opt/gnome/bin'
SYSTEMROOT='C:\WINNT'
As required.
Regards,
Marcus
 


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/


Cygwin Configuration Diagnostics
Current System Time: Tue Oct 12 09:51:51 2004

Windows 2000 Professional Ver 5.0 Build 2195 Service Pack 4

Path:   D:\cygwin\usr\local\bin
D:\cygwin\bin
D:\cygwin\bin
D:\cygwin\sbin
D:\cygwin\usr\sbin
D:\cygwin\usr\X11R6\bin
c:\WINNT\system32
c:\WINNT
c:\WINNT\System32\Wbem
d:\Microsoft Visual Studio\Common\Tools\WinNT
d:\Microsoft Visual Studio\Common\MSDev98\Bin
d:\Microsoft Visual Studio\Common\Tools
d:\Microsoft Visual Studio\VC98\bin
f:\Program Files\INUS Technology\RapidForm2004\Exchange
f:\Program Files\INUS Technology\RapidForm2004\Exchange\intel_a\code\bin
.\

Output from D:\cygwin\bin\id.exe (nontsec)
UID: 1000(Carlo) GID: 513(None)
513(None)

Output from D:\cygwin\bin\id.exe (ntsec)
UID: 1000(Carlo) GID: 513(None)
0(root)  513(None)
544(Administrators)  545(Users)

SysDir: C:\WINNT\system32
WinDir: C:\WINNT

CYGWIN = `server'
HOME = `D:\cygwin\home\Carlo'
MAKE_MODE = `unix'
PWD = `/etc'
USER = `Carlo'

ALLUSERSPROFILE = `C:\Documents and Settings\All Users'
APPDATA = `C:\Documents and Settings\Carlo\Application Data'
CATDEFAULTENVIRONMENT = `InterOpB11'
COLORFGBG = `15;default;0'
COLORTERM = `rxvt-xpm'
COMMONPROGRAMFILES = `C:\Program Files\Common Files'
COMPUTERNAME = `THORIN'
COMSPEC = `C:\WINNT\system32\cmd.exe'
CVS_RSH = `/bin/ssh'
DISPLAY = `:0'
HOMEDRIVE = `C:'
HOMEPATH = `\Documents and Settings\Carlo'
HOSTNAME = `thorin'
INCLUDE = `D:\Microsoft Vi

Re: 1.5.11 - tcp problems

2004-09-21 Thread Marcus Davage
Sorry about the compressed file! :-)

PATH='/opt/qt/3.2/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/sbin:/cygdrive/c/DmiNT40/Win32/bin:/cygdrive/c/DMI/bin:/cygdrive/c/WINNT/system32:/cygdrive/c/WINNT:/cygdrive/c/Program
Files/Personal
Communications:/cygdrive/d/MSSQL7/BINN:/cygdrive/d/program
files/IBM/DB2 Extenders/bin:/cygdrive/d/Program Files/IBM/DB2 XML
Extenders/bin:/usr/bin:/usr/sbin:/usr/X11R6/bin:/sbin:/opt/gnome/bin:/home/9763207/bin:/cygdrive/d/PROGRA~1/SQLLIB/BIN:/cygdrive/d/PROGRA~1/SQLLIB/FUNCTION:/cygdrive/d/PROGRA~1/SQLLIB/SAMPLES/REPL:/cygdrive/d/objrexx:/opt/gnome/bin'

SYSTEMROOT='C:\WINNT'

As required.

Regards,
Marcus


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

Re: 1.5.11 - tcp problems

2004-09-21 Thread Corinna Vinschen
On Sep 20 13:31, Marcus Davage wrote:
> Corinna,
> 
> >I'm wondering if C:\WINNT\system32\drivers\etc\services is readable
> >for everyone.  Could you go into the above directory and call
> >
> >  chmod a+r services
> 
> Everyone can read it.
> 
> >Attaching the cygcheck output could perhaps give us a clue what's
> >going wrong on your system.
> 
> Attached - cygcheck.txt.bz2

Quote from http://cygwin.com/problems.html:

"Please do not compress or otherwise encode the output. Just attach it
 as a straight text file so that it can be easily viewed."

But the cygcheck output doesn't help, unfortunately. 

When running ftp, how are the environment variables $PATH and $SYSTEMROOT
set?  PATH must contain C:\WINNT\system32 (resp. /cygdrive/c/WINNT/system32)
and SYSTEMROOT must be set to C:\WINNT.  Could you check that?


Corinna

-- 
Corinna Vinschen  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader  mailto:[EMAIL PROTECTED]
Red Hat, Inc.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: 1.5.11 - tcp problems

2004-09-20 Thread Marcus Davage
Corinna,

>I'm wondering if C:\WINNT\system32\drivers\etc\services is readable
>for everyone.  Could you go into the above directory and call
>
>  chmod a+r services

Everyone can read it.

>Attaching the cygcheck output could perhaps give us a clue what's
>going wrong on your system.

Attached - cygcheck.txt.bz2

Thanks.

Marcus



cygcheck.txt.bz2
Description: Zip archive
--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

Re: 1.5.11 - tcp problems

2004-09-15 Thread Corinna Vinschen
On Sep 15 10:01, Marcus Davage wrote:
> Firstly, sorry, but I am afriad I cannot CYMTNQREAIYR - it's out of my
> control.

I don't think so.  The last resort is called "hand editing".  That should
always work sufficiently.

> Next, my dir /etc/services returns
> services -> C:\WINNT\system32\drivers\etc\services*
> so it IS a symlink to Windows.

I'm wondering if C:\WINNT\system32\drivers\etc\services is readable
for everyone.  Could you go into the above directory and call

  chmod a+r services

and try again?  Other than that, please follow the guidelines on
http://cygwin.com/problems.html

Attaching the cygcheck output could perhaps give us a clue what's
going wrong on your system.


Corinna

-- 
Corinna Vinschen  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader  mailto:[EMAIL PROTECTED]
Red Hat, Inc.

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: 1.5.11 - tcp problems

2004-09-15 Thread Marcus Davage
Firstly, sorry, but I am afriad I cannot CYMTNQREAIYR - it's out of my
control.
Next, my dir /etc/services returns
services -> C:\WINNT\system32\drivers\etc\services*
so it IS a symlink to Windows.

Marcus


--Original Mail--
Marcus,

First off, .  Thanks.

Secondly, the /etc/services file seems ok, but in Cygwin it's actually
a
symlink to the one in the Windows system directory.  Do you have the
symlink on your system, or is /etc/services a file?  If it's a file,
Windows (in particular, winsock) won't be aware of it.
Igor


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

Re: 1.5.11 - tcp problems

2004-09-14 Thread Igor Pechtchanski
Marcus,

First off, <http://cygwin.com/acronyms/#PCYMTNQREAIYR>.  Thanks.

Secondly, the /etc/services file seems ok, but in Cygwin it's actually a
symlink to the one in the Windows system directory.  Do you have the
symlink on your system, or is /etc/services a file?  If it's a file,
Windows (in particular, winsock) won't be aware of it.
Igor

On Tue, 14 Sep 2004, Marcus Davage wrote:

> Sorry, but I'm a bit of a novice when it comes to TCP - how should I
> edit /etc/services?
> There are currently entries for ftp and telnet already...
> ftp21/tcp
> ssh22/tcp
> ssh22/udp
> telnet 23/tcp
> smtp   25/tcpmail
>
> Regards,
> Marcus
>
> --Original Mail--
> From: Igor Pechtchanski <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED], Marcus Davage <[EMAIL PROTECTED]>
> Received On: Tue, 14 Sep 2004 15:57:24
> Subject: Re: 1.5.11 - tcp problems
>
> On Tue, 14 Sep 2004, Igor Pechtchanski wrote:
>
> > On Tue, 14 Sep 2004, Marcus Davage wrote:
> >
> > > When executing ftp command, I get...
> > > ftp: ftp/tcp: unknown service
> > >
> > > When executing x3270 hostname, I get...
> > > Unknown port number or service: telnet
> > >
> > > What can I do to re-establish tcp connectivity?
> >
> > Umm, edit /etc/protocols?
>
> Whoops, fingers ahead of the brain there.  Make that /etc/services...
>   Igor
>
> > > uname -s returns...
> > > CYGWIN_NT-4.0 wrkseverns79590 1.5.11(0.116/4/2) 2004-09-04 23:17 i686 unknown 
> > > unknown Cygwin
> > >
> > > Kind regards,
> > > Marcus

-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
 |,4-  ) )-,_. ,\ (  `'-'   Igor Pechtchanski, Ph.D.
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Happiness lies in being privileged to work hard for long hours in doing
whatever you think is worth doing."  -- Dr. Jubal Harshaw

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: 1.5.11 - tcp problems

2004-09-14 Thread Marcus Davage
Sorry, but I'm a bit of a novice when it comes to TCP - how should I
edit /etc/services?
There are currently entries for ftp and telnet already...
ftp21/tcp
ssh22/tcp
ssh22/udp
telnet 23/tcp
smtp   25/tcpmail

Regards,
Marcus

--Original Mail--
From: Igor Pechtchanski <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED], Marcus Davage <[EMAIL PROTECTED]>
Received On: Tue, 14 Sep 2004 15:57:24
Subject: Re: 1.5.11 - tcp problems

On Tue, 14 Sep 2004, Igor Pechtchanski wrote:

> On Tue, 14 Sep 2004, Marcus Davage wrote:
>
> > When executing ftp command, I get...
> > ftp: ftp/tcp: unknown service
> >
> > When executing x3270 hostname, I get...
> > Unknown port number or service: telnet
> >
> > What can I do to re-establish tcp connectivity?
>
> Umm, edit /etc/protocols?

Whoops, fingers ahead of the brain there.  Make that /etc/services...
Igor

> > uname -s returns...
> > CYGWIN_NT-4.0 wrkseverns79590 1.5.11(0.116/4/2) 2004-09-04 23:17
i686 unknown unknown Cygwin
> >
> > Kind regards,
> > Marcus

-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
 |,4-  ) )-,_. ,\ (  `'-'   Igor Pechtchanski, Ph.D.
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Happiness lies in being privileged to work hard for long hours in
doing
whatever you think is worth doing."  -- Dr. Jubal Harshaw


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/

Re: 1.5.11 - tcp problems

2004-09-14 Thread Igor Pechtchanski
On Tue, 14 Sep 2004, Igor Pechtchanski wrote:

> On Tue, 14 Sep 2004, Marcus Davage wrote:
>
> > When executing ftp command, I get...
> > ftp: ftp/tcp: unknown service
> >
> > When executing x3270 hostname, I get...
> > Unknown port number or service: telnet
> >
> > What can I do to re-establish tcp connectivity?
>
> Umm, edit /etc/protocols?

Whoops, fingers ahead of the brain there.  Make that /etc/services...
Igor

> > uname -s returns...
> > CYGWIN_NT-4.0 wrkseverns79590 1.5.11(0.116/4/2) 2004-09-04 23:17 i686 unknown 
> > unknown Cygwin
> >
> > Kind regards,
> > Marcus

-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
 |,4-  ) )-,_. ,\ (  `'-'   Igor Pechtchanski, Ph.D.
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Happiness lies in being privileged to work hard for long hours in doing
whatever you think is worth doing."  -- Dr. Jubal Harshaw

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



Re: 1.5.11 - tcp problems

2004-09-14 Thread Igor Pechtchanski
On Tue, 14 Sep 2004, Marcus Davage wrote:

> When executing ftp command, I get...
> ftp: ftp/tcp: unknown service
>
> When executing x3270 hostname, I get...
> Unknown port number or service: telnet
>
> What can I do to re-establish tcp connectivity?

Umm, edit /etc/protocols?
Igor

> uname -s returns...
> CYGWIN_NT-4.0 wrkseverns79590 1.5.11(0.116/4/2) 2004-09-04 23:17 i686 unknown 
> unknown Cygwin
>
> Kind regards,
> Marcus

-- 
http://cs.nyu.edu/~pechtcha/
  |\  _,,,---,,_[EMAIL PROTECTED]
ZZZzz /,`.-'`'-.  ;-;;,_[EMAIL PROTECTED]
 |,4-  ) )-,_. ,\ (  `'-'   Igor Pechtchanski, Ph.D.
'---''(_/--'  `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"Happiness lies in being privileged to work hard for long hours in doing
whatever you think is worth doing."  -- Dr. Jubal Harshaw

--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/



1.5.11 - tcp problems

2004-09-14 Thread Marcus Davage
When executing ftp command, I get...
ftp: ftp/tcp: unknown service

When executing x3270 hostname, I get...
Unknown port number or service: telnet

What can I do to re-establish tcp connectivity?

uname -s returns...
CYGWIN_NT-4.0 wrkseverns79590 1.5.11(0.116/4/2) 2004-09-04 23:17 i686
unknown unknown Cygwin

Kind regards,
Marcus


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Problem reports:   http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/