[Zope] Re: FTP

Maik Jablonski maik.jablonski@uni-bielefeld.de
Tue, 21 Jan 2003 15:51:03 +0100


Maik Jablonski wrote:
> D. Rick Anderson wrote:
> 
>> I'm having a problem with the FTP portion of one of my zope servers. 
>> This server is hosting about 6 domains using VHM, but when I ftp into 
>> it, it drops me into one of the virtual host directories no matter 
>> which domain I ftp to.
>>
>> Let me clarify. I'll use example names. I have directory1, directory2 
>> and directory3. They're all setup in the VHM as 
>> *.directory1.com/directory1 and so on. When I FTP to ANY of the 
>> domains, I'm put into directory3. Doesn't matter what 
>> username/password combination that I use. I can log in as the 
>> emergency user and it still puts me in directory3. I can log into 
>> ftp.directory2.com and it will still put me in directory3.
>>
>> I have 3 Zope servers running:
>> Zope 2.6.0 (binary release, python 2.1, linux2-x86), python 2.1.3, linux2
>> RedHat 8.0
>>
>> The other two are running virtual hosts as well, but aren't having 
>> this problem.
> 
> 
> I have the same problem with FTP and VHM. Zope2.6-Head, python2.1.3, 
> Redhat 7.2.
> 
> What happens:
> 
> If I connect via "localhost:8021", the VHM gets "myvirtualserverdomain" 
> as hostname already (I've inserted a "print host" statement to debug). 
> So I think it's not a problem of the VHM-Code, because if the VHM sees 
> "myvirtualserverdomain" as hostname already it should drop me into my 
> virtual directory.
> 
> Maybe it's a ZServer-Bug or something strange with Redhat's resolving of 
> hostnames.
> 
> I'll look deeper into it, but maybe there are others who encounter the 
> same problem... other configs?

Seems to be problem with Redhat configs... My "hostname" was set to 
"www.myvirtualserverdomain.de". ZServer took this one for the FTP-Server 
and VHM recognized a virtual domain, so I wasn't able to see the root of 
my Zope with FTP.

I corrected the "hostname" to "www" and all works fine. Something that 
is strange with ZServer: It uses different methods to get the hostname.

If I start my server with ./start -a 127.0.0.1 ...

the ZSERVER-HTTP-Hostname resolves to localhost (from /etc/hosts),
the ZSERVER-FTP-Hostname resolves to www... (from hostname of server)

I think that the resolving of the ZSERVER-FTP is some kind of a bug...

-mj