• 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31

基本はstableで使いつつ、ちょっと使ってみたい新しい
パッケージがある場合だけ、unstableから持ってくるような使い方を
する場合のaptの設定メモ。

まずはsources.listにunstableを追加。

/etc/apt/sources.list

pre>>
deb http://cdn.debian.or.jp/debian/ etch main contrib non-free
deb-src http://cdn.debian.or.jp/debian/ etch main contrib non-free

deb http://security.debian.org/ etch/updates main contrib
deb-src http://security.debian.org/ etch/updates main contrib

deb http://cdn.debian.or.jp/debian/ unstable main contrib non-free
deb-src http://cdn.debian.or.jp/debian/ unstable main contrib non-free
<<--

それがすんだら、優先度の設定を行います。

/etc/apt/preferences

pre>>
Package: *
Pin: release a=stable
Pin-Priority: 100

Package: *
Pin: release a=stable-proposed-updates
Pin-Priority: 110

Package: *
Pin: release a=unstable
Pin-Priority: 90
<<--

ついでに、キャッシュ容量の設定なども行っておきましょう。

/etc/apt/apt.conf

pre>>
APT::Cache-Limit "100000000";
APT::Default-Release "stable";
<<--

上記の設定ファイルファイルが無い場合は、新しく作成します。

これで完了。あとはapt-get updateすればOK。
必要に応じて、-t unstable オプションを指定して unstableの
パッケージを利用できます。

posted by genki genki on Sat 8 Dec 2007 at 07:35 with 0 comments