Configurare Buildbot per le Macchine Virtuali - Centos 5 amd64

Installazione base

cd /kvm
qemu-img create -f qcow2 vms/vm-centos5-amd64-serial.qcow2 8G
kvm -m 2047 -hda /kvm/vms/vm-centos5-amd64-serial.qcow2 -cdrom CentOS-5.3-x86_64-bin-DVD.iso -redir 'tcp:2237::22' -boot d -smp 2 -cpu qemu64 -net nic,model=virtio -net user

Setup della porta seriale e dell'account

kvm -m 2047 -hda /kvm/vms/vm-centos5-amd64-serial.qcow2 -cdrom CentOS-5.3-i386-bin-DVD.iso -redir 'tcp:2237::22' -boot c -smp 2 -cpu qemu64 -net nic,model=virtio -net user -nographic

Aggiungere a /boot/grub/menu.lst:

serial --unit=0 --speed=115200 --word=8 --parity=no --stop=1
terminal --timeout=3 serial console

inoltre aggiungere in menu.lst la riga del kernel (dopo aver cancellato `quiet splash'):

console=tty0 console=ttyS0,115200n8

Eseguire i seguenti comandi:

cat >>/etc/inittab <<END
# Console seriale.
S0:2345:respawn:/sbin/agetty -h -L ttyS0 19200 vt100
useradd buildbot

# La password è disabilitata per default in Centos5.

usermod -a -G wheel buildbot

# Decommentare la riga "%wheel        ALL=(ALL)       NOPASSWD: ALL"
# Commentare questa riga:
# Defaults    requiretty

# Mettere in public la chiave ssh per l'account e l'host.
# Notare che Centos5 richiede: require .ssh/authorized_keys chmod go-rwx.

su - buildbot
mkdir .ssh
chmod go-rwx .ssh
cat >.ssh/authorized_keys
chmod go-rwx .ssh/authorized_keys

Immagine per la build rpm

qemu-img create -b vm-centos5-amd64-serial.qcow2 -f qcow2 vm-centos5-amd64-build.qcow2
kvm -m 2047 -hda /kvm/vms/vm-centos5-amd64-build.qcow2 -cdrom /kvm/CentOS-5.3-x86_64-bin-DVD.iso -redir 'tcp:2237::22' -boot c -smp 2 -cpu qemu64 -net nic,model=virtio -net user -nographic

Installare i compilatori, etc:

sudo yum groupinstall "Development Tools"
sudo yum install gperf readline-devel ncurses-devel libaio-devel openssl-devel zlib-devel perl perl\(DBI\)

Scaricare l'rpm di 5.0 per shared-compat:

sudo mkdir -p /srv/shared/yum/CentOS/5/x86_64/RPMS/
cd /srv/shared/yum/CentOS/5/x86_64/RPMS/
sudo wget

Immagine per installare/testare

qemu-img create -b vm-centos5-amd64-serial.qcow2 -f qcow2 vm-centos5-amd64-install.qcow2
kvm -m 2047 -hda /kvm/vms/vm-centos5-amd64-install.qcow2 -cdrom /kvm/CentOS-5.3-x86_64-bin-DVD.iso -redir 'tcp:2237::22' -boot c -smp 2 -cpu qemu64 -net nic,model=virtio -net user -nographic

Installare le dipendenze aggiuntive:

sudo yum install perl perl\(DBI\)


Sto caricando i commenti......
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.