Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am trying to install unzip and vsftpd on my lamp server on my aws instance, but attempting to install anything results in the following error:

$ sudo apt-get install vsftpd
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following NEW packages will be installed:
  vsftpd
0 upgraded, 1 newly installed, 0 to remove and 82 not upgraded.
Need to get 111 kB of archives.
After this operation, 361 kB of additional disk space will be used.
Err http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/ trusty-updates/main vsftpd amd64 3.0.2-1ubuntu2.14.04.1
  Could not resolve 'ap-southeast-1.ec2.archive.ubuntu.com'
E: Failed to fetch http://ap-southeast-1.ec2.archive.ubuntu.com/ubuntu/pool/main/v/vsftpd/vsftpd_3.0.2-1ubuntu2.14.04.1_amd64.deb  Could not resolve 'ap-southeast-1.ec2.archive.ubuntu.com'

E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

I've tried apt-get update and --fix-missing but still unable to install anything new.

The version details are as follows:

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04 LTS
Release:    14.04
Codename:   trusty
share|improve this question
    
Could not resolve 'ap-southeast-1.ec2.archive.ubuntu.com' is self explanatory. –  dawud Jul 17 '14 at 10:44
    
Not to me. That's the error I understand, but how to resolve it is something I have no idea about. –  Aayush Jul 17 '14 at 10:51
    
can I change the download mirror in ubuntu? –  Aayush Jul 17 '14 at 10:53

2 Answers 2

You can try below

1.) launch instances with user data like:

cloud-config

apt_mirror: http://us.archive.ubuntu.com/ubuntu/

The above will allow other portions of cloud-config that assume apt is set up properly to work.

Then try apt-get update & apt-get install

share|improve this answer
    
I'm not sure what that means? Will I have to launch a new instance. Is it not possible to change the apt_mirror to what you have mentioned? –  Aayush Jul 17 '14 at 10:54
    
Yes changing mirror will do. –  ganeshragav Jul 17 '14 at 10:57

I'm not sure if doing this is the right way to do this, but I got it working by changing the apt-get mirrors in /etc/apt/sources.list to http://us.archive.ubuntu.com/ubuntu/ but I made a backup of the file just in case.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.