VMware Global Community
stworekpotworek
Contributor
Contributor

instalacja ubuntu na vmware win2003 ?

Witam,

mam postawiony VMware serwer na win2003 serwer, kilka virtualek sobie tam chodzi, glownie windowsowych, teraz chcialbym wrzucic kolejna virtualke ubuntu_9.0, niestety utknelem, czy ktos moze podeslac jakies materialy jak to pchnac ?

A moze ktos juz cos podobnego zrobil ?

Pozdrawiam

Rafal

Reply
0 Kudos
18 Replies
inleo
Leadership
Leadership

a wyskakuje ci jakiś błąd? napisz dokładniej gdzie pojawia się Twój problem.

http://blog.inleo.pl @maciejlelusz
Reply
0 Kudos
kszafer
Contributor
Contributor

Hi

Thank You for Your email. I'm on the business trip till 18th February - please expect some delays in answering Your email.

Kindly Regards

Krzysztof Szafer

Reply
0 Kudos
stworekpotworek
Contributor
Contributor

Witaj, 

nie , nie dostarlem do tego etapu, nie znalazlem konwertera ktory skonwertowalby mi działajace ubuntu do vmwware pod win2003.

dlatego pytalem o manual/metodyke postepowania.

Pozdrawiam

Rafal

Reply
0 Kudos
inleo
Leadership
Leadership

Aaa... czyli ty chcesz zmigorwać ubuntu z jakiegoś kompa do vm. Trzeba było od razu tak mówić Smiley Wink Słuchaj sprawa jest dosyć prosta, ale niepewna (tzn. czasami działa ta metoda czasami nie, kwestia jak bardzo wyuzdany kontroler dysków masz w maszynie fizycznej z której migrujesz).

Otóż ściągnij sobie VMware Converter w wersji którą możesz nagrać na płytę i zbootować (). Zimna migracja powinna przenieść Ubuntu do maszyny wirtualnej którą będziesz ją mógł odpalić na VMware Server na 2003. Podczas migracji będziesz mógł wybrać typ maszyny wirtualnej do jakiego chcesz migrować.

http://blog.inleo.pl @maciejlelusz
Reply
0 Kudos
stworekpotworek
Contributor
Contributor

no tak,

tylko  bootcd jest w wersji platnej za ponad 2tys , a jak nie zadziala , to 2 tys niepotrzebnie wydane ;-(

chyba ze zle patrze, i moze jest cos co niekoniecznie jest odplatne ?

Reply
0 Kudos
inleo
Leadership
Leadership

W sumie to ja nie popatrzyłem, mam komercyjną wersję, więc nigdy nie sprawdziłem czy na convertera trzeba mieć licencję... ale przyszła mi do głowy metoda full-hardkor. Tzn. Zrobić kopię clonezilla do czystej maszyny wirtualnej.

Ściągnij sobie clonezille, zrób obraz maszyny fizycznej na jakiś przenośny dysk, czy zasób sieciowy a później odzyskaj ją do czystej maszyny wirtualnej. Ubuntu powinno wstać po takiej zabawie, jedyne co powinno nie działać to sieciówki, ale wystarczy w pliku /etc/udev/70-cośtam-rules/... zmienić mac adresy i powinno wszytko zadziałać. Clonezilla może działać również w trybie klient serwer i bezpośrednio z jednej maszyny możesz lądować do drugiej (w twoim przypadku z blachy do vm).

Spróbuj powinno się udać, chyba że coś zmieniałeś w tym ubuntu (własny kernel itp.)

http://blog.inleo.pl @maciejlelusz
Reply
0 Kudos
stworekpotworek
Contributor
Contributor

Uzylem clonnzille - stworzyl mi :

aporia-root.ext3-ptcl-img.gz.aa  Info-dmi.txt    Info-packages.txt  lvm_vg_dev.list          sda-chs.sf                sda-pt.parted

aporia-root.ext3-ptcl-img.gz.ab  Info-lshw.txt  lvm_aporia.conf    parts                    sda-hidden-data-after-mbr  sda-pt.sf

disk                            Info-lspci.txt  lvm_logv.list      sda5.ext2-ptcl-img.gz.aa  sda-mbr                    swappt-aporia-swap_1.info

teraz nie wiem jak to zaimporowac do maszyny wirtualnej ,

przy probie importu mowie ze nie znalazl systemu operacyjnego ,

Moj Kontroler Raid :  04:03.0 RAID bus controller: Dell PowerEdge Expandable RAID controller 4/Di (rev 02)

dell poweredge 1950

Pozdrawiam

Rafal

Reply
0 Kudos
inleo
Leadership
Leadership

Rozumiem że botujesz w maszynie wirtualnej clonezille i nią wpluwasz z obrazu do maszyny bezpośrednio?

http://blog.inleo.pl @maciejlelusz
stworekpotworek
Contributor
Contributor

wykrzacza sie na LVM ktory zostal domyslnie zainstalowany na maszynie pierwotnej, i nie udaje sie odtworzyc, sypie beldami przy odtwarzaniu.

Reply
0 Kudos
TomPreg
Contributor
Contributor

Jestem nieobecny w pracy do dnia 28-02-2011. Pilne sprawy proszę kierować na skrzynkę AdministratorzyNT. Tomek Pręgowski

Reply
0 Kudos
kszafer
Contributor
Contributor

Hi

Thank You for Your email. I'm on the vacations till 6th March with no access to Internet.

Kindly Regards

Krzysztof Szafer

Reply
0 Kudos
stworekpotworek
Contributor
Contributor

wykrzacza sie na LVM ktory zostal domyslnie zainstalowany na maszynie  pierwotnej, i nie udaje sie odtworzyc, sypie beldami przy odtwarzaniu partycji, odtwarza tylko 1 bootowalna z 3 , reszty wogole nie tworzy ;-(

Proba utworzenia recznie tych partycji pozostalych nie przynosi rezultatu

Maszyne bez lvm z ubuntu -udalo sie przeniesc z powodzeniem.

Reply
0 Kudos
Grzesiekk
Expert
Expert

Czy probowales uzywac vmware convertera ? Vmware converter jest DARMOWY.

--- @blog https://grzegorzkulikowski.info
Reply
0 Kudos
stworekpotworek
Contributor
Contributor

tak , probowalismy na poczatku , co z tego ze DARMOWY jak NIEDZIAŁA

Reply
0 Kudos
inleo
Leadership
Leadership

Mam jeszcze jeden hardkorowy pomysł...

1. Musisz w maszynie wirtualnej zainstalować identyczne ubuntu ( ta sama wersja) w takiej samej konfiguracji.

2. Po instalacji zbotować z płytki i podłaczyć sobie roota systemu zainstalowanego na dysku,

4. Serwer do przegrania spakować do tar'a z zachowaniem dat i uprawnien,

3. Po scp/nfs/smb/wathever przewalić tego tara, wywalić wszytkie pliki z podmontowanego systemu i rozpakowac do "/" wczesniej przygotowanego tara.

Nie jest to ani dobre ani profesjonalne rozwiązanie ale może zadzialac Smiley Happy

http://blog.inleo.pl @maciejlelusz
Reply
0 Kudos
Grzesiekk
Expert
Expert

Skoro probowales convertera i nie poszlo to czas na piechote. Wyslij mi PW , bo zapomne potem, w weekend bede mial dostep do starego dysku i wysle ci mailem swoja procedurke na p2v linuxa - jesli Ci zadziala to mozesz ja wkleic potem na forum zeby inni mieli w razie wypadku. Jesli nie zapomne o tym to sam wkleje tutaj ( pewnie zapomne ) . Jak dla mnie sprawdzala sie w 100%, jak Ci nie dziala to trzeba pewnie bedzie wprowadzic pare modyfikacji. Niemniej jednak nie martw sie gdyz to co chcesz zrobic jest w 100% wykonalne.

--- @blog https://grzegorzkulikowski.info
Reply
0 Kudos
Grzesiekk
Expert
Expert

PW nie wyslales, wiec nie wiem czy sobie poradziles czy nie. Niemniej jednak moze wkleje to co kiedys napisalem odnosnie p2v dla linux o/s. Jesli komus sie przyda to dobrze.

Linux P2V howto
Grzegorz Kulikowski 16.07.2008

Vmware converter option
Partimage option

1). Vmware converter option
There is a chance that vmware converter will be able to define the operating system on physical box(linux). We still do not know what is the % of linux that can we understood by vmware converter. For example on a box with fedora 5 , converter had no problems with converting it to virtual machine. On a machine with Centos 4.6 convert could not figure out what operating system is installed and the conversion was not started.
If the conversion starts without any problems below steps are to be taken to complete p2v.
go to www.sysresccd.org/ and download latest system rescue cd. It is a bootable linux that has many handy tools that will help us in later steps.
Be sure that you have the first CD from your linux distribution, or special rescue cd from the linux distribution that you are using
In order to boot the linux system again, we must boot the VM from the first cd from installation set in rescue mode . After that we have to boot machine in rescue mode, usually you boot the cd with : “linux rescue” but that can depend from distribution.
After step (c) installer should tell you that he found operating system on your drive and it is ready to be chrooted in : /mnt/sysimage (this is usual place for that)
If installer will not tell you that he has found existing OS, then you have to mount it manually in /mnt/sysimage : mount /boot , / in /mnt/sysimage . type fdisk –l  , if you want to see what partition will be used. After mounting it manually, or having it mounted by installer type : “chroot /mnt/sysimage/”
After last issued command you are inside of your linux which resides on the disk so watch our for commands as they are affecting your new VM.
You have to gather information whether your linux is supporting buslogic or lsilogic. If you have this information edit your /etc/modules.conf  (or modprobe.conf depends from distribution). Be sure that you change all aliases starting from scsi, to a module “BusLogic” , watch for the capital letters as they matter.  If you know that you want to use lsi logic then, change modules for “mptscsih”. Also be sure ! that all network aliases are changed to pcnet32 module.
Now: we have to create new initial ram disk according to new modules that we want to have available when booting : for buslogic I suggest : “ mkinitrd –v –f /boot/YOUR-KERNEL.img YOUR-KERNEL “  in case of lsi logic I suggest : “mkinitrd –v –f --preload mptbase /boot/YOUR-KERNEL.img YOUR-KERNEL” .
Be sure that this corresponds with your kernel that you will use, if you have more than 1 kernel, make sure that you are creating initrd for that actual kernel. To check whether you have one or more kernels go to: /boot/grub/grub.conf and read this file, be sure if you need to use smp or not, and if you have more than 1 kernel check the option :”default” which corresponds with which kernel should be used. Check if correct disks are given for grub to operate on !
If all above steps are completed we have to rewrite mbr. Run “grub” , and within grub write : “ root (hd0,0) “, after this issue save : “setup (hd0)” . and exit & reboot.
For figuring out the hd numbers : hd0 means “A” ,1-“B”,2-“C”,3-“D” so: sda is hd0 , sdb is hd1, and so one, about the partition number : hd0,0->  the second zero is like 1, so hd0,0 is sda1 , if hd0,1 then sda2 . , if hd1,0 sdb1 . Be sure to specify the /boot partition. Usually /boot is the first partition so my guess is that this will be : hd0,0 . But it is not a must.
If you encounter some additional errors I suggest to read below links :
http://www.vmware.com/support/esx21/doc/esx21admin_lsilogic_vms.html
http://virtualaleph.blogspot.com/2007/05/virtualize-linux-server-with-vmware.html
http://communities.vmware.com/blogs/JoeHan/2008/06/11/successful-physical-to-virtual-p2v-conversion-...
http://conshell.net/wiki/index.php/Linux_P2V
about grub
http://www.sorgonet.com/linux/grubrestore/
http://orgs.man.ac.uk/documentation/grub/grub_3.html

2. Partimage option
a) If in case vmware converter can’t recognize the system, we will use partimage.
b)Download system rescue-cd mentioned in 1)-a) . Boot the machine from sysres cd. Be sure that you have where to store the saved partition images.
c)About the storage for partition images :
c1: on netapp storage, request for a nfs share with write/read . withing the rescue cd configure network connection as : net-setup eth0  / net-setup eth1 / net-setup ethX . After you have configured network connection create a directory  : “cd $HOME && mkdir test “ , after this : “mount IP_NFS_SHARE:/X/Y/ test/”  where x and y are shared volumes from netapp. Make shure that you enter directory test : “cd test/” , and while being in test/ directory you run partimage. To run it, just type in console : “partimage”. Within partimage select partition to be saved on disk, specify filename, and press F5, select compression mode for the file, and again F5. Repeat this step with partimage until you have all partitions saved. Umount your test/ directory. Remember that you can not save a swap partition. See what is it’s size and write it down it will be needed in later steps. Create a new VM specifying linux system, and the scsi adapter(buslogic/lsi). Create a new virtual disk. Boot the vm from rescue cd. Setup the network. Do : “cd $HOME && mkdir test”. Then mount the directory with images through nfs: “mount IP_NFS_SHARE:/X/Y test/”. Enter the test/ directory. Run gparted, to create the partition on which you will be copying the images. Remember to create also a swap partition. Run partimage, and resport partitions on the new ones which we have created.

C2: if you know that you still have some free space on the disks, you can create an ext3 partition just for storing the partition images. Being in rescue cd system, type:”gparted” and create another partition from free space. After you have create a partition. Mount this partition : “cd $HOME && mkdir test && mount /dev/sdXY test/” where x and y are the disk and partition number. Remember to enter the test directory before you run partimage :”cd test/” . Run partimage and save the partitions . Your partitions images are now ready to copy them via scp to esx on which you will host the vm.  In Virtual Center create a new VM and specify whether you will you lsi or buslogic in vm “edit settings”. Besides creating a new disk for the linux machine, create a second disk that we will use to copy partition images on it. Boot the new vm from rescue cd. Setup network, and copy via scp, partitions images from esx, to the 2nd disk you have created for this vm. Remember to partition it first using gparted and then mount it as a filesystem. If you have now your partition images on the second virtual disk, you can create partitions using gparted on the first virtual disk, remembering the size of previous partitions from physical box. If this is done, go to the directory where you have mounted second disk with images. And from there run partimage, and restore the partitions onto the first disk. As we did not copy the swap partition , we also now create using gparted a partition for new swap. Make the same size partition as on physical box.Your linux machine disk is now created. In VM edit setting delete the second virtual disk.
d) The configuration of mbr/initrd/modules is the same as in the procedure per converter linux p2v, see section 1).

If you need more informations about partimage go to :
www.partimage.org/

Sorry ze w eng, ale pisalem to tylko w eng, jak ktos che przetlumaczyc to be my guest Smiley Wink.  Jesli beda jakies problemy to daj znac, postaram sie pomoc.

--- @blog https://grzegorzkulikowski.info
Reply
0 Kudos
kszafer
Contributor
Contributor

Hi

Thank You for Your email. I'm on the business trip with limited access to Internet. Please expect some delays in answer.

Kindly Regards

Krzysztof Szafer

Reply
0 Kudos