para uso com o apt 1.2 no Ubuntu 16.04 com repositório local você precisa remover este arquivo:
/etc/apt/apt.conf.d/50appstream
usando:
sudo rm /etc/apt/apt.conf.d/50appstream
Eu tenho repositório local de xenial no diretório /CDs/ubuntu
. Meu arquivo sources.list:
deb file:/CDs/ubuntu xenial main restricted universe multiverse
Resultados da atualização:
#apt-get update
Get:1 file:/CDs/ubuntu xenial InRelease
Ign:1 file:/CDs/ubuntu xenial InRelease
Get:2 file:/CDs/ubuntu xenial Release [246 kB]
Get:2 file:/CDs/ubuntu xenial Release [246 kB]
Get:3 file:/CDs/ubuntu xenial Release.gpg [933 B]
Get:3 file:/CDs/ubuntu xenial Release.gpg [933 B]
Get:4 file:/CDs/ubuntu xenial/main amd64 Packages
Ign:4 file:/CDs/ubuntu xenial/main amd64 Packages
Get:5 file:/CDs/ubuntu xenial/main i386 Packages
Ign:5 file:/CDs/ubuntu xenial/main i386 Packages
Get:6 file:/CDs/ubuntu xenial/main Translation-en
Ign:6 file:/CDs/ubuntu xenial/main Translation-en
Get:7 file:/CDs/ubuntu xenial/main amd64 DEP-11 Metadata
Ign:7 file:/CDs/ubuntu xenial/main amd64 DEP-11 Metadata
Get:8 file:/CDs/ubuntu xenial/main DEP-11 64x64 Icons
Ign:8 file:/CDs/ubuntu xenial/main DEP-11 64x64 Icons
Get:9 file:/CDs/ubuntu xenial/restricted amd64 Packages
Ign:9 file:/CDs/ubuntu xenial/restricted amd64 Packages
Get:10 file:/CDs/ubuntu xenial/restricted i386 Packages
Ign:10 file:/CDs/ubuntu xenial/restricted i386 Packages
Get:11 file:/CDs/ubuntu xenial/restricted Translation-en
Ign:11 file:/CDs/ubuntu xenial/restricted Translation-en
Get:12 file:/CDs/ubuntu xenial/restricted amd64 DEP-11 Metadata
Ign:12 file:/CDs/ubuntu xenial/restricted amd64 DEP-11 Metadata
Get:13 file:/CDs/ubuntu xenial/universe amd64 Packages
Ign:13 file:/CDs/ubuntu xenial/universe amd64 Packages
Get:14 file:/CDs/ubuntu xenial/universe i386 Packages
Ign:14 file:/CDs/ubuntu xenial/universe i386 Packages
Get:15 file:/CDs/ubuntu xenial/universe Translation-en
Ign:15 file:/CDs/ubuntu xenial/universe Translation-en
Get:16 file:/CDs/ubuntu xenial/universe amd64 DEP-11 Metadata
Ign:16 file:/CDs/ubuntu xenial/universe amd64 DEP-11 Metadata
Get:17 file:/CDs/ubuntu xenial/universe DEP-11 64x64 Icons
Ign:17 file:/CDs/ubuntu xenial/universe DEP-11 64x64 Icons
Get:18 file:/CDs/ubuntu xenial/multiverse amd64 Packages
Ign:18 file:/CDs/ubuntu xenial/multiverse amd64 Packages
Get:19 file:/CDs/ubuntu xenial/multiverse i386 Packages
Ign:19 file:/CDs/ubuntu xenial/multiverse i386 Packages
Get:20 file:/CDs/ubuntu xenial/multiverse Translation-en
Ign:20 file:/CDs/ubuntu xenial/multiverse Translation-en
Get:21 file:/CDs/ubuntu xenial/multiverse amd64 DEP-11 Metadata
Ign:21 file:/CDs/ubuntu xenial/multiverse amd64 DEP-11 Metadata
Get:22 file:/CDs/ubuntu xenial/multiverse DEP-11 64x64 Icons
Ign:22 file:/CDs/ubuntu xenial/multiverse DEP-11 64x64 Icons
Get:4 file:/CDs/ubuntu xenial/main amd64 Packages [1,201 kB]
Ign:4 file:/CDs/ubuntu xenial/main amd64 Packages
Get:5 file:/CDs/ubuntu xenial/main i386 Packages [1,196 kB]
Ign:5 file:/CDs/ubuntu xenial/main i386 Packages
Get:6 file:/CDs/ubuntu xenial/main Translation-en [568 kB]
Ign:6 file:/CDs/ubuntu xenial/main Translation-en
Get:7 file:/CDs/ubuntu xenial/main amd64 DEP-11 Metadata [733 kB]
Ign:7 file:/CDs/ubuntu xenial/main amd64 DEP-11 Metadata
Get:8 file:/CDs/ubuntu xenial/main DEP-11 64x64 Icons [409 kB]
Ign:8 file:/CDs/ubuntu xenial/main DEP-11 64x64 Icons
Get:9 file:/CDs/ubuntu xenial/restricted amd64 Packages [8,344 B]
Ign:9 file:/CDs/ubuntu xenial/restricted amd64 Packages
Get:10 file:/CDs/ubuntu xenial/restricted i386 Packages [8,684 B]
Ign:10 file:/CDs/ubuntu xenial/restricted i386 Packages
Get:11 file:/CDs/ubuntu xenial/restricted Translation-en [2,908 B]
Ign:11 file:/CDs/ubuntu xenial/restricted Translation-en
Get:12 file:/CDs/ubuntu xenial/restricted amd64 DEP-11 Metadata [186 B]
Ign:12 file:/CDs/ubuntu xenial/restricted amd64 DEP-11 Metadata
Get:13 file:/CDs/ubuntu xenial/universe amd64 Packages [7,532 kB]
Ign:13 file:/CDs/ubuntu xenial/universe amd64 Packages
Get:14 file:/CDs/ubuntu xenial/universe i386 Packages [7,512 kB]
Ign:14 file:/CDs/ubuntu xenial/universe i386 Packages
Get:15 file:/CDs/ubuntu xenial/universe Translation-en [4,354 kB]
Ign:15 file:/CDs/ubuntu xenial/universe Translation-en
Get:16 file:/CDs/ubuntu xenial/universe amd64 DEP-11 Metadata [3,410 kB]
Ign:16 file:/CDs/ubuntu xenial/universe amd64 DEP-11 Metadata
Get:17 file:/CDs/ubuntu xenial/universe DEP-11 64x64 Icons [7,448 kB]
Ign:17 file:/CDs/ubuntu xenial/universe DEP-11 64x64 Icons
Get:18 file:/CDs/ubuntu xenial/multiverse amd64 Packages [144 kB]
Ign:18 file:/CDs/ubuntu xenial/multiverse amd64 Packages
Get:19 file:/CDs/ubuntu xenial/multiverse i386 Packages [140 kB]
Ign:19 file:/CDs/ubuntu xenial/multiverse i386 Packages
Get:20 file:/CDs/ubuntu xenial/multiverse Translation-en [106 kB]
Ign:20 file:/CDs/ubuntu xenial/multiverse Translation-en
Get:21 file:/CDs/ubuntu xenial/multiverse amd64 DEP-11 Metadata [63.8 kB]
Ign:21 file:/CDs/ubuntu xenial/multiverse amd64 DEP-11 Metadata
Get:22 file:/CDs/ubuntu xenial/multiverse DEP-11 64x64 Icons [230 kB]
Ign:22 file:/CDs/ubuntu xenial/multiverse DEP-11 64x64 Icons
Get:4 file:/CDs/ubuntu xenial/main amd64 Packages [1,558 kB]
Get:5 file:/CDs/ubuntu xenial/main i386 Packages [1,552 kB]
Get:6 file:/CDs/ubuntu xenial/main Translation-en [799 kB]
Ign:6 file:/CDs/ubuntu xenial/main Translation-en
Get:7 file:/CDs/ubuntu xenial/main amd64 DEP-11 Metadata [2,189 kB]
Err:7 file:/CDs/ubuntu xenial/main amd64 DEP-11 Metadata
File not found - /CDs/ubuntu/dists/xenial/main/dep11/Components-amd64.yml (2: No such file or directory)
Get:8 file:/CDs/ubuntu xenial/main DEP-11 64x64 Icons [481 kB]
Err:8 file:/CDs/ubuntu xenial/main DEP-11 64x64 Icons
File not found - /CDs/ubuntu/dists/xenial/main/dep11/icons-64x64.tar (2: No such file or directory)
Reading package lists... Done
E: Failed to fetch file:/CDs/ubuntu/dists/xenial/main/dep11/Components-amd64.yml File not found - /CDs/ubuntu/dists/xenial/main/dep11/Components-amd64.yml (2: No such file or directory)
E: Failed to fetch file:/CDs/ubuntu/dists/xenial/main/dep11/icons-64x64.tar File not found - /CDs/ubuntu/dists/xenial/main/dep11/icons-64x64.tar (2: No such file or directory)
E: Some index files failed to download. They have been ignored, or old ones used instead.
Em /var/lib/apt/lists
, não tenho nada. Apenas informações parciais no diretório partial
:
#/var/lib/apt/lists/partial# ls -l
total 7308
-rw-r--r-- 1 root root 7228243 Apr 22 09:37 _CDs_ubuntu_dists_xenial_main_binary-amd64_Packages
lrwxrwxrwx 1 root root 54 May 13 10:25 _CDs_ubuntu_dists_xenial_main_binary-amd64_Packages.gz -> /CDs/ubuntu/dists/xenial/main/binary-amd64/Packages.gz
lrwxrwxrwx 1 root root 53 May 13 10:25 _CDs_ubuntu_dists_xenial_main_binary-i386_Packages.gz -> /CDs/ubuntu/dists/xenial/main/binary-i386/Packages.gz
-rw-r--r-- 1 root root 245864 Apr 22 11:24 _CDs_ubuntu_dists_xenial_Release
-rw-r--r-- 1 root root 933 Apr 22 11:24 _CDs_ubuntu_dists_xenial_Release.gpg
O problema pode ser resolvido apenas por downgrade para o apt 1.1 de trusty
.
Além disso, o novo apt-get update
tenta alterar os direitos dos arquivos que ele armazena como links simbólicos em /var/lib/apt/list
. Por exemplo, ele altera os direitos de acesso do arquivo:
/CDs/ubuntu/dists/xenial/main/binary-amd64/Packages.gz
Alguma sugestão de como usar o apt 1.2 no Ubuntu 16.04 com repositório local?
para uso com o apt 1.2 no Ubuntu 16.04 com repositório local você precisa remover este arquivo:
/etc/apt/apt.conf.d/50appstream
usando:
sudo rm /etc/apt/apt.conf.d/50appstream
Para mim, sozinho, excluindo
/etc/apt/apt.conf.d/50appstream
não funcionou, porque eu havia baixado somente os pacotes amd64
. Para fazê-lo funcionar, eu adicionei a arquitetura ao sources.list
lines
deb [arch=amd64] file:/wherever xenial main restricted universe multiverse
...etc.
Depois de fazer isso apt-get update
funcionou bem.
Eu tive o mesmo problema, tentei corrigir esse problema
sudo rm /etc/apt/apt.conf.d/50appstream
Mas não funcionou para mim. Estou vermelho sobre um possível bug sobre aqui
De qualquer forma, eu acho uma alternativa e funciona muito bem para mim
Eu abro o diretório onde tenho meu repositório e executo o seguinte comando:
python -m SimpleHTTPServer <port>
é uma maneira fácil de iniciar um servidor web em qualquer pasta que você possa ver em Como iniciar facilmente um servidor web em qualquer pasta?
Então, agora você pode usar o seu sources.list como quando você usa o repositório por http. Por exemplo, no meu caso eu uso o por 8585 e este é o meu sources.list
deb http://localhost:8585/ xenial main multiverse restricted universe
deb http://localhost:8585/ xenial-backports main multiverse restricted universe
deb http://localhost:8585/ xenial-proposed main multiverse restricted universe
deb http://localhost:8585/ xenial-security main multiverse restricted universe
deb http://localhost:8585/ xenial-updates main multiverse restricted universe
É uma solução rápida, tenho certeza que existem outras soluções mais strongs.
Tags apt