Home > Computers and Internet > Esxi 4.1.0 slic bios modify.

Esxi 4.1.0 slic bios modify.

Version Esxi 4.1.0 Build 348481
Adding Slic 2.1 to the bios under linux (I’m using fedora 14):

There’s two way to get modified bios, One is to replace the rom file in s.z, and another is to load dedicate rom file for every VM using configuration settings.
———————–
Way I:

Step 1: Enable SSH on ESXi Server and find s.z

enable ssh from console.
ssh to host and find s.z
~ # find / -name s.z
/vmfs/volumes/d106897a-21396673-f6f9-ddabebae8192/s.z

Step 2: Getting the vmx file

copy the s.z to a location to a temp folder, I copy to the datastore folder.

~ # cp /vmfs/volumes/d106897a-21396673-f6f9-ddabebae8192/s.z /vmfs/volumes/datastore1/temp/
~ # cd /vmfs/volumes/datastore1/temp/
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp # cp s.z s.gz
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp # gunzip s.gz
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp # vmtar -x s -o s.tar
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp # tar xf s.tar

copy the vms file under bin folder to another temp folder:

/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp # mkdir ../modified
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp # cp bin/vmx ../modified/

open vSphere Client (under windows)and open configuration-> storage, then browse the datastore1 and download the vms under modified folder to local drive.
copy the vms file to linux.

Step 3: Extract bios440.rom from vmx

copy vms to a temp folder under user’s home and extract bios file.

[neo@fedora temp]$ objdump –headers vmx
output like this:
vmx:     file format elf64-x86-64

Sections:
Idx Name          Size      VMA               LMA               File off  Algn
0 .interp       0000001c  0000000000000238  0000000000000238  00000238  2**0
CONTENTS, ALLOC, LOAD, READONLY, DATA

30 bios440       00034fc7  0000000000000000  0000000000000000  00844ddb  2**0
CONTENTS, READONLY

[neo@fedora temp]$ objcopy vmx –output-target=binary –only-section=bios440 –set-section-flags bios440=alloc bios440.rom.zl
ls to get the size of bios440.rom.zl
[neo@fedora temp]$ ls -l
-rw-rw-r– 1 neo neo   217031 Jun 28 15:00 bios440.rom.zl
[neo@fedora temp]$ perl -e ‘use Compress::Zlib; my $v; read STDIN, $v, 217031; $v = uncompress($v); print $v;’ < bios440.rom.zl > bios440.rom

then you get the bios440.rom bin file. copy to windows and then do the modify. Also you can do the modify under linux if you know how.

Step 4: Modify BIos file.

download phoenixtool and RW
run RWeverything and click acpi, wait then
save all (ctrl+F2) using RW as acpitbls.rw
open phoenixtool and load the bios440.rom, add slic 2.1 file and apply.
copy the bios440_SLIC.rom back to linux.

Step 5: Compress bios440.rom

[neo@fedora temp]$ perl -e ‘use Compress::Zlib; my $v; read STDIN, $v, 524288; $v = compress($v); print $v;’ < bios440_SLIC.rom > bios440_mod.rom.zl

Step 6: Delete section bios440 from vmx file

[neo@fedora temp]$ objcopy –remove-section bios440 vmx
[neo@fedora temp]$ objdump –headers vmx

checked there’s no bios section anymore.

Step 7: Put bios440_mod.rom.zl into vmx

[neo@fedora temp]$ objcopy –add-section bios440=bios440_mod.rom.zl vmx
[neo@fedora temp]$ objdump –headers vmx

vmx:     file format elf64-x86-64

Sections:
Idx Name          Size      VMA               LMA               File off  Algn

…..
42 bios440       0003531e  0000000000000000  0000000000000000  00a93785  2**0
CONTENTS, READONLY
copy back vmx back to modified folder.

Step8: Build a new s.z file

copy vmx to temp/bin to replace vmx
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp/bin # cp ../../modified/vmx ./
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp/bin # chmod 755 vmx
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp/bin # chown 201.201 vmx
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp/bin # chmod u+s vmx
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/temp # tar cf ../modified/s.tar *
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/modified # vmtar -c s.tar -o s.tar.vtar
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/modified # gzip s.tar.vtar
/vmfs/volumes/4d8b2d15-6717c527-2dcd-000e0cc12447/modified # cp s.tar.vtar.gz    /vmfs/volumes/d106897a-21396673-f6f9-ddabebae8192/s.z

Reboot.
—————
Way II:

Same as the way I and you get the original rom file and get it modified. then upload the rom file to a folder of esxi server.
Edit the VM’s configuration file by adding biso440.filename=”location to the file and name”. the VM’s configuration file is under the same folder of the VM and name as VMname.vmx.

Advertisements
  1. pix
    July 27, 2011 at 12:38 AM
    • July 27, 2011 at 5:50 PM

      Hi Pix,

      Yes, that’s the first step I ever tried. But your tools can’t find my s.z file. My s.z file was not in any Hyperdvisor* folder. I checked the messages showed in your tools that find what’s the tool did and browsed some post from mydigitalllife web site then find the way out.

      Thanks for your information. I have no idea that why my s.z file was not in the Hypervisor folders. Any way, the new rom file works thought some times the guest os get ‘recovered from serious problem’.

      Neo.

  2. here
    September 7, 2011 at 8:59 AM

    Hi, do you have the correct sequence fro ESXi 5?

    • September 7, 2011 at 10:18 AM

      Hi Here,

      Not yet, I havn’t install Esxi 5 yet.

  3. here
    September 7, 2011 at 12:35 PM

    Ok, thanks.. I am trying to follow your steps but I am stuck on step 10.. where are step 8 and 9? am I missing something? everything goes well until step 7…. and then the rest is not very clear…
    when following:
    cp s.tar.vtar.gz /vmfs/volumes/d106897a-21396673-f6f9-ddabebae8192/s.z
    from step 10 the file becomes huge! are we supposed to delete some files from /temp?
    thanks!

    • September 30, 2011 at 11:24 PM

      Dear Here,

      Sorry, there’s no step 8 and 9, type, and for step 7, the last line should be ‘copy back vmx back to modified folder.’
      the purpose of step 8 is to try to replace the vmx file under bin with new one and then creating new s.z file. to create s.z file you have to do it under ssh command of Esxi 4. tar the folder, then using vmtar to tar the tar file again. and then gzip it and rename it. Then replace the old s.z file with the new one. OK.
      For me, no need to delete any files under s.z. The source file is about 69.3MB, almost the same with the modified one.

  4. October 2, 2011 at 7:36 PM

    Did anyone get this working with ESXi 5 yet?

    • October 6, 2011 at 10:51 PM

      Dear Mickrussom,

      Please check this page, seems that they have a solution.

  5. Kang Sun
    July 23, 2015 at 6:40 AM

    Hello, just saw your post and try to follow to modify the guest bios.
    Is there a better way of doing this now?
    Anyway following your step4 . I am not sure what is SLIC and when and where acpitbls.rw is applied. I simply use Pheonix BIOS Editor Pro to manually editing Dmi section to my need, build the BIOS.
    However, on step 7 I when putting bios440_mod.rom.zl into vmx, I got “objcopy:stMISou9: can’t add section ‘bios440’: File in wrong format”.
    What was wrong here? Please help!
    Thanks!
    -Kang Sun

    • July 23, 2015 at 7:46 AM

      Hi Kang,

      This is few years ago. Now vSphere is version 6 and I haven’t touch bios modification for long times.
      You may try Method II, just to modify the ROM setting for each VMs you need.

      Neo

  6. Kang Sun
    July 23, 2015 at 12:39 PM

    Thanks! Method II is what I need. Reading your instruction again I realized Once I got the modified BIOS file bios_mod.rom, I could have stopped there.
    I was trying to visualize IBM HMC Server. I could do it easily on VirtualBox by adding Dmi parameters with VboxManage. Now I can do the same on VMWare, too.
    Thank you very much!
    –Kang Sun

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: