Re: HOSTALIASES variable not being checked

From: Vineet Kumar (vineet_at_doorstop.net)
Date: 12/30/04

  • Next message: Thomas Weber: "Samba and Unix Password Sync"
    Date: Thu, 30 Dec 2004 02:30:11 -0800
    To: debian-user@lists.debian.org
    
    
    

    * Matt Perry (matt@primefactor.com) [041230 01:30]:
    > >From reading the man page for gethostbyname(3) I see that I can set
    > the environment variable HOSTALIASES to point to a file with local
    > aliases. When I do that, it doesn't seem to be working.
    >
    > $ cat hostalias
    > deb ftp.debian.org
    >
    > $ export HOSTALIASES=$HOME/hostalias
    >
    > $ ftp deb
    > ftp: deb: Name or service not known
    >
    > Has anyone gotten HOSTALIASES to work properly? I'm running sarge.

    Works for me here:

    vineet@sprocket:~$ echo "foo google.com" > hostalias
    vineet@sprocket:~$ export HOSTALIASES=$HOME/hostalias
    vineet@sprocket:~$ echo "GET / HTTP/1.0
    ^M
    ^M" | nc foo 80 | head
    HTTP/1.0 200 OK
    Cache-Control: private
    Content-Type: text/html
    Set-Cookie: PREF=ID=03c0d2281eda6f75:TM=1104402356:LM=1104402356:S=jkhUw7L5KYF4vGXQ; expires=Sun, 17-Jan-2038 19:14:07 GMT; path=/; domain=.google.com
    Server: GWS/2.1
    Date: Thu, 30 Dec 2004 10:25:56 GMT
    Connection: Close

    <html><head><meta http-equiv="content-type" content="text/html;
    charset=ISO-8859-1"><title>Google</title><style><!--
    body,td,a,p,.h{font-family:arial,sans-serif;}
    vineet@sprocket:~$

    try strace to see what ftp is doing wrong. My ftp does the right thing,
    too.

    good times,
    Vineet

    -- 
    http://www.doorstop.net/
    -- 
    If Haydn had patented "a symphony, characterised by that sound is produced
    [ in extended sonata form ]", Mozart would have been in trouble.
    http://swpat.ffii.org
    
    

    -- 
    To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org 
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
    


  • Next message: Thomas Weber: "Samba and Unix Password Sync"