wget inside jail not working

Discussion in 'ISPConfig 3 Priority Support' started by millpark10, Mar 29, 2014.

  1. millpark10

    millpark10 Member

    Hi when trying this:
    Code:
    varnisshell@example.org:/web/test$ wget example.org
    --2014-03-28 23:37:40--  http://example.org/
    Resolving example.org (example.org)... xxx.xxx.105.178
    Connecting to example.org (example.org)|xxx.xxx.105.178|:80... failed: Connection refused
    it fails as you can see.
    This is run from commandline inside jailkit. Is it depending on a local DNS? If not, what are we doing wrong? Workaround?
    //millpark10
     
    Last edited: Mar 29, 2014
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes, most likely a part of the dns resolving system is missing. We fixed something in the beta, you can try to fix it manually for this jail to see id it works then. Copy the files:

    /lib/x86_64-linux-gnu/libnss*.so.2

    from your system into the same folder in the jail.
     
  3. millpark10

    millpark10 Member

    Hi Till
    The files/links seem to already be installed in jail.
    Code:
     :/var/www/clients/client3/web5# jk_cp -j /var/www/clients/client3/web5/ -v /lib/x86_64-linux-gnu/libnss*.so.2
    Creating symlink /var/www/clients/client3/web5/lib/x86_64-linux-gnu/libnss_compat.so.2 to libnss_compat-2.15.so
    /var/www/clients/client3/web5/lib/x86_64-linux-gnu/libnss_compat-2.15.so already exists, will not touch it
    /var/www/clients/client3/web5/lib/x86_64-linux-gnu/libnsl.so.1 already exists, will not touch it
    /var/www/clients/client3/web5/lib/x86_64-linux-gnu/libc.so.6 already exists, will not touch it
    /var/www/clients/client3/web5/lib64/ld-linux-x86-64.so.2 already exists, will not touch it
    ....plus more...
    
    I am not running a local DNS on the mirrored servers. Do I have to in order to get wget to work? (I am using external DNS for name resolution)
    //millpark10
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    DNS on the mirrors is not nescessary, just set correct dns servers in /etc/resolv.conf. I just reread your post above, it seems more that the tec connection is blocked, as the message:

    Resolving example.org (example.org)... xxx.xxx.105.178
    Connecting to example.org (example.org)|xxx.xxx.105.178|:80... failed: Connection refused

    shows an ip address, so the dns resolution worked but something is blocking the connections.
     
  5. millpark10

    millpark10 Member

    Till
    As usual you are right, no problem with name resolution, the name is resolved by external DNS, and it is done correctly.
    Code:
    :/var/www/clients/client5/web7# cat /etc/resolv.conf 
    # Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
    #     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
    nameserver 8.8.8.8
    nameserver 8.8.4.4
    The DNS entry points, correctly, to my ispconfig servers external IPaddress. As I understand, wget tries to connect to that IP.
    But the server to connect to is a named virtual server within ISPconfig.
    We need the FQDname to be "passed on" to connect. I think?
    (Not sure if I am using an understandable language here)
    //millpark10
     

Share This Page