Dos_Box Posted May 15, 2008 Posted May 15, 2008 Can someone write me a quick set of instructions on how to set the system proxy setting (not the Internet proxy in Firefox!) using the terminal (ctrl-alt-t) as we need to let school staff know how to do this to allow them to install software and updates etc. Or a script may be better, but we would still need instructions on how to run it etc.
plexer Posted May 15, 2008 Posted May 15, 2008 The “http_proxy” environment variable - Setup proxy setting in a linux machine. « This is me… Like that? Ben
Dos_Box Posted May 15, 2008 Author Posted May 15, 2008 OK. I'm a Linux dummy. Where and how do you set it. A simple line of text doesn't reveal much!
jamesb Posted May 15, 2008 Posted May 15, 2008 Go into the command-line, and type the text as described. If you need authentication though you'll need to make it: $export http_proxy="http://:@:/" That'll need to be done each time the machine is restarted, though you can edit /home/username/.bashrc to include the line.
kmount Posted May 15, 2008 Posted May 15, 2008 Make sure you don't put the dollar in. It should just be: export http_proxy="http://proxy.embc.uk.com:80" export ftp_proxy="ftp://proxy.embc.uk.com:80"
jamesb Posted May 15, 2008 Posted May 15, 2008 Just pulled out my own EEE PC now and working through it. I'll note down as I go. Ctrl-Alt-T to pull up the terminal. This puts you into your home directory. Type "vi .bashrc" Once in the bashrc file scroll down to the end of the file, then along to the last character on that line. Press 'a'. Press enter to move to a new line, then again so you've got a little space to work. Type '# Proxy settings for ' Press enter. Type 'http_proxy="http://<:password>@<:port>/"' Press enter. Type 'export http_proxy' Press Esc. Type :wq to save the file and quit vi. Should then be held there and automatically export the variable each time. Hopefully that'll do what you want, its working on mine at least. Do not type any of the single quotes, but you do need the double quotes around the proxy address.
Dos_Box Posted May 15, 2008 Author Posted May 15, 2008 Ah! No. The command seems to have worked but when I use the 'Add\Remove' programs applet I get 'Unmet dependencies. Try 'apt-get -f install' with no packages' errors
Geoff Posted May 15, 2008 Posted May 15, 2008 If you want this setting to stick, your best adding it to the bottom of /etc/profile. I've written before about where to set proxy settings on Linux machines. So you might want to read that post here: http://www.edugeek.net/forums/nix/7519-apt-get-proxy.html#post77088
Dos_Box Posted May 15, 2008 Author Posted May 15, 2008 You have to take on board the fact that these instructions are going to be for teachers and will need to be simple (covering up the fact they are also for me and need to be simple!).
Dos_Box Posted May 15, 2008 Author Posted May 15, 2008 Ah. Hang on. We've been setting the http proxy. What does apt-get use? We need to be setting that to use the add\remove programs applet I think!
kmount Posted May 15, 2008 Posted May 15, 2008 Apt-get uses the http/ftp proxy details if ran from the command line, but I think Synaptic uses a different set. Shall locate the eeepc now.
SimpleSi Posted May 15, 2008 Posted May 15, 2008 @geoff problems are no /etc/profile on eeePC no /etc/apt/apt.conf file (there is a /etc/apt/apt.conf.d folder but I don't think that has anything to do with this???) Do we just create them? regards Simon @Chris - I hadn't put any thing in the wiki as I couldn't work out where to stick the lines and when I tried updating something once I just took the machine home instead and did it from there Even if we come up with the settings and the files - i think it will be awkward for people to switch from home/work unless someone writes a switcher program
Dos_Box Posted May 15, 2008 Author Posted May 15, 2008 Well, I've got 135 EeePCs sat in and around my office all going out to schools in class sets and I really need to get something sorted soon! Anyone care to do a small EduGeek project for this. It would be very popular worldwide!
Jona Posted May 15, 2008 Posted May 15, 2008 Have you confirmed that apt-get works from the command line and it's just Synaptic that is having proxy issues?? In terms of switching proxy it should be quite easy to shell script, provided everything takes it's settings from the http_proxy environment variable, the only tricky bit if you want to fully automate it is how to detect if an eeepc is in school or at home...... Jona
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now