lost and found ( for me ? )

Showing posts with label BackTrack Linux 5 R3. Show all posts
Showing posts with label BackTrack Linux 5 R3. Show all posts

install backtrack linux 5 r3 within KVM


KVM host

[root@f18 ~]# libvirtd --version
libvirtd (libvirt) 1.0.3
[root@f18 ~]# qemu-kvm --version
QEMU emulator version 1.4.0, Copyright (c) 2003-2008 Fabrice Bellard
[root@f18 ~]# cat /etc/fedora-release
Fedora release 18 (Spherical Cow)

after I completed installing bt5 within KVM , I faced the following error.

error : no suitable mode found
error : unknown command ‘terminal’
vga=791 is deprecated.


To solve this , it seems that we may solve this by switching video model to cirrus.
So I tried to switch video model to cirrus via virt-manager , I faced another error.
XML error: ram attribute only supported for type of qxl

It was caused by the following bug.

Bug 920549 - error shows when changing video from qxl to other models

To solve this issue , edit the the xml file via “virsh edit” command.

virsh edit <VM name>

edit the following line:

form
<model type='qxl' ram='65536' vram='65536' heads='1'/>

to
<model type='cirrus' vram='65536' heads='1'/>

after switching video mode to cirrus , I am able to boot the BT5R3 within KVM successfully.

install BackTrack Linux 5 R3 x86_64 (BT5R3 ) within KVM

Here's an explanation of how to install BackTrack Linux 5 R3 within KVM 

KVM host info

# lsb_release -a
No LSB modules are available.
Distributor ID: LinuxMint
Description:    Linux Mint 12 Lisa
Release:        12
Codename:       lisa

# uname -ri
3.2.0-33-generic x86_64

# libvirtd --version
libvirtd (libvirt) 0.9.8

# kvm --version
QEMU emulator version 1.0 (qemu-kvm-1.0), Copyright (c) 2003-2008 Fabrice Bellard


install BT5R3 with virt-manager.
BT5R3 is Ubuntu 12.04 base.



boot BT



after booting the BT , type startx



click “Install BackTrack”



installing BT into HDD





after booting BT from vDHH.

user : root
credential : toor




[ allow ssh access ]

generate SSH key

root@bt:~# sshd-generate


start ssh daemon
root@bt:~# /etc/init.d/ssh start


[ how to access to BT via virsh console ]

add a serial port on BT VM , if you have not added to

on the KVM host
virsh # dumpxml BT5

   <serial type='pty'>
     <source path='/dev/pts/16'/>
     <target port='0'/>
     <alias name='serial0'/>
   </serial>


make /etc/init/ttyS0.conf on the BT VM
root@bt:~# cat /etc/init/ttyS0.conf
start on stopped rc RUNLEVEL=[2345]
stop on runlevel [!2345]

respawn
exec /sbin/getty -L 115200 ttyS0 vt102


edit /boot/grub/menu.lst

add writable permission
root@bt:~# chmod u+w /boot/grub/grub.cfg


edit grub.cfg
add red lines.
serial -speed=115200 -unit=0 -word=8 -parity=no -stop=1
terminal -timeout=10 serial

menuentry 'Ubuntu, with Linux 3.2.6' --class ubuntu --class gnu-linux --class gnu --class os {
       recordfail
       insmod ext2
       set root='(hd0,1)'
       search --no-floppy --fs-uuid --set 818802dc-9073-4b13-93a8-046e382edb46
       linux   /boot/vmlinuz-3.2.6 root=UUID=818802dc-9073-4b13-93a8-046e382edb46 ro   text splash vga=791 console=ttyS0,115200n8
       initrd  /boot/initrd.img-3.2.6
}


reboot the BT

connect to the BT5 VM over virsh console
virsh # console BT5
Connected to domain BT5
Escape character is ^]

BackTrack 5 R3 - 64 Bit bt ttyS0
bt login: root
Password:
Last login: Tue Nov 27 22:40:14 JST 2012 on ttyS0