Showing posts with label vmware workstation pro 15. Show all posts
Showing posts with label vmware workstation pro 15. Show all posts

Thursday, February 21, 2019

VMware Workstation Pro 15] 19. Configuring Shared Disks


Hello, guys. You will figure out how to configure shared disks in VMware Workstation Pro in this post. When you finish this practice, you will be able to create your test environment for testing cluster volume managers, cluster file systems, cluster server solutions, virtualization solutions and so on.



Please note that I don't explain about CLVM and GFS2 in this post. it is just an example of using a shared disk. I will post about these in the future.


Preparing the Test Environment

Please, create two virtual machines with the following spec:

Virtual machine name: CentOS601, CentOS602
Hardware compatibility: Workstation 15.x
Guest operating system: Linux/CentOS 6 64-bit
Processors: 1 Socket/2 Cores
Memory: 2048 MB
Network connection: VMnet5
I/O controller types: LSI Logic
Virtual disk type: SCSI
Disk: 20 GB
Display: Uncheck Accelerate 3D graphics

Install CentOS 6.6 on both virtual machines. You can download the relevant ISO files from the following website.

http://vault.centos.org/6.6/isos/x86_64/

When installing, select the set of software as shown below.




If the installation is finished, install VMware Tools. If you don't know how to install VMware Tools, refer to the following post.

https://sunguruitchannel01.blogspot.com/2019/02/vmware-workstation-pro-15-installing.html

Add the following to the /etc/hosts file.

192.168.5.21 centos601
192.168.5.22 centos602

Set the IP address.

CentOS601
CentOS602
  IP Address : 192.168.5.21/24
  Gateway : 192.168.5.254
  DNS : 1.1.1.1
  IP Address : 192.168.5.22/24
  Gateway : 192.168.5.254
  DNS : 1.1.1.1

Connect the CentOS-6.6-x86_64-bin-DVD1.iso file to the CDROM of the virtual machine and execute the following commands. Both virtual machines.

[root@centos601 ~]# cd /media/CentOS_6.6_Final/Packages/
[root@centos601 Packages]# rpm -ivh lvm2-cluster-2.02.111-2.el6.x86_64.rpm 
warning: lvm2-cluster-2.02.111-2.el6.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: NOKEY
Preparing...                ########################################### [100%]
   1:lvm2-cluster           ########################################### [100%]
[root@centos601 Packages]# rpm -ivh gfs2-utils-3.0.12.1-68.el6.x86_64.rpm 
warning: gfs2-utils-3.0.12.1-68.el6.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: NOKEY
Preparing...                ########################################### [100%]
   1:gfs2-utils             ########################################### [100%]
[root@centos601 Packages]# lvmconf --enable-cluster
[root@centos601 Packages]# shutdown -h now


Creating the virtual disk for sharing

Open File Explorer and create a folder for the shared disks. Then open the CMD window and execute the following commands for creating a virtual disk. You and my folder path may be different.

M:\>mkdir Shareddisks
M:\>cd Shareddisks
M:\Shareddisks>vmware-vdiskmanager -c -s 5GB -a lsilogic -t 4 CentOS6_CLVM_Disk01.vmdk

Please, select Editor virtual machine setting for adding the virtual disk you just created to the virtual machine.


click the Add button


Select Hard Disk and SCSI.


Select Use an existing virtual disk and click the Browse button. Then select the virtual disk file you just created. When you press the Finish button, a small window appears. Click the Keep Existing Format button.


Press the Advanced button for additional settings. Then set the device node and virtual disk mode.


Once you have finished setting up, you will see the added disk information as shown below.


Now edit the virtual machine's configuration file with the notepad. Just add the highlighted part.


If you finish, power on both virtual machines. Ignore the warning message.



Creating CLVM and GFS2 file system.

Copy the following and apply it to your virtual machines. To simplify testing, disable the firewall and SELinux features.

[root@centos601 ~]# vi a.sh


sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
setenforce permissive
service iptables stop
chkconfig iptables off 
chkconfig NetworkManager off
service NetworkManager stop
chkconfig cman on
chkconfig clvmd on
chkconfig gfs2 on
chkconfig acpid off

[root@centos601 ~]# bash a.sh
[root@centos601 ~]# vi /etc/cluster/cluster.conf
<cluster name="cl01" config_version="2">
   <cman two_node="1" expected_votes="1"/>
   <clusternodes>
     <clusternode name="centos601" nodeid="1">
         <fence>
         </fence>
     </clusternode>
     <clusternode name="centos602" nodeid="2">
         <fence>
         </fence>
     </clusternode>
   </clusternodes>
   <fencedevices>
   </fencedevices>
   <rm>
   </rm>
</cluster>

[root@centos601 ~]# shutdown -r now

Let's now create a cluster volume and a cluster file system.

[root@centos601 ~]# service cman status
cluster is running.

[root@centos601 ~]# service clvmd status
clvmd (pid  2104) is running...
Clustered Volume Groups: (none)
Active clustered Logical Volumes: (none)

[root@centos601 ~]# lsblk | grep disk
sda                         8:0    0   20G  0 disk 
sdb                         8:16   0    5G  0 disk 

[root@centos601 ~]# pvscan
  PV /dev/sda2   VG vg_os   lvm2 [19.51 GiB / 0    free]
  Total: 1 [19.51 GiB] / in use: 1 [19.51 GiB] / in no VG: 0 [0   ]

[root@centos601 ~]# pvcreate /dev/sdb
  Physical volume "/dev/sdb" successfully created

[root@centos601 ~]# vgcreate vg_cl01 /dev/sdb
  Clustered volume group "vg_cl01" successfully created

[root@centos601 ~]# lvcreate -L 1G -n data01_vol vg_cl01
  Logical volume "data01_vol" created

[root@centos601 ~]# blkid /dev/vg_cl01/data01_vol 
[root@centos601 ~]# mkfs -t gfs2 -p lock_dlm -t cl01:data01 -j 2 /dev/vg_cl01/data01_vol
This will destroy any data on /dev/vg_cl01/data01_vol.
It appears to contain: symbolic link to `../dm-2'

Are you sure you want to proceed? [y/n] y

Device:                    /dev/vg_cl01/data01_vol
Blocksize:                 4096
Device Size                1.00 GB (262144 blocks)
Filesystem Size:           1.00 GB (262142 blocks)
Journals:                  2
Resource Groups:           4
Locking Protocol:          "lock_dlm"
Lock Table:                "cl01:data01"
UUID:                      800caabd-9d7e-3f7e-721c-9f4b307e312f

[root@centos601 ~]# blkid /dev/vg_cl01/data01_vol 
/dev/vg_cl01/data01_vol: LABEL="cl01:data01" UUID="800caabd-9d7e-3f7e-721c-9f4b307e312f" TYPE="gfs2" 

[root@centos602 ~]# pvscan
  PV /dev/sdb    VG vg_cl01   lvm2 [5.00 GiB / 4.00 GiB free]
  PV /dev/sda2   VG vg_os     lvm2 [19.51 GiB / 0    free]
  Total: 2 [24.50 GiB] / in use: 2 [24.50 GiB] / in no VG: 0 [0   ]

[root@centos602 ~]# vgscan
  Reading all physical volumes.  This may take a while...
  Found volume group "vg_cl01" using metadata type lvm2
  Found volume group "vg_os" using metadata type lvm2

[root@centos602 ~]# lvscan
  ACTIVE            '/dev/vg_cl01/data01_vol' [1.00 GiB] inherit
  ACTIVE            '/dev/vg_os/root_vol' [15.51 GiB] inherit
  ACTIVE            '/dev/vg_os/swap_vol' [4.00 GiB] inherit

[root@centos602 ~]# blkid /dev/vg_cl01/data01_vol
/dev/vg_cl01/data01_vol: LABEL="cl01:data01" UUID="800caabd-9d7e-3f7e-721c-9f4b307e312f" TYPE="gfs2" 

[root@centos601 ~]# mkdir /data01
[root@centos601 ~]# mount /dev/vg_cl01/data01_vol /data01
[root@centos601 ~]# sed -i '$ a\/dev/vg_cl01/data01_vol /data01 gfs2    defaults        0       0' /etc/fstab

In the sed command, press the Ctrl+v+Tab key at the same time to apply the tab.

[root@centos601 ~]# umount /data01
[root@centos601 ~]# mount /data01
[root@centos601 ~]# df -Ph /data01
Filesystem                      Size  Used Avail Use% Mounted on
/dev/mapper/vg_cl01-data01_vol  1.0G  259M  766M  26% /data01

[root@centos602 ~]# mkdir /data01
[root@centos602 ~]# mount /dev/vg_cl01/data01_vol /data01
[root@centos602 ~]# sed -i '$ a\/dev/vg_cl01/data01_vol /data01 gfs2    defaults        0       0' /etc/fstab
[root@centos602 ~]# touch /data01/file1

[root@centos601 ~]# ls -l /data01
total 4
-rw-r--r-- 1 root root 0 Feb 22 15:13 file1

Configuring Shared Disks is not easy. And if you use VMware Workstation for operating system testing or program development testing, you will rarely use this feature. However, if you are interested in or are planning to deal with virtualization and cluster server solutions, this feature will be quite useful for you.

You have acquired the skill to configure shared disks in VMware Workstation Pro. I encourage you to practice a few more times to become proficient. This feature will be needed to upgrade your IT skills. See you next. Thank you.



Wednesday, February 20, 2019

VMware Workstation Pro 15] 18. Configuring VNC connections


Hello, guys. You will figure out how to configure a virtual machine as a VNC server in VMware Workstation Pro in this post. When you finish this practice, you will be able to connect your virtual machine from a remote system for your test.


Configuring VNC connections

VNC allows you to connect to a remote system and control mouse and keyboard. It works as a server-client model and requires that related programs be installed on each system. VMware Workstation Pro 15 provides the VNC Connections feature to connect remotely your virtual machines. 

If you enable this feature in the Virtual Machine Settings window, the virtual machine behaves like a VNC server. You do not need to install a VNC program to your virtual machines. On Windows host, you can assign a port number to your virtual machine in the range from 5901 to 6001. If the Linux host, only the root can listen to ports up to port number 1024.



You must allow the service port in your host operating system firewall.



I used the TightVNC Viewer for testing. The related program can be downloaded from the following website.

https://www.tightvnc.com/download.php

And I installed by excluding the VNC Server function when installing on the host OS. After running TightVNC Viewer, please enter your host IP address when the following window appears.


After entering the password, press the OK button and you will see the VNC connection screen as shown below.


You have acquired the skill to configure VNC connections in VMware Workstation Pro. I encourage you to practice a few more times to become proficient. This feature will be needed to collaborate with other people. See you next. Thank you.



VMware Workstation Pro 15] 17. Using Shared Folders


Hello, guys. You will figure out how to set the Shared Folders feature in VMware Workstation Pro in this post. When you finish this practice, you will be able to share folders or directories of your host to virtual machines for your test.


The Shared Folders Feature

What would you do if you wanted the virtual machine to use the files that exist on the host operating system? You can configure the FTP server or use the Drag and Drop feature. If you have to make the same files available to multiple virtual machines, these methods will be inefficient. This is because the same files are stored redundantly on your host.

The Shared Folders feature allows you to share folders or directories on a host to virtual machines. This feature can increase the efficiency of your host storage usage.


Using Shared Folders

To use this feature, you must first install VMware Tools on the guest OS of your virtual machine.  

Select the virtual machine in the library and select VM > Settings from the menu bar for the setting. Select Shared Folders on the Options tab. Then select the Always enabled radio button as shown below and click the Add button to select the folder to share.


When the Shared Folder Wizard window appears as shown below, click the Next button and set the host folder to share.


To set the shared folder to read-only, check Read-only. click the Finish button to finish the setup.


If Windows guest OS, check the Map as a network drive in Windows guests checkbox.


Now you are able to see the host folder in your virtual machines.

Windows 10:


Ubuntu Server 18.04:


CentOS 7.6:


You have acquired the skill to set the Shared Folders feature in VMware Workstation Pro. I encourage you to practice a few more times to become proficient. Save your storage by using this feature. See you next. Thank you.


VMware Workstation Pro 15] 16. Using the Copy and Paste & the Drag and Drop Features


Hello, guys. You will figure out how to use two features provided by VMware Workstation Pro in this post. When you finish this practice, you will be able to use these features efficiently for your test.


Using the Copy and Paste Feature

Suppose you have a set of commands that you use frequently for testing. And what if you want to use these commands easily in a virtual machine? The easiest way would be to copy the text from the document stored on your host and use it in a virtual machine. If VMware Tools is installed in the Guest OS installed in the virtual machine, you can use the Copy and Pasted feature. This feature enables copying and pasting text between the host and the virtual machines.


The Copy and Paste feature is available for Windows, Linux, Solaris 10 Guest OS. Linux is available in the X Windows environment and Solaris in the Xorg X Server and JDS / Gnome environments.


Using the Drag and Drop Feature

If VMware Tools is installed in the Guest OS installed in the virtual machine, you can use the Drag-and-Drop feature. This feature can be used to copy files between the host and the virtual machines. How to use is simple. Select the file to copy. Then Drag and drop the file where you want it to be copied.


If you need to copy to multiple virtual machines, I recommend using the Shared Folders feature.

You have acquired the skill to use two features. I encourage you to practice a few more times to become proficient. Save your valuable time by using these features. See you next. Thank you.


Tuesday, February 19, 2019

VMware Workstation Pro 15] 14. Installing VMware Tools on Windows 10

Hello, guys. You will figure out how to VMware Tools on Windows 10 operating system in this post. When you finish this practice, you will be able to use the features provided by VMware Tools on your Windows 10.

I strongly recommend that you install VMware Tools after installing Windows 10 operating system on a virtual machine. VMware Tools is the utilities which enhance the performance of the guest operating system.

VMware Tools Benefits and Features

This provides you with the following benefits:

- ThinPrint
- Shared folders
- Faster graphics performance
- Improved mouse performance
- Automatic grabbing and releasing of the mouse cursor
- File drag and drop between your host os and a guest os
- Text copy and paste between your host os and a guest os
- And so on

In particular, copying and pasting text will greatly reduce your computer language testing time.

Installing VMware Tools on Windows 10

select VM > Install VMware Tools from the menu bar for installing VMware Tools. And open Explorer. You can see VMware Tools mounted on the CDROM as following.


Double-click the D drive for installing VMware Tools. When the VMware Tools setup window appears as shown below, click the Next button. And Select Setup Type as Typical and press the Next button.


Click the Install button to proceed.


When the installation is finished, press the Finish button and reboot Windows 10.


The screen resolution will automatically adjust and the mouse will move more smoothly. And you can use the features provided by VMware Tools.

You have acquired the skill to install VMware Tools on Windows 10. I encourage you to practice a few more times to become proficient. Save your valuable time by using VMware Tools features. See you next. Thank you.