0

as written here, I should put this lines:

deb mirror://mirrors.ubuntu.com/mirrors.txt precise main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt precise-updates main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt precise-backports main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt precise-security main restricted universe multiverse

on the top in my /etc/apt/sources.list file, and this should be all that is needed to make it automatically pick a mirror for me based on my geographical location.

because the file sources.list is read-only, what should I do?
tried
$ sudo mount -o rw,remount /etc/apt/sources.list
but it wasn't found..

Tzahi Leh
  • 281

2 Answers2

3

Let's check the default permission of /etc/apt/sources.list:

-rw-rw-r-- 1 root root 2563 Aug 21 04:24 /etc/apt/sources.list 

As you can see only user root and the members of group root can write to the file, all other users while trying to edit the file will get a message saying that the file is read only for them.

To edit the file, just use sudo to impersonate root e.g. using nano :

sudo nano /etc/apt/sources.list

or gedit:

sudo -H gedit /etc/apt/sources.list
heemayl
  • 93,925
1

You do not have yo edit the /etc/apt/sources.list manually.

You can go to System Settings -> Software & Updates and setup your mirror there in GUI. It is "Download from" drop down menu.

Pilot6
  • 92,041