大家好新年快乐
最近,我已经从debian backport源码中构build了nginx deb软件包v1.4.4,当然我已经添加到apt sources.list中,事情变得非常好。
我的问题: 请问debian会自动更新自己从官方源代码构build的软件包吗? 我的意思是通过更新安全的。
更新:
我已经运行apt-get update然后今天apt-get -V upgrade来检查如何debian 7 apt将performance..这就是我得到的:
root@debian-lab:~/nginx-1.4.4-packages# apt-get -V upgrade Reading package lists... Done Building dependency tree Reading state information... Done The following packages will be upgraded: nginx-full (1.4.4-1~bpo70+1 => 1.4.4-1~bpo70+1) 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Need to get 0 B/464 kB of archives. After this operation, 9,027 kB disk space will be freed. Do you want to continue [Y/n]?
正如你所看到的,apt正在尝试从(1.4.4-1〜bpo70 + 1 => 1.4.4-1〜bpo70 + 1)升级,这基本上是两个相同的版本,但我安装的deb软件包中添加了自定义的nginx模块到默认nginx-full和更新后,我的自定义模块都没有了,被标准的debian wheezy backport deb取代..我已经从debian backport源码构build了我的nginx backport deb包,并通过backport安装了build-deb但是一些依赖从stable中自动安装,这是我从verbose输出中看到的。
你能帮我防止这个例子吗?
UPDATE
我已经尝试了封装,并没有工作,这里是我得到的输出:
apt-cache policy nginx-full nginx-full: Installed: 1.4.4-1~bpo70+1 Candidate: 1.4.4-1~bpo70+1 Version table: 1.4.4-1~bpo70+1 0 100 http://ftp.uk.debian.org/debian/ wheezy-backports/main amd64 Packages *** 1.4.4-1~bpo70+1 0 100 /var/lib/dpkg/status 1.2.1-2.2+wheezy2 0 500 http://ftp.uk.debian.org/debian/ wheezy/main amd64 Packages 500 http://security.debian.org/ wheezy/updates/main amd64 Packages
以下是apt-cache策略nginx:
/etc/apt/preferences.d# apt-cache policy nginx nginx: Installed: 1.4.4-1~bpo70+1 Candidate: 1.4.4-1~bpo70+1 Package pin: 1.4.4-1~bpo70+1 Version table: *** 1.4.4-1~bpo70+1 1001 100 http://ftp.uk.debian.org/debian/ wheezy-backports/main amd64 Packages 100 /var/lib/dpkg/status 1.2.1-2.2+wheezy2 1001 500 http://ftp.uk.debian.org/debian/ wheezy/main amd64 Packages 500 http://security.debian.org/ wheezy/updates/main amd64 Packages
但仍然是正在尝试升级和更换!
Sources.list内容:
deb http://ftp.uk.debian.org/debian/ wheezy main deb-src http://ftp.uk.debian.org/debian/ wheezy main deb http://security.debian.org/ wheezy/updates main deb-src http://security.debian.org/ wheezy/updates main # wheezy-updates, previously known as 'volatile' deb http://ftp.uk.debian.org/debian/ wheezy-updates main deb-src http://ftp.uk.debian.org/debian/ wheezy-updates main # Wheezy Backports repository deb http://ftp.uk.debian.org/debian wheezy-backports main deb-src http://ftp.uk.debian.org/debian wheezy-backports main
我已经尝试了一次封装名称'nginx',而另一次使用nginx-full。
但都没有拿着包!
我会build议你打包的版本。 APT知道这两个软件包是不一样的,并试图从可信来源安装软件包。 dch -i就是你所需要的,只需添加一些简短的描述并重新构build包。
您也可以以不同的方式固定包装:
Package: nginx-full Pin: origin "" Pin-Priority: 999
这将给予本地安装的软件包更多的优先权。
如果存储库版本string取代了当前安装的版本,并且没有任何固定并且某个版本被发布,那么apt会从存储库安装软件包(希望已经应用了补丁),如果你有正确的源代码的话。
如果你固定这个包,apt-get将不会尝试升级它。
要固定这个包,在/etc/apt/preferences.d中创build一个文件,例如/etc/apt/preferences.d/nginx
把这个放在文件中:
Package: nginx Pin: version 1.4.4-1~bpo70+1 Pin-Priority: 1001