Page 3 of 3 FirstFirst 123
Results 21 to 28 of 28

Thread: Install GUI from behind proxy

  1. #21
    Join Date
    Nov 2006
    Location
    Belgium
    Beans
    3,025
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Install GUI from behind proxy

    Quote Originally Posted by lykwydchykyn View Post
    Code:
    unset http_proxy
    that should do it

    Quote Originally Posted by computer_freak_8 View Post
    No! I thought that maybe by logging out, it would reset itself. How do I do this?

    Okay, first, I have to guess. Here are my guesses:
    Code:
    /dev/null > http_proxy
    
    http_proxy < /dev/null
    
    export http_proxy=/dev/null
    
    export http_proxy=$/dev/null
    
    export http_proxy="/dev/null"
    
    export http_proxy="$/dev/null"
    Would any of these work? (My newbie-ness is almost certainly showing...)


    Thanks,
    computer_freak_8
    nice try.
    something like
    Code:
    export http_proxy=""
    would actually have worked.

  2. #22
    Join Date
    Jun 2008
    Location
    Des Moines area (Iowa)
    Beans
    171
    Distro
    Ubuntu

    Wink Re: Install GUI from behind proxy

    lykwydchykyn and koenn:

    Thanks for that. I figured something might be wrong with my syntax...

    As I mentioned in another post in this thread, I will (unfortunately) have to wait until Monday to try this. I really do appreciate the quick responses, though. The more information I'm armed with, the better. At least as I figure it, this way I will have a few different ways to try, and if for some reason they don't work, we can move on with troubleshooting more quickly.


    Thanks again,
    computer_freak_8
    I'm just a geek...

  3. #23
    Join Date
    Jun 2008
    Location
    Des Moines area (Iowa)
    Beans
    171
    Distro
    Ubuntu

    Question Re: Install GUI from behind proxy

    Alright, I unset the http_proxy environmental variable and it still didn't work.

    So, I would like to try and get the proxy going (as was my original goal) and then ditch the Sprint card efforts, since it won't always be there, anyways.

    promodus:
    Is there any way to use your code without entering the username and password?

    I can put the following code into my /etc/bash.bashrc file...
    Code:
    function proxy(){
    echo -n "username:"
    read -e username
    echo -n "password:"
    read -es password
    export http_proxy="http://$username:$password@192.168.xx.xx:80/"
    export ftp_proxy="http://$username:$password@192.168.xx.xx:80/"
    echo -e "\nProxy environmental variables set."
    }
    ...and type "proxy" (without quotes) in a terminal, and it will prompt me for my username and password. So, can I simply substitute ...$username:$password@... where your code shows ...username:password... and have it work correctly?

    Also, I found this code somewhere (can't remember where) to put in /apt/apt.conf to setup the proxy:
    Code:
    Acquire {
    Retries "0";
    HTTP {
    Proxy "http://proxy.url.here:80";
    };
    };
    Can I sub in "$username:$password@" directly before the "proxy.url.here" and have it work?


    Thanks in advance,
    computer_freak_8
    Last edited by computer_freak_8; October 13th, 2008 at 06:56 PM. Reason: Remove private information
    I'm just a geek...

  4. #24
    Join Date
    Nov 2006
    Location
    Belgium
    Beans
    3,025
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Install GUI from behind proxy

    yes for both questions;
    it's usually not considerd good practice to put passwords in scripts like that, but if you want it that way ..

    /apt/apt.conf - probably /etc/apt/apt.conf; and I thought this was already meantioned somewhere in this thread ...

    edit : OK, slightly different syntax
    Last edited by koenn; October 13th, 2008 at 07:54 PM.

  5. #25
    Join Date
    Jun 2008
    Location
    Des Moines area (Iowa)
    Beans
    171
    Distro
    Ubuntu

    Re: Install GUI from behind proxy

    Quote Originally Posted by koenn View Post
    /apt/apt.conf - probably /etc/apt/apt.conf; and I thought this was already meantioned somewhere in this thread ...

    edit : OK, slightly different syntax
    Yes, I meant /etc/apt/apt.conf, not /apt/apt.conf.

    I tried several different things, including exporting the username and password to the respective variables, and I even tried taking out the whole "http://........:80/" and putting in "$http_proxy" instead; still no luck, same 401 error.

    I know it is exporting because I checked it with "echo $http_proxy", "echo $username", et cetera.
    I'm just a geek...

  6. #26
    Join Date
    Jun 2008
    Location
    Des Moines area (Iowa)
    Beans
    171
    Distro
    Ubuntu

    Question Re: Install GUI from behind proxy

    Don't know if this will help anyone to troubleshoot with me, but I noticed something interesting.

    "wget http://us.archive.ubuntu.com/blocked/file/path/here.gz" gives a 407 error. However, I can easily download it from Firefox.

    Any ideas as to why this is? Can I make my terminal appear (to the proxy) to be Firefox? If so, how do I do this?


    Thanks in advance,
    computer_freak_8
    I'm just a geek...

  7. #27
    Join Date
    Nov 2006
    Location
    Belgium
    Beans
    3,025
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Install GUI from behind proxy

    Quote Originally Posted by computer_freak_8 View Post
    Don't know if this will help anyone to troubleshoot with me, but I noticed something interesting.

    "wget http://us.archive.ubuntu.com/blocked/file/path/here.gz" gives a 407 error. However, I can easily download it from Firefox.

    Any ideas as to why this is? Can I make my terminal appear (to the proxy) to be Firefox? If so, how do I do this?


    Thanks in advance,
    computer_freak_8
    most likely because FF is configured to use a proxy, wget isn't, and you can't get direct internet access because of a firewall somewhere.

    wget has an option to set a proxy (man wget for syntax), you could see if that helps.

  8. #28
    Join Date
    Jun 2008
    Location
    Des Moines area (Iowa)
    Beans
    171
    Distro
    Ubuntu

    Question Re: Install GUI from behind proxy

    Quote Originally Posted by koenn View Post
    most likely because FF is configured to use a proxy, wget isn't, and you can't get direct internet access because of a firewall somewhere.

    wget has an option to set a proxy (man wget for syntax), you could see if that helps.
    Thanks for that, but I'm still confused then: I have configured the environmental variable "http_proxy" as well as "/etc/apt/apt.conf", and it still won't use a proxy - just like wget won't.

    I mean, it makes sense for wget to be giving me errors (if it doesn't see "http_proxy"), but it doesn't make sense for apt-get to be giving me errors.

    Yes, Firefox is configured to use a proxy. I had to go into "Edit" --> "Preferences" to make it that way. How do I get my CLI programs to use the proxy?

    Now, it's obvious that my proxy doesn't block the packages; they go through just fine in Firefox. So it is something with the authentication. (I think.)

    Is there some way to get the CLI programs - especially apt-get - to prompt me for my authentication as needed, like Firefox does? Maybe this would solve my problem...
    I'm just a geek...

Page 3 of 3 FirstFirst 123

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •