雑記 日記帳 構想として、中古PCにジェンツーペンギン。part6 別館 これはダブリ部分が有るのでNGな出来だったような気がする。
結果として、失敗の作業なので読む必要は有りません。自分用メモです。
これが大本でしたがhatenaに書き込んで表示したら、何故かcopyされてダブリの部分が多々有るので、他を作っての時の参考の為保存です。頭が痛い。
あまり長い物は良く無いようで、対策として短めに分けて書く。
構想として。
中古PCにジェンツーペンギン。part6
では、ジェンツーペンギンのwikiには今どのように書いて有るのか?を調べて見ると、
Handbook:AMD64
https://wiki.gentoo.org/wiki/Handbook:AMD64
Preparing the disks
https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Disks
Safe CFLAGS
https://wiki.gentoo.org/wiki/
Gentooのインストールファイルのインストール
ハンドブック:AMD64
などより
パーティションの設定を済ませて では無いような説明のようです。
google翻訳でhttpを見て下さい。
nano -w
はnano で作業予定。
On ext2,
root #
mke2fs -T small /dev/<device>
root #
mke2fs -j -T small /dev/<device>
root #
mkfs.ext2 /dev/sda2
root #
mkfs.ext4 /dev/sda4
root #
mkswap /dev/sda3
root #
swapon /dev/sda3 <ーー私の場合はここから、多分。
root #
mount /dev/sda4 /mnt/gentoo
root #
mkdir /mnt/gentoo/boot
root #
mount /dev/sda2 /mnt/gentoo/boot
ここからが作業の開始です。
キーボードは22のjapanを選択する。
作成したファイルシステムをマウント
# mount /dev/sda27 /mnt/gentoo/
# mkdir /mnt/gentoo/boot
# mount /dev/sda20 /mnt/gentoo/boot
# swapon /dev/sda5
# date <ーーーー単なる確認。
# tar xvjpf stage3-*.tar.bz2 --xattrs
でいいのでは?と思う。下記も参考にして。root #
date
root #
date 032916212014
root #
cd /mnt/gentoo
root #
openssl dgst -r -sha512 stage3-amd64-<release>.tar.bz2
root #
sha512sum stage3-amd64-<release>.tar.bz2
root #
openssl dgst -r -whirlpool stage3-amd64-<release>.tar.bz2
root #
nano -w /mnt/gentoo/etc/portage/make.conf
<ーー -wは面倒なのでしない。なので
CFLAGS="-march=native -O2 -pipe" <ーー安全策でこれにする。
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
# Use the same settings for both variables
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j2" ここは
MAKEOPTS="-j5" にする。
Installing the Gentoo base system.
Warningを読むと下記2行は不要。root #
mirrorselect -i -o >> /mnt/gentoo/etc/portage/make.conf
root #
mirrorselect -i -r -o >> /mnt/gentoo/etc/portage/make.conf
root #
cp -L /etc/resolv.conf /mnt/gentoo/etc/
必要なファイルを更新して chroot でインストール環境に入ります。
# mount --rbind /dev/ dev/
root #
mount -t proc proc /mnt/gentoo/proc
root #
mount --rbind /sys /mnt/gentoo/sys
root #
mount --make-rslave /mnt/gentoo/sys
root #
mount --rbind /dev /mnt/gentoo/dev
root #
mount --make-rslave /mnt/gentoo/dev
root #
chroot /mnt/gentoo /bin/bash
root #
source /etc/profile
root #
export PS1="(chroot) $PS1"
root #
emerge-webrsync
<ーーこれは1年前では無かった。root #
emerge --sync
root #
eselect news list
root #
eselect news read
root #
man news.eselect
root #
eselect profile set 2
<ーー1年前では3だったが2に変わっている。In order to select a pure 64-bit environment,
with no 32-bit applications or libraries, use a non-multilib profile:
[5] default/linux/amd64/13.0/no-multilib なので 5 は絶対に選択しない。
root #
emerge --info | grep ^USE
USE="X acl alsa amd64 berkdb bindist bzip2 cli cracklib crypt cxx dri ..."
A full description on the available USE flags can be found on the system in /usr/portage/profiles/use.desc.
root #
less /usr/portage/profiles/use.desc
root #
nano -w /etc/portage/make.conf
なんとhi-hoのインストールの仕方は上2行のような感じ。
hi-hoは複製・転載は禁止します。との事です。root #
emerge --config sys-libs/timezone-data
Configure locales ここは絶対に合っていると思う。root #
nano -w /etc/locale.gen
en_US.UTF-8 UTF-8
ja_JP.UTF-8 UTF-8root #
locale-gen
root #
env-update && source /etc/profile
For Intel Core i7 CPU users or those having econf error during install (with the current 2012.1 release of Gentoo which ships with GCC 4.5.3 compiler) it is recommended to begin your install with the -march=core2 flag to generate a base install against GCC 4.5.3, then later you can upgrade GCC to 4.6.3 or newer in order to support the new -march=corei7 flag. Below is the recommended setting to begin with for Core i7 users:
CFLAGS="-march=core2 -O2 -pipe" CXXFLAGS="${CFLAGS}"
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
MAKEOTS="-j5" ここは MAKEOTS="-j9" が正解なのかも知れない
ソース2より上記かな?
https://wiki.gentoo.org/wiki/CFLAGS
Configuring the Linux kernel 段々と疲労してやる気がなく成りつつ有ります。
root #
emerge --ask sys-kernel/gentoo-sources
genkernel
を使用する。kernelのbuildの方のやり方は採用しない。root #
emerge genkernel
root #
genkernel --install initramfs
root #
emerge --ask sys-kernel/genkernel
root #
nano -w /etc/fstab
/dev/sda2 /boot ext2 defaults 0 2
root #
genkernel all
root #
ls /boot/kernel* /boot/initramfs*
Configuring the modules
root #
find /lib/modules/<kernel version>/ -type f -iname '*.o' -or -iname '*.ko' | less
root #
nano -w /etc/conf.d/modules
root #
emerge --ask sys-kernel/linux-firmware
root #
nano -w /etc/fstab
# nano /etc/fstab
/dev/sda20 /boot ext4 noauto,noatime 1 2
/dev/sda27 / ext4 noatime 0 1
/dev/sda5 none swap sw 0 0
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
#/dev/fd0 /mnt/floppy auto noauto 0 0 <ーーー#を付加した。
Host and domain information
root #
nano -w /etc/conf.d/hostname
root #
emerge --ask --noreplace net-misc/netifrc
To use DHCP, define config_eth0
:
config_eth0="dhcp"
Please read /usr/share/doc/netifrc-*/net.example.bz2 for a list of all available options. Be sure to also read up on the DHCP client man page if specific DHCP options need to be set.
If the system has several network interfaces, then repeat the above steps for config_eth1
, config_eth2
, etc.
Now save the configuration and exit to continue.
Automatically start networking at boot
root #
cd /etc/init.d
root #
ln -s net.lo net.eth0
root #
rc-update add net.eth0 default
The hosts file
root #
nano -w /etc/hosts
# This defines the current system and must be set 127.0.0.1 tux.homenetwork tux localhost # Optional definition of extra systems on the network 192.168.0.5 jenny.homenetwork jenny 192.168.0.6 benny.homenetwork benny
パスワード更新
root #
passwd
Gentoo (at least when using OpenRC) uses /etc/rc.conf to configure the services, startup, and shutdown of a system. Open up /etc/rc.conf and enjoy all the comments in the file. Review the settings and change where needed.
root #
nano -w /etc/rc.conf <ーーどう扱うのか不明。
root #
nano -w /etc/conf.d/keymaps
# nano /etc/conf.d/keymaps
keymap="jp106"
# emerge dhcpcd このコマンドはもう今では消滅したのか?不明。
dhcpcdを使用しない方でやるか迷う所です。
2012年1月にvmware-playerにゲストとしてインストールしたジェンツーペンギン
64bitはdhcpcdを使用ですが、今では参考にしたhttpが無いようで、どのように
して作業したのか不明。
root #
nano -w /etc/conf.d/hwclock
clock="local"
#
nano /etc/conf.d/hwclock
clock="local"
Installing system toolsroot #
emerge --ask app-admin/syslog-ng
root #
rc-update add syslog-ng default
上記4行は
syslogとcronをemergeする
# emerge syslog-ng
# rc-update add syslog-ng default
# emerge vixie-cron
# rc-update add vixie-cron default
# emerge cronie
# rc-update add cronie
default vixie-cronからcronieに変わったようです。
で作業予定。感想としてダメだこのトリは。
一時期どう対処したらいいのかの表示が分り易かった事も有ったのですが。
Installing a DHCP client
Important
Although optional, the majority of users will find
that they need a DHCP client to get on their network.
Please install a DHCP client. If this is forgotten,
then the system might not be able to get on the network,
and thus cannot install a DHCP client afterwards as well.
In order for the system to automatically obtain an IP address
for one or more network interface(s),
it is necessary to install a DHCP client.
We recommend the use of net-misc/dhcpcd although many other DHCP clients
are available through the portage tree as well:
root #
emerge --ask net-misc/dhcpcd 有りました。これは
Configuring the bootloader
Installing GRUB2root #
emerge --ask sys-boot/grub
root #
grub2-install /dev/sda
# grub2-install /dev/sda で作業予定。1年前に比べて簡単に成ったようですが
これは
# emerge grub
合っているのか不明。
root #
grub2-mkconfig -o /boot/grub/grub.cfg
1年前と比べてインストール順番が違うのですが、合っているのか不明。ブートローダーの設定
# emerge grub <ーー1回目は何故か、ここも結構時間が掛かった。
# cd /boot
# mkdir grub
# grub2-mkconfig -o /boot/grub/grub.cfg
# grub2-install /dev/sda <ーーーこの順序でOK。
でしたが。
Rebooting the systemroot #
exit
cdimage ~#
cd
cdimage ~#
umount -l /mnt/gentoo/dev{/shm,/pts,}
cdimage ~#
umount /mnt/gentoo{/boot,/sys,/proc,}
cdimage ~#
reboot
との事なので、
chrootから抜ける
# exit
アンマウント
# umount -l dev/
# umount -l proc/
この辺りでPCからminimalCDを外しておく
# reboot で作業予定。
Finalizingnano -w
はnano で作業予定。
On ext2,
root #
mke2fs -T small /dev/<device>
root #
mke2fs -j -T small /dev/<device>
root #
mkfs.ext2 /dev/sda2
root #
mkfs.ext4 /dev/sda4
root #
mkswap /dev/sda3
root #
swapon /dev/sda3 <ーー私の場合はここから、多分。
root #
mount /dev/sda4 /mnt/gentoo
root #
mkdir /mnt/gentoo/boot
root #
mount /dev/sda2 /mnt/gentoo/boot
ここからが作業の開始です。
キーボードは22のjapanを選択する。
作成したファイルシステムをマウント
# mount /dev/sda27 /mnt/gentoo/
# mkdir /mnt/gentoo/boot
# mount /dev/sda20 /mnt/gentoo/boot
# swapon /dev/sda5
# date <ーーーー単なる確認。
# tar xvjpf stage3-*.tar.bz2 --xattrs
でいいのでは?と思う。下記も参考にして。root #
date
root #
date 032916212014
root #
cd /mnt/gentoo
root #
openssl dgst -r -sha512 stage3-amd64-<release>.tar.bz2
root #
sha512sum stage3-amd64-<release>.tar.bz2
root #
openssl dgst -r -whirlpool stage3-amd64-<release>.tar.bz2
root #
nano -w /mnt/gentoo/etc/portage/make.conf
<ーー -wは面倒なのでしない。なので
CFLAGS="-march=native -O2 -pipe" <ーー安全策でこれにする。
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
# Use the same settings for both variables
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j2" ここは
MAKEOPTS="-j5" にする。
Installing the Gentoo base system.
Warningを読むと下記2行は不要。root #
mirrorselect -i -o >> /mnt/gentoo/etc/portage/make.conf
root #
mirrorselect -i -r -o >> /mnt/gentoo/etc/portage/make.conf
root #
cp -L /etc/resolv.conf /mnt/gentoo/etc/
必要なファイルを更新して chroot でインストール環境に入ります。
# mount --rbind /dev/ dev/
root #
mount -t proc proc /mnt/gentoo/proc
root #
mount --rbind /sys /mnt/gentoo/sys
root #
mount --make-rslave /mnt/gentoo/sys
root #
mount --rbind /dev /mnt/gentoo/dev
root #
mount --make-rslave /mnt/gentoo/dev
root #
chroot /mnt/gentoo /bin/bash
root #
source /etc/profile
root #
export PS1="(chroot) $PS1"
root #
emerge-webrsync
<ーーこれは1年前では無かった。root #
emerge --sync
root #
eselect news list
root #
eselect news read
root #
man news.eselect
root #
eselect profile set 2
<ーー1年前では3だったが2に変わっている。In order to select a pure 64-bit environment,
with no 32-bit applications or libraries, use a non-multilib profile:
[5] default/linux/amd64/13.0/no-multilib なので 5 は絶対に選択しない。
root #
emerge --info | grep ^USE
USE="X acl alsa amd64 berkdb bindist bzip2 cli cracklib crypt cxx dri ..."
A full description on the available USE flags can be found on the system in /usr/portage/profiles/use.desc.
root #
less /usr/portage/profiles/use.desc
root #
nano -w /etc/portage/make.conf
なんとhi-hoのインストールの仕方は上2行のような感じ。
hi-hoは複製・転載は禁止します。との事です。root #
emerge --config sys-libs/timezone-data
Configure locales ここは絶対に合っていると思う。root #
nano -w /etc/locale.gen
en_US.UTF-8 UTF-8
ja_JP.UTF-8 UTF-8root #
locale-gen
root #
env-update && source /etc/profile
For Intel Core i7 CPU users or those having econf error during install (with the current 2012.1 release of Gentoo which ships with GCC 4.5.3 compiler) it is recommended to begin your install with the -march=core2 flag to generate a base install against GCC 4.5.3, then later you can upgrade GCC to 4.6.3 or newer in order to support the new -march=corei7 flag. Below is the recommended setting to begin with for Core i7 users:
CFLAGS="-march=core2 -O2 -pipe" CXXFLAGS="${CFLAGS}"
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
MAKEOTS="-j5" ここは MAKEOTS="-j9" が正解なのかも知れない
ソース2より上記かな?
https://wiki.gentoo.org/wiki/CFLAGS
-----------------------------
CLDXでibusやmozcがemerge出来なく成ったのはGentoo側の仕様変更のような気がする。
CLDXのcopyその1でradiorayの.debをtar展開してusrをcopyでマージしたら、
起動しなく成った。
CLDXのcopyその2のusrをcopyでマージしたら、起動はしたが、netが継らなく成った。
今、元に成った本家CLDXのusrをcopy中、良くないusrは削除してから。
これでダメだったら、また例のワンパターンで元に成ったCLDXをパーティションごと
copyする。ダメでnetが継らなく成ったでした。
後で、例のワンパターンで元に成ったCLDXをパーティションごとcopyする。で
行こうと思います。と思いましたが、忘れない内に作業して、どうなのか?
今、時間の掛かるsudo update-grubを実行中、で無事に起動しました。
おめでとうございます。以前はvlcはemergeでインストールしていたと思うのですが
emerge出来ませんでした。GUIで再起動は出来なく成っていたので端末で
sudo reboot 以前は確かcajaのtarをbuildでインストールしていましたが
今回はcopyを取ってからしようと思います。段々とCLDXが増えて行きます。
今3個です。
これは元々/のみで/bootのパーティションは無い。間違え易いので、注意の事。
copyその3を作っておこうと思いました。
------------------------
中古PCにMint13 MATE 64bitをUSBメモリにインストールでそれをHDDにcopyで
インストールしたが、状態が悪いので、 sda35。
Zorin Core 6.4 64bitを、これはHDDに直にインストール出来たが、
状態が悪いので、 swapのUUIDは変わっていなかった。良かった。
サポート切れですがUbuntu 10.04 64bit を
最初はHDDに直にインストールしようとしたが、
swapをformatするような表示でしたので、方針変更で
USBメモリにインストールでそれをHDDにcopyでインストールした。
後で、暇な時にkernelのVerをUPしようと思う。
clementine 1.2.0とradiotrayは動くようにした。
google-earthが文字化けでしたので、
env LANG="en_US" /opt/googleearth/googleearth %f で英語表示にした。
後でいじって見る。
サポート切れだと、依存関係で必要なsoftがインストールされない場合が有る。
そんな場合は端末表示を見てsynapticで1つ1つインストールした後で
gdebi展開でインストールした。端末で
# dpkg -i なんとか.deb よりもいいとの説有り。実際はどうなのかは不明。
--------------------------------------------------------------------
Configuring the Linux kernel 段々と疲労してやる気がなく成りつつ有ります。
root #
emerge --ask sys-kernel/gentoo-sources
genkernel
を使用する。kernelのbuildの方のやり方は採用しない。root #
emerge genkernel
root #
genkernel --install initramfs
root #
emerge --ask sys-kernel/genkernel
root #
nano -w /etc/fstab
/dev/sda2 /boot ext2 defaults 0 2
root #
genkernel all
root #
ls /boot/kernel* /boot/initramfs*
Configuring the modules
root #
find /lib/modules/<kernel version>/ -type f -iname '*.o' -or -iname '*.ko' | less
root #
nano -w /etc/conf.d/modules
root #
emerge --ask sys-kernel/linux-firmware
root #
nano -w /etc/fstab
# nano /etc/fstab
/dev/sda20 /boot ext4 noauto,noatime 1 2
/dev/sda27 / ext4 noatime 0 1
/dev/sda5 none swap sw 0 0
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
#/dev/fd0 /mnt/floppy auto noauto 0 0 <ーーー#を付加した。
Host and domain information
root #
nano -w /etc/conf.d/hostname
root #
emerge --ask --noreplace net-misc/netifrc
To use DHCP, define config_eth0
:
config_eth0="dhcp"
Please read /usr/share/doc/netifrc-*/net.example.bz2 for a list of all available options. Be sure to also read up on the DHCP client man page if specific DHCP options need to be set.
If the system has several network interfaces, then repeat the above steps for config_eth1
, config_eth2
, etc.
Now save the configuration and exit to continue.
Automatically start networking at boot
root #
cd /etc/init.d
root #
ln -s net.lo net.eth0
root #
rc-update add net.eth0 default
The hosts file
root #
nano -w /etc/hosts
# This defines the current system and must be set 127.0.0.1 tux.homenetwork tux localhost # Optional definition of extra systems on the network 192.168.0.5 jenny.homenetwork jenny 192.168.0.6 benny.homenetwork benny
パスワード更新
root #
passwd
Gentoo (at least when using OpenRC) uses /etc/rc.conf to configure the services, startup, and shutdown of a system. Open up /etc/rc.conf and enjoy all the comments in the file. Review the settings and change where needed.
root #
nano -w /etc/rc.conf <ーーどう扱うのか不明。
root #
nano -w /etc/conf.d/keymaps
# nano /etc/conf.d/keymaps
keymap="jp106"
# emerge dhcpcd このコマンドはもう今では消滅したのか?不明。
dhcpcdを使用しない方でやるか迷う所です。
2012年1月にvmware-playerにゲストとしてインストールしたジェンツーペンギン
64bitはdhcpcdを使用ですが、今では参考にしたhttpが無いようで、どのように
して作業したのか不明。
root #
nano -w /etc/conf.d/hwclock
clock="local"
#
nano /etc/conf.d/hwclock
clock="local"
Installing system toolsroot #
emerge --ask app-admin/syslog-ng
root #
rc-update add syslog-ng default
上記4行は
syslogとcronをemergeする
# emerge syslog-ng
# rc-update add syslog-ng default
# emerge vixie-cron
# rc-update add vixie-cron default
# emerge cronie
# rc-update add cronie
default vixie-cronからcronieに変わったようです。
で作業予定。感想としてダメだこのトリは。
一時期どう対処したらいいのかの表示が分り易かった事も有ったのですが。
Installing a DHCP client
Important
Although optional, the majority of users will find
that they need a DHCP client to get on their network.
Please install a DHCP client. If this is forgotten,
then the system might not be able to get on the network,
and thus cannot install a DHCP client afterwards as well.
In order for the system to automatically obtain an IP address
for one or more network interface(s),
it is necessary to install a DHCP client.
We recommend the use of net-misc/dhcpcd although many other DHCP clients
are available through the portage tree as well:
root #
emerge --ask net-misc/dhcpcd 有りました。これは
Configuring the bootloader
Installing GRUB2root #
emerge --ask sys-boot/grub
root #
grub2-install /dev/sda
# grub2-install /dev/sda で作業予定。1年前に比べて簡単に成ったようですが
これは
# emerge grub
合っているのか不明。
root #
grub2-mkconfig -o /boot/grub/grub.cfg
1年前と比べてインストール順番が違うのですが、合っているのか不明。ブートローダーの設定
# emerge grub <ーー1回目は何故か、ここも結構時間が掛かった。
# cd /boot
# mkdir grub
# grub2-mkconfig -o /boot/grub/grub.cfg
# grub2-install /dev/sda <ーーーこの順序でOK。
でしたが。
Rebooting the systemroot #
exit
cdimage ~#
cd
cdimage ~#
umount -l /mnt/gentoo/dev{/shm,/pts,}
cdimage ~#
umount /mnt/gentoo{/boot,/sys,/proc,}
cdimage ~#
reboot
との事なので、
chrootから抜ける
# exit
アンマウント
# umount -l dev/
# umount -l proc/
この辺りでPCからminimalCDを外しておく
# reboot で作業予定。
Finalizing
Login:root
Password: (Enter the root password)
root #
useradd -m -G users,wheel,audio -s /bin/bash john
root #
passwd john 注、johnはここではユーザー名
Password: (Enter the password for john) Re-enter password: (Re-enter the password to verify)
との事なので、
再起動で
root
パスワード
# useradd -m -G users,wheel,audio -s /bin/bash ユーザー名
# passwd
ユーザー名
で作業予定。
何と信じらない事にHandbook:AMD64の説明はここで終わっていました。
GUI画面の出し方の説明は? 以下勝手な想像で、かGentoo LXDEでぐぐるか
Login:root
Password: (Enter the root password)
Login:
構想として。
中古PCにジェンツーペンギン。part6
では、ジェンツーペンギンのwikiには今どのように書いて有るのか?を調べて見ると、
Handbook:AMD64
https://wiki.gentoo.org/wiki/Handbook:AMD64
Preparing the disks
https://wiki.gentoo.org/wiki/Handbook:AMD64/Installation/Disks
Safe CFLAGS
https://wiki.gentoo.org/wiki/
Gentooのインストールファイルのインストール
ハンドブック:AMD64
などより
パーティションの設定を済ませて では無いような説明のようです。
google翻訳でhttpを見て下さい。
nano -w
はnano で作業予定。
On ext2,
root #
mke2fs -T small /dev/<device>
root #
mke2fs -j -T small /dev/<device>
root #
mkfs.ext2 /dev/sda2
root #
mkfs.ext4 /dev/sda4
root #
mkswap /dev/sda3
root #
swapon /dev/sda3 <ーー私の場合はここから、多分。
root #
mount /dev/sda4 /mnt/gentoo
root #
mkdir /mnt/gentoo/boot
root #
mount /dev/sda2 /mnt/gentoo/boot
ここからが作業の開始です。
キーボードは22のjapanを選択する。
作成したファイルシステムをマウント
# mount /dev/sda27 /mnt/gentoo/
# mkdir /mnt/gentoo/boot
# mount /dev/sda20 /mnt/gentoo/boot
# swapon /dev/sda5
# date <ーーーー単なる確認。
# tar xvjpf stage3-*.tar.bz2 --xattrs
でいいのでは?と思う。下記も参考にして。root #
date
root #
date 032916212014
root #
cd /mnt/gentoo
root #
openssl dgst -r -sha512 stage3-amd64-<release>.tar.bz2
root #
sha512sum stage3-amd64-<release>.tar.bz2
root #
openssl dgst -r -whirlpool stage3-amd64-<release>.tar.bz2
root #
nano -w /mnt/gentoo/etc/portage/make.conf
<ーー -wは面倒なのでしない。なので
CFLAGS="-march=native -O2 -pipe" <ーー安全策でこれにする。
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
# Use the same settings for both variables
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j2" ここは
MAKEOPTS="-j5" にする。
Installing the Gentoo base system.
Warningを読むと下記2行は不要。root #
mirrorselect -i -o >> /mnt/gentoo/etc/portage/make.conf
root #
mirrorselect -i -r -o >> /mnt/gentoo/etc/portage/make.conf
root #
cp -L /etc/resolv.conf /mnt/gentoo/etc/
必要なファイルを更新して chroot でインストール環境に入ります。
# mount --rbind /dev/ dev/
root #
mount -t proc proc /mnt/gentoo/proc
root #
mount --rbind /sys /mnt/gentoo/sys
root #
mount --make-rslave /mnt/gentoo/sys
root #
mount --rbind /dev /mnt/gentoo/dev
root #
mount --make-rslave /mnt/gentoo/dev
root #
chroot /mnt/gentoo /bin/bash
root #
source /etc/profile
root #
export PS1="(chroot) $PS1"
root #
emerge-webrsync
<ーーこれは1年前では無かった。root #
emerge --sync
root #
eselect news list
root #
eselect news read
root #
man news.eselect
root #
eselect profile set 2
<ーー1年前では3だったが2に変わっている。In order to select a pure 64-bit environment,
with no 32-bit applications or libraries, use a non-multilib profile:
[5] default/linux/amd64/13.0/no-multilib なので 5 は絶対に選択しない。
root #
emerge --info | grep ^USE
USE="X acl alsa amd64 berkdb bindist bzip2 cli cracklib crypt cxx dri ..."
A full description on the available USE flags can be found on the system in /usr/portage/profiles/use.desc.
root #
less /usr/portage/profiles/use.desc
root #
nano -w /etc/portage/make.conf
なんとhi-hoのインストールの仕方は上2行のような感じ。
hi-hoは複製・転載は禁止します。との事です。root #
emerge --config sys-libs/timezone-data
Configure locales ここは絶対に合っていると思う。root #
nano -w /etc/locale.gen
en_US.UTF-8 UTF-8
ja_JP.UTF-8 UTF-8root #
locale-gen
root #
env-update && source /etc/profile
For Intel Core i7 CPU users or those having econf error during install (with the current 2012.1 release of Gentoo which ships with GCC 4.5.3 compiler) it is recommended to begin your install with the -march=core2 flag to generate a base install against GCC 4.5.3, then later you can upgrade GCC to 4.6.3 or newer in order to support the new -march=corei7 flag. Below is the recommended setting to begin with for Core i7 users:
CFLAGS="-march=core2 -O2 -pipe" CXXFLAGS="${CFLAGS}"
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
MAKEOTS="-j5" ここは MAKEOTS="-j9" が正解なのかも知れない
ソース2より上記かな?
https://wiki.gentoo.org/wiki/CFLAGS
Configuring the Linux kernel 段々と疲労してやる気がなく成りつつ有ります。
root #
emerge --ask sys-kernel/gentoo-sources
genkernel
を使用する。kernelのbuildの方のやり方は採用しない。root #
emerge genkernel
root #
genkernel --install initramfs
root #
emerge --ask sys-kernel/genkernel
root #
nano -w /etc/fstab
/dev/sda2 /boot ext2 defaults 0 2
root #
genkernel all
root #
ls /boot/kernel* /boot/initramfs*
Configuring the modules
root #
find /lib/modules/<kernel version>/ -type f -iname '*.o' -or -iname '*.ko' | less
root #
nano -w /etc/conf.d/modules
root #
emerge --ask sys-kernel/linux-firmware
root #
nano -w /etc/fstab
# nano /etc/fstab
/dev/sda20 /boot ext4 noauto,noatime 1 2
/dev/sda27 / ext4 noatime 0 1
/dev/sda5 none swap sw 0 0
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
#/dev/fd0 /mnt/floppy auto noauto 0 0 <ーーー#を付加した。
Host and domain information
root #
nano -w /etc/conf.d/hostname
root #
emerge --ask --noreplace net-misc/netifrc
To use DHCP, define config_eth0
:
config_eth0="dhcp"
Please read /usr/share/doc/netifrc-*/net.example.bz2 for a list of all available options. Be sure to also read up on the DHCP client man page if specific DHCP options need to be set.
If the system has several network interfaces, then repeat the above steps for config_eth1
, config_eth2
, etc.
Now save the configuration and exit to continue.
Automatically start networking at boot
root #
cd /etc/init.d
root #
ln -s net.lo net.eth0
root #
rc-update add net.eth0 default
The hosts file
root #
nano -w /etc/hosts
# This defines the current system and must be set 127.0.0.1 tux.homenetwork tux localhost # Optional definition of extra systems on the network 192.168.0.5 jenny.homenetwork jenny 192.168.0.6 benny.homenetwork benny
パスワード更新
root #
passwd
Gentoo (at least when using OpenRC) uses /etc/rc.conf to configure the services, startup, and shutdown of a system. Open up /etc/rc.conf and enjoy all the comments in the file. Review the settings and change where needed.
root #
nano -w /etc/rc.conf <ーーどう扱うのか不明。
root #
nano -w /etc/conf.d/keymaps
# nano /etc/conf.d/keymaps
keymap="jp106"
# emerge dhcpcd このコマンドはもう今では消滅したのか?不明。
dhcpcdを使用しない方でやるか迷う所です。
2012年1月にvmware-playerにゲストとしてインストールしたジェンツーペンギン
64bitはdhcpcdを使用ですが、今では参考にしたhttpが無いようで、どのように
して作業したのか不明。
root #
nano -w /etc/conf.d/hwclock
clock="local"
#
nano /etc/conf.d/hwclock
clock="local"
Installing system toolsroot #
emerge --ask app-admin/syslog-ng
root #
rc-update add syslog-ng default
上記4行は
syslogとcronをemergeする
# emerge syslog-ng
# rc-update add syslog-ng default
# emerge vixie-cron
# rc-update add vixie-cron default
# emerge cronie
# rc-update add cronie
default vixie-cronからcronieに変わったようです。
で作業予定。感想としてダメだこのトリは。
一時期どう対処したらいいのかの表示が分り易かった事も有ったのですが。
Installing a DHCP client
Important
Although optional, the majority of users will find
that they need a DHCP client to get on their network.
Please install a DHCP client. If this is forgotten,
then the system might not be able to get on the network,
and thus cannot install a DHCP client afterwards as well.
In order for the system to automatically obtain an IP address
for one or more network interface(s),
it is necessary to install a DHCP client.
We recommend the use of net-misc/dhcpcd although many other DHCP clients
are available through the portage tree as well:
root #
emerge --ask net-misc/dhcpcd 有りました。これは
Configuring the bootloader
Installing GRUB2root #
emerge --ask sys-boot/grub
root #
grub2-install /dev/sda
# grub2-install /dev/sda で作業予定。1年前に比べて簡単に成ったようですが
これは
# emerge grub
合っているのか不明。
root #
grub2-mkconfig -o /boot/grub/grub.cfg
1年前と比べてインストール順番が違うのですが、合っているのか不明。ブートローダーの設定
# emerge grub <ーー1回目は何故か、ここも結構時間が掛かった。
# cd /boot
# mkdir grub
# grub2-mkconfig -o /boot/grub/grub.cfg
# grub2-install /dev/sda <ーーーこの順序でOK。
でしたが。
Rebooting the systemroot #
exit
cdimage ~#
cd
cdimage ~#
umount -l /mnt/gentoo/dev{/shm,/pts,}
cdimage ~#
umount /mnt/gentoo{/boot,/sys,/proc,}
cdimage ~#
reboot
との事なので、
chrootから抜ける
# exit
アンマウント
# umount -l dev/
# umount -l proc/
この辺りでPCからminimalCDを外しておく
# reboot で作業予定。
Finalizingnano -w
はnano で作業予定。
On ext2,
root #
mke2fs -T small /dev/<device>
root #
mke2fs -j -T small /dev/<device>
root #
mkfs.ext2 /dev/sda2
root #
mkfs.ext4 /dev/sda4
root #
mkswap /dev/sda3
root #
swapon /dev/sda3 <ーー私の場合はここから、多分。
root #
mount /dev/sda4 /mnt/gentoo
root #
mkdir /mnt/gentoo/boot
root #
mount /dev/sda2 /mnt/gentoo/boot
ここからが作業の開始です。
キーボードは22のjapanを選択する。
作成したファイルシステムをマウント
# mount /dev/sda27 /mnt/gentoo/
# mkdir /mnt/gentoo/boot
# mount /dev/sda20 /mnt/gentoo/boot
# swapon /dev/sda5
# date <ーーーー単なる確認。
# tar xvjpf stage3-*.tar.bz2 --xattrs
でいいのでは?と思う。下記も参考にして。root #
date
root #
date 032916212014
root #
cd /mnt/gentoo
root #
openssl dgst -r -sha512 stage3-amd64-<release>.tar.bz2
root #
sha512sum stage3-amd64-<release>.tar.bz2
root #
openssl dgst -r -whirlpool stage3-amd64-<release>.tar.bz2
root #
nano -w /mnt/gentoo/etc/portage/make.conf
<ーー -wは面倒なのでしない。なので
CFLAGS="-march=native -O2 -pipe" <ーー安全策でこれにする。
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
# Use the same settings for both variables
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j2" ここは
MAKEOPTS="-j5" にする。
Installing the Gentoo base system.
Warningを読むと下記2行は不要。root #
mirrorselect -i -o >> /mnt/gentoo/etc/portage/make.conf
root #
mirrorselect -i -r -o >> /mnt/gentoo/etc/portage/make.conf
root #
cp -L /etc/resolv.conf /mnt/gentoo/etc/
必要なファイルを更新して chroot でインストール環境に入ります。
# mount --rbind /dev/ dev/
root #
mount -t proc proc /mnt/gentoo/proc
root #
mount --rbind /sys /mnt/gentoo/sys
root #
mount --make-rslave /mnt/gentoo/sys
root #
mount --rbind /dev /mnt/gentoo/dev
root #
mount --make-rslave /mnt/gentoo/dev
root #
chroot /mnt/gentoo /bin/bash
root #
source /etc/profile
root #
export PS1="(chroot) $PS1"
root #
emerge-webrsync
<ーーこれは1年前では無かった。root #
emerge --sync
root #
eselect news list
root #
eselect news read
root #
man news.eselect
root #
eselect profile set 2
<ーー1年前では3だったが2に変わっている。In order to select a pure 64-bit environment,
with no 32-bit applications or libraries, use a non-multilib profile:
[5] default/linux/amd64/13.0/no-multilib なので 5 は絶対に選択しない。
root #
emerge --info | grep ^USE
USE="X acl alsa amd64 berkdb bindist bzip2 cli cracklib crypt cxx dri ..."
A full description on the available USE flags can be found on the system in /usr/portage/profiles/use.desc.
root #
less /usr/portage/profiles/use.desc
root #
nano -w /etc/portage/make.conf
なんとhi-hoのインストールの仕方は上2行のような感じ。
hi-hoは複製・転載は禁止します。との事です。root #
emerge --config sys-libs/timezone-data
Configure locales ここは絶対に合っていると思う。root #
nano -w /etc/locale.gen
en_US.UTF-8 UTF-8
ja_JP.UTF-8 UTF-8root #
locale-gen
root #
env-update && source /etc/profile
For Intel Core i7 CPU users or those having econf error during install (with the current 2012.1 release of Gentoo which ships with GCC 4.5.3 compiler) it is recommended to begin your install with the -march=core2 flag to generate a base install against GCC 4.5.3, then later you can upgrade GCC to 4.6.3 or newer in order to support the new -march=corei7 flag. Below is the recommended setting to begin with for Core i7 users:
CFLAGS="-march=core2 -O2 -pipe" CXXFLAGS="${CFLAGS}"
CFLAGS="-march=core2 -O2 -pipe" <ーーソース2より
MAKEOTS="-j5" ここは MAKEOTS="-j9" が正解なのかも知れない
ソース2より上記かな?
https://wiki.gentoo.org/wiki/CFLAGS
-----------------------------
CLDXでibusやmozcがemerge出来なく成ったのはGentoo側の仕様変更のような気がする。
CLDXのcopyその1でradiorayの.debをtar展開してusrをcopyでマージしたら、
起動しなく成った。
CLDXのcopyその2のusrをcopyでマージしたら、起動はしたが、netが継らなく成った。
今、元に成った本家CLDXのusrをcopy中、良くないusrは削除してから。
これでダメだったら、また例のワンパターンで元に成ったCLDXをパーティションごと
copyする。ダメでnetが継らなく成ったでした。
後で、例のワンパターンで元に成ったCLDXをパーティションごとcopyする。で
行こうと思います。と思いましたが、忘れない内に作業して、どうなのか?
今、時間の掛かるsudo update-grubを実行中、で無事に起動しました。
おめでとうございます。以前はvlcはemergeでインストールしていたと思うのですが
emerge出来ませんでした。GUIで再起動は出来なく成っていたので端末で
sudo reboot 以前は確かcajaのtarをbuildでインストールしていましたが
今回はcopyを取ってからしようと思います。段々とCLDXが増えて行きます。
今3個です。
これは元々/のみで/bootのパーティションは無い。間違え易いので、注意の事。
copyその3を作っておこうと思いました。
------------------------
中古PCにMint13 MATE 64bitをUSBメモリにインストールでそれをHDDにcopyで
インストールしたが、状態が悪いので、 sda35。
Zorin Core 6.4 64bitを、これはHDDに直にインストール出来たが、
状態が悪いので、 swapのUUIDは変わっていなかった。良かった。
サポート切れですがUbuntu 10.04 64bit を
最初はHDDに直にインストールしようとしたが、
swapをformatするような表示でしたので、方針変更で
USBメモリにインストールでそれをHDDにcopyでインストールした。
後で、暇な時にkernelのVerをUPしようと思う。
clementine 1.2.0とradiotrayは動くようにした。
google-earthが文字化けでしたので、
env LANG="en_US" /opt/googleearth/googleearth %f で英語表示にした。
後でいじって見る。
サポート切れだと、依存関係で必要なsoftがインストールされない場合が有る。
そんな場合は端末表示を見てsynapticで1つ1つインストールした後で
gdebi展開でインストールした。端末で
# dpkg -i なんとか.deb よりもいいとの説有り。実際はどうなのかは不明。
--------------------------------------------------------------------
Configuring the Linux kernel 段々と疲労してやる気がなく成りつつ有ります。
root #
emerge --ask sys-kernel/gentoo-sources
genkernel
を使用する。kernelのbuildの方のやり方は採用しない。root #
emerge genkernel
root #
genkernel --install initramfs
root #
emerge --ask sys-kernel/genkernel
root #
nano -w /etc/fstab
/dev/sda2 /boot ext2 defaults 0 2
root #
genkernel all
root #
ls /boot/kernel* /boot/initramfs*
Configuring the modules
root #
find /lib/modules/<kernel version>/ -type f -iname '*.o' -or -iname '*.ko' | less
root #
nano -w /etc/conf.d/modules
root #
emerge --ask sys-kernel/linux-firmware
root #
nano -w /etc/fstab
# nano /etc/fstab
/dev/sda20 /boot ext4 noauto,noatime 1 2
/dev/sda27 / ext4 noatime 0 1
/dev/sda5 none swap sw 0 0
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
#/dev/fd0 /mnt/floppy auto noauto 0 0 <ーーー#を付加した。
Host and domain information
root #
nano -w /etc/conf.d/hostname
root #
emerge --ask --noreplace net-misc/netifrc
To use DHCP, define config_eth0
:
config_eth0="dhcp"
Please read /usr/share/doc/netifrc-*/net.example.bz2 for a list of all available options. Be sure to also read up on the DHCP client man page if specific DHCP options need to be set.
If the system has several network interfaces, then repeat the above steps for config_eth1
, config_eth2
, etc.
Now save the configuration and exit to continue.
Automatically start networking at boot
root #
cd /etc/init.d
root #
ln -s net.lo net.eth0
root #
rc-update add net.eth0 default
The hosts file
root #
nano -w /etc/hosts
# This defines the current system and must be set 127.0.0.1 tux.homenetwork tux localhost # Optional definition of extra systems on the network 192.168.0.5 jenny.homenetwork jenny 192.168.0.6 benny.homenetwork benny
パスワード更新
root #
passwd
Gentoo (at least when using OpenRC) uses /etc/rc.conf to configure the services, startup, and shutdown of a system. Open up /etc/rc.conf and enjoy all the comments in the file. Review the settings and change where needed.
root #
nano -w /etc/rc.conf <ーーどう扱うのか不明。
root #
nano -w /etc/conf.d/keymaps
# nano /etc/conf.d/keymaps
keymap="jp106"
# emerge dhcpcd このコマンドはもう今では消滅したのか?不明。
dhcpcdを使用しない方でやるか迷う所です。
2012年1月にvmware-playerにゲストとしてインストールしたジェンツーペンギン
64bitはdhcpcdを使用ですが、今では参考にしたhttpが無いようで、どのように
して作業したのか不明。
root #
nano -w /etc/conf.d/hwclock
clock="local"
#
nano /etc/conf.d/hwclock
clock="local"
Installing system toolsroot #
emerge --ask app-admin/syslog-ng
root #
rc-update add syslog-ng default
上記4行は
syslogとcronをemergeする
# emerge syslog-ng
# rc-update add syslog-ng default
# emerge vixie-cron
# rc-update add vixie-cron default
# emerge cronie
# rc-update add cronie
default vixie-cronからcronieに変わったようです。
で作業予定。感想としてダメだこのトリは。
一時期どう対処したらいいのかの表示が分り易かった事も有ったのですが。
Installing a DHCP client
Important
Although optional, the majority of users will find
that they need a DHCP client to get on their network.
Please install a DHCP client. If this is forgotten,
then the system might not be able to get on the network,
and thus cannot install a DHCP client afterwards as well.
In order for the system to automatically obtain an IP address
for one or more network interface(s),
it is necessary to install a DHCP client.
We recommend the use of net-misc/dhcpcd although many other DHCP clients
are available through the portage tree as well:
root #
emerge --ask net-misc/dhcpcd 有りました。これは
Configuring the bootloader
Installing GRUB2root #
emerge --ask sys-boot/grub
root #
grub2-install /dev/sda
# grub2-install /dev/sda で作業予定。1年前に比べて簡単に成ったようですが
これは
# emerge grub
合っているのか不明。
root #
grub2-mkconfig -o /boot/grub/grub.cfg
1年前と比べてインストール順番が違うのですが、合っているのか不明。ブートローダーの設定
# emerge grub <ーー1回目は何故か、ここも結構時間が掛かった。
# cd /boot
# mkdir grub
# grub2-mkconfig -o /boot/grub/grub.cfg
# grub2-install /dev/sda <ーーーこの順序でOK。
でしたが。
Rebooting the systemroot #
exit
cdimage ~#
cd
cdimage ~#
umount -l /mnt/gentoo/dev{/shm,/pts,}
cdimage ~#
umount /mnt/gentoo{/boot,/sys,/proc,}
cdimage ~#
reboot
との事なので、
chrootから抜ける
# exit
アンマウント
# umount -l dev/
# umount -l proc/
この辺りでPCからminimalCDを外しておく
# reboot で作業予定。
Finalizing
Login:root
Password: (Enter the root password)
root #
useradd -m -G users,wheel,audio -s /bin/bash john
root #
passwd john 注、johnはここではユーザー名
Password: (Enter the password for john) Re-enter password: (Re-enter the password to verify)
との事なので、
再起動で
root
パスワード
# useradd -m -G users,wheel,audio -s /bin/bash ユーザー名
# passwd
ユーザー名
で作業予定。
何と信じらない事にHandbook:AMD64の説明はここで終わっていました。