Update to the latest ESXI 6.7 patch version on an Intel NUC (offline update)

I recently bought an Intel NUC for my homelab (NUC7i5BNH with 64Gigs of RAM) which has been running ESXi for the past few months and I have been happy with its performance so far. Fear for the worst, I noticed a few minor UI issues in the build that I was running which had been really bugging me. For Example: When using the search bar in the HTML5 UI, it partially hides the last search result in the list which was super annoying.

Luckily, VMware fixed these issues in one of the newer 6.7 patch releases and this blog post details on how I updated ESXi 6.7 U3 to the latest patch release on my NUC. To be precise, the upgrade was from ESXi-6.7.0-20190802001-standard (Build 14320388) to ESXi-6.7.0-20200604001 (Build 16316930). PS: I am not using vCenter in my homelab.

Short Version:

1. Backup your VMs/ESXI configuration. Download the latest patch from VMware’s website (Link).
2. Upload the ESXI patch release to the server’s datastore.
3. SSH into the NUC and get the full location of uploaded patch in your datastore. Find the profiles bundled within the patch file.
4. Put the ESXI server in maintenance mode and start the update.
4. Once update is complete, reboot the NUC, disable maintenance mode and you are good to go.

[Disclaimer: Please review VMware’s best practices for performing an ESXI upgrade which also includes taking backup of your ESXI configuration + VMs. if you plan to upgrade for a production system, make sure all necessary backups are taken before attempting the procedure. My NUC which is the 5th gen, the update worked right of the box without any customization. If you are running the new 10th generation Intel NUC, then you may need have make some modification to the VIBs for the upgrade to work.]

Long Version:

Go to VMware’s patch page  and download the latest patch version for the ESXI release (Link).

In my case, I downloaded the latest patch which at the time of writing this post was ESXi670-202006001.zip.

Before the upgrade, my Intel NUC was running the below build:

[[email protected]:~] vmware -vl
VMware ESXi 6.7.0 build-14320388
VMware ESXi 6.7.0 Update 3

-To check the volumes in the datastore. I did upload my patch to the ssd datastore which is a symlink.

[[email protected]:~] ls /vmfs/volumes/ -l
total 1792
drwxr-xr-x    1 root     root             8 Jan  1  1970 317122ee-8c7e716b-adf9-8414e6a14676
drwxr-xr-x    1 root     root             8 Jan  1  1970 5e4867ab-521f3ade-c1f4-94c691adc828
drwxr-xr-t    1 root     root         86016 Jun 26 18:10 5e486a9d-f29d23c4-81b6-94c691adc828
drwxr-xr-x    1 root     root             8 Jan  1  1970 dafb9eea-924c7ebf-4eba-5b7ab8fcbb15
lrwxr-xr-x    1 root     root            35 Jun 26 18:16 ssd -> 5e486a9d-f29d23c4-81b6-94c691adc828

Verify the full path/location of the uploaded image.

[[email protected]:~] ls /vmfs/volumes/5e486a9d-f29d23c4-81b6-94c691adc828/ESXi670-202006001.zip
/vmfs/volumes/5e486a9d-f29d23c4-81b6-94c691adc828/ESXi670-202006001.zip

Using esxcli, find the profiles that are bundled with the offline installer. The profile name will be used later when performing the upgrade.

[[email protected]:~] esxcli software sources profile list -d /vmfs/volumes/5e486a9d-f29d23c4-81b6-94c691adc828/ESXi670-202006001.zip
Name                             Vendor        Acceptance Level  Creation Time        Modification Time
-------------------------------  ------------  ----------------  -------------------  -------------------
ESXi-6.7.0-20200604001-standard  VMware, Inc.  PartnerSupported  2020-06-04T02:21:11  2020-06-04T02:21:11
ESXi-6.7.0-20200604001-no-tools  VMware, Inc.  PartnerSupported  2020-06-04T02:21:11  2020-06-04T02:21:11
[[email protected]:~]

Place the ESXI host in maintenance mode before starting the upgrade.

[[email protected]:~] esxcli system maintenanceMode set -e true

Verify that ESXI is running in Maintenance mode.

[[email protected]:~] esxcli system maintenanceMode get
Enabled

The output “Enabled” means that the host is in maintenance mode.

To perform the patch upgrade, pass the path and the profile as well.

[[email protected]:~] esxcli software profile update -d /vmfs/volumes/5e486a9d-f29d23c4-81b6-94c691adc828/ESXi670-202006001.zip -p ESXi-6.7.0-20200604001-standard
Update Result
Message: The update completed successfully, but the system needs to be rebooted for the changes to be effective.
Reboot Required: true
VIBs Installed: VMW_bootbank_ixgben_1.7.1.16-2vmw.670.3.104.16075168, 
....
[[email protected]:~]

Once the update is complete, reboot the ESXI server.

[[email protected]:~] reboot

Once the host is back up, SSH into the ESXI host. The host will still be in maintenance mode which is expected.

[[email protected]:~] esxcli system maintenanceMode get
Enabled

Disable maintenance mode

[[email protected]:~] esxcli system maintenanceMode set -e false
[[email protected]:~] esxcli system maintenanceMode get
Disabled

Now, verify that the update completed and is running the new build.

[[email protected]:~] vmware -vl
VMware ESXi 6.7.0 build-16316930
VMware ESXi 6.7.0 Update 3
[[email protected]:~]

Well, Thats it folks!! Hope this helps.

 

PS: I anticipated the update process to be super confusing and tedious. However, it turned out to be fairly simple thanks to jeffreykusters and VMware’s instructions which I have credited them for below).

Credits/References/Sources:

jeffreykusters
Vmware

Make CentOS virtual machine in VirtualBox use the host’s VPN Connection

If your host PC (in my case Windows 10) is connected to a VPN but your CentOS 6.x VM is not using the VPN, then do the following:

1: Power off your CentOS VM.

2: Right click your centos machine in virtualbox and then click “Settings“.

right click your centos virtual machine and click settings (Screenshot)

3: Click “Network” and change the Adapter Settings to “NAT“.

change virtualbox network settings to NAT (Screenshot)

4: Now power on your centos virtual machine.

5: Once your VM boots up, login and then restart the network service. You can use the following CLI command “service network restart“.

Your CentOS virtual machine should now to able to use the VPN connection and use it accordingly. Do verify the same in your virtual machine. Hope this helps!

Do like and subscribe if this guide helped you. Cheers!

Install Kali Linux in virtualbox (using ova file)

This is how I installed Kali Linux in virtualbox using the ova file method in my windows 10 PC along with its screenshots.

Requirements:

  1. Kali Linux 2019.1 Preinstalled ImageDownload Link (Torrent)  (~3.2 GB) [Updated link o latest Kali Version]
  2. VirtualBox: Download Link (~200 MB)
  3. CPU that supports Virtualization.
  4. Atleast 8GB of free disk space
  5. 7-zip: Download Link (~1.4 MB) [ Note: Winrar is another alternative you could use instead of 7-zip.]
  6. Virtual Box Extension Pack: Download Link (~22 MB) [Optional]

Installation Procedure:

The first thing you need to do is go ahead download and install Virtualbox in your system. Then download the Kali Linux ova file mentioned above and extract it using 7-zip or Winrar. The extracted file would be a .ova file format which is a pre-installed Kali Linux machine. Using a pre-installed file saves us a lot of time as we don’t have to go through the whole installation process.

Now, open VirtualBox:

open virtualbox

Then click on “File” and then click on “Import Appliance“.

click file import appliance

Click on the folder icon as shown below.

import ova file window

Now, browse to and select the extract .ova Kali Linux image file and click on “Open“.

select kali linux ova file

You would now see a window called “Appliance settings” where you can configure stuff like the name of your VM, the amount of RAM to be allocated to your Kali Linux VM etc.

kali linux appliance settings

If you want to change the name of the VM, simply click on the text and you can change it according to your will.

changing vm name

Finally, click on “Import” and wait for a few moments to import the Kali Linux Appliance.

click import to load kali linux appliance

importing kali linux appliance progress bar

Now, right click on your Kali Linux Virtual machine as shown below and click on “Settings“.

open kali linux virtual machine Settings

If you need to adjust the amount of RAM, click on “System” and you can move the slider accordingly. I would suggest atleast a minimum of 2048 MB (2GB) of RAM.

select ram for your Kali Linux VM

Now, click on “Network” as shown below and select “Bridged Adapter” and then click on “OK“.

Select Kali Linux network mode to Bridged Adapter

Click on your Kali Linux VM and then click on Start as shown below.

start kali linux in virtualbox

You should now be able to see the grub menu. Hit “Enter” in your keyboard.

kali linux grub menu

Now, login to your Kali Linux machine with the default username as root and password toor.

Note: If you are using newer Kali versions (from year 2020 ), the username and password is “kali”.

Ref: https://www.kali.org/docs/introduction/default-credentials/

kali username

kali password

You should now be booted into your Kali Linux desktop.

kali linux logged in

Customize Kali (Optional): 

I would like to make some minor changes to make sure the VM is not interrupted during pen testing. This section is purely optional, you can skip to the next section if you don’t want to customize it.

Click on the triangle pointing downwards in the upper right corner and then click on the “Settings” icon.

Kali Linux drop down menu

This will bring you the “All Settings” window as shown below. Click on “Date & Time“.

all settings menu

You can change the time zone to your time zone.

change time zone

Now, go back to the “All Settings” window and then click on “Privacy“.

select privacy in all setting menu

You would see a screen similar to the one below:

default privacy settings

Now, disable “Automatic Screen Lock” by moving the slider.

disable auto screen lock

Go back to “All Settings“, then click on “Power“.

click on power in all settings

Now, select Blank Screen option as “Never” and turn off  “Automatic Suspend” as shown below.

disable blank screen and automatic suspend

Update Kali Linux:

Open the terminal window by clicking on the icon as shown below:

open terminal

This is what the terminal window would look like in a Kali Linux system.

Kali Linux Terminal

Enter the following commands in the terminal to update your Kali Linux system.

apt-get clean && apt-get update -y
apt-get upgrade -y && apt-get dist-upgrade -y

This may take a while depending on your internet connection for the update to complete.

And that is it for setting up Kali Linux in virtualbox to get started with pentesting (only for ethical hacking and for purely educational purposes).

If you have any sort of queries regarding this installation, just leave a comment and will get back to you. I will be posting some ethical hacking tutorials in the future, so stay tuned.

Double quotes not working in Linux terminal – [Solution]

I encountered an issue in my CentOS VM where whenever I type the  (single quote) or the  (double quotes) in the terminal, they don’t get displayed. I did the following to fix the issue:

In your terminal window, type the following:

# setxkbmap -layout us

You should now be able to use single, double quotes or tilde symbols in your terminal.

The above command simply changes the keyboard layout to English (US) and this is under the assumption that you are actually using a English (US) keyboard in your PC.

[Note: English (US) layout is different from English (US) International keyboard layout].

You can check the screenshot below for reference.

setxkbmap -layout us

Thanks and credits to this post that helped me resolve this issue.

Feel free to leave a comment in the comments section down below. Happy troubleshooting! Cheers!

How To fix “This kernel requires an x86-64 CPU, but only detected an i686 CPU. This processor is unsupported in RHEL 7.” when booting from VirtualBox

Error: This kernel requires an x86-64 CPU, but only detected an i686 CPU.
This processor is unsupported in RHEL 7. 

centos-boot-error

[Note: This tutorial is under the assumption that your physical CPU is 64-bit and your installed host OS is 64-bit and will only work in these circumstances.]

Cause:

This mainly happens due two reasons:

  1. If you have a 64-bit OS installed but the VirtualBox OS type is accidentally changed/set to 32-bit after installation.
  2. If Vt-X (Virtualization) is disabled in the BIOS. (This can happen if you reset your BIOS to default settings which may have disabled Vt-X  bit).

Solution:

Step 1: Right Click on the Centos/RHEL OS which is giving you the error and then click on “Settings“.

virtualbox settings

Step 2: In General Tab, check the OS Type and see if you are able to change to “Redhat 64-bit” and follow step 4.

change os type

Step 3: If you are only able to see 32-bit entries in the OS type list and your physical CPU supports 64-bit, this means that Vt-X is disabled in your BIOS. So, restart your PC and boot into your BIOS, enable Vt-X.

For reference, I have a Asus Maximus VII Ranger Motherboard and here is how I enabled Vt-X in my BIOS.

enable vt-x

[Optional: If your CPU supports Vt-d, enable that too, it will improve functionality and performance of your Virtual Machine. Some CPUs will not have the Vt-d function, if you dont have it then you can ignore it]

optional step to enabled vt-d

Step 4: Restart your computer and boot back your CentOS/RHEL VM and it should come right up.

centos boot error fixed

Hope this fixed the issue. If this tutorial helped you,do  leave a thumbs up a comment below. Hope this helps! 🙂

If you have any sort of queries,  just leave a comment below and will get back to you. Don’t forget to follow my blog to get future updates! 😀

Regards,
ΞXΤЯ3МΞ