Could not record any guest kernel reference relocation symbols using Intel Processor Trace (Intel PT) - intel

We have set up one VM (Virtual Machine) (Ubuntu Desktop 16.04) on VMM (virtual-manager) running QEMU / KVM. We are using Ubuntu Desktop 16.04 as our HOST OS. We execute suspicious C language code on our guest VM. We want to intercept certain instructions executed in the form of suspicious C language code on our guest VM from our HOST OS.
To accomplish this task, We are trying to capture Intel PT traces for our guest OS using the below command on our host. We're getting the following error when running this command on our terminal.
$ perf kvm --guest --guestkallsyms=guest-kallsyms --guestmodules=guest-modules record -e intel_pt//
Couldn't record guest kernel [0]'s reference relocation symbol.
" guest-kallsyms and guest-modules are the kallsyms and module files we copied from the guest onto our host. "
Does perf kvm command support intel_pt//?
Our System Configuration:
Operating System: Ubuntu 16.04.6 LTS
Kernel: Linux 4.15.0-66-generic
Architecture: x86-64

Related

Starting Minishift VM ..... FAIL E1210 : "This computer doesn't have VT-X/AMD-v enabled. Enabling it in the BIOS is mandatory"

I was trying to install minishift on my local laptop.
I was following the below said steps as part of the process.
https://docs.okd.io/3.11/minishift/getting-started/preparing-to-install.html
Set up your virtualization environment
Download Minishift software for your operating system from the Minishift Releases page
Install Minishift
Start Minishift
Configure Minishift so you can use it efficiently
I did install VirtualBox (6.1.16) as part of virtualization. And disabled the Hyper-v and Windows Hypervisor platform (Windows Program Features on/off). But after downloading and installing minishift by configuring it under PATH environment variable. I run the the below command - minishift start from command prompt.
-- Starting profile 'minishift'
-- Check if deprecated options are used ... OK
-- Checking if https://github.com is reachable ... OK
-- Checking if requested OpenShift version 'v3.11.0' is valid ... OK
-- Checking if requested OpenShift version 'v3.11.0' is supported ... OK
-- Checking if requested hypervisor 'virtualbox' is supported on this platform ... OK
-- Checking if VirtualBox is installed ... OK
-- Checking the ISO URL ... OK
-- Checking if provided oc flags are supported ... OK
-- Starting the OpenShift cluster using 'virtualbox' hypervisor ...
-- Minishift VM will be configured with ...
Memory: 4 GB
vCPUs : 2
Disk size: 20 GB
-- Starting Minishift VM ..... FAIL E1210 00:01:26.829916 9000 start.go:499] Error starting the VM: Error creating the VM. Error with pre-create check: "This computer doesn't have VT-X/AMD-v enabled. Enabling it in the BIOS is mandatory". Retrying.
Error starting the VM: Error creating the VM. Error with pre-create check: "This computer doesn't have VT-X/AMD-v enabled. Enabling it in the BIOS is mandatory"
I verified the BIOS Setup for VT-x/AMD-v, and it is enabled already, so I am wondering why it is still throwing this error -
This computer doesn't have VT-X/AMD-v enabled. Enabling it in the BIOS is mandatory
I used this commands cdk-scripts to verify that machine is capable of virtualization before running minishift on it. Should work for win 10 and 7.
Feel free to check the commands out on your machine. You will need powershell for that purpose.
To answer to my question here -
I uninstalled the existing virtual box and managed to run the minishift from windows hypervisor option (Hyper-v Manager). I adjusted my application processes (to control RAM usage) and launched minshift successfully using available 4GB RAM (out of total 8 GB in my machine).

Failed to start domain SC-1

I am trying to bring common base architecture controller for my ovs setup on the esxi box sles linux os . when i try to bring up my controller i am getting the following error. Could you please help me out.
"unsupported configuration: Domain requires KVM, but it is not available. Check that virtualization is enabled in the host BIOS, and host configuration is setup to load the kvm modules."
Steps followed to bring up my controller
linux-u96x:~/cbavms/products # virsh define SC-1.xml
Domain SC-1 defined from SC-1.xml
linux-u96x:~/cbavms/products # virsh start SC-1
error: Failed to start domain SC-1
error: unsupported configuration: Domain requires KVM, but it is not available. Check that virtualization is enabled in the host BIOS, and host configuration is setup to load the kvm modules.
linux-u96x:~/cbavms/products #
KVM Software tools should be on the controller
patterns-sles-kvm_server - KVM Host Server 12-58.8
patterns-sles-kvm_server-32bit - KVM Host Server
patterns-sles-kvm_tools - KVM Virtualization Host and tools
patterns-sles-kvm_tools-32bit - KVM Virtualization Host and tools
qemu-kvm - Kernel-based Virtual Machine
virt-v2v - Convert a virtual machine to run on KVM
yast2-vm - Configure Hypervisor and Tools for Xen and KVM
check the hardware requirement as mentioned below:
1.1. Hardware Requirements¶
Currently, SUSE only supports KVM full virtualization on x86_64 hosts. KVM is designed around hardware virtualization
features included in AMD (AMD-V) and Intel (VT-x) CPUs. It supports virtualization features of chipsets, and PCI devices,
such as an I/O Memory Mapping Unit (IOMMU) and Single Root I/O Virtualization (SR-IOV)).
You can test whether your CPU supports hardware virtualization with the following command:
egrep '(vmx|svm)' /proc/cpuinfo
If this command returns no output, your processor either does not support hardware virtualization, or this feature has been
disabled in the BIOS.
The following Web site identifies processors which support hardware virtualization:
how to enable the vx-t in virtual machine :
https://forum.ivorde.com/kvm-nested-in-vmware-esxi-5-5-enable-guest-hypervisor-vmx-svm-flags-without-vsphere-web-client-
t19773.html
GO to the VMS vmdk folders and edit .vmx file and add the following flag in that file and save it.
vhv.enable = "TRUE"
Follow the commands below to restart the VM and reboot the machine.
/vmfs/volumes/53071ba5-6f9682d4-5898-002590883ef6/SLES 12 VM # vim-cmd vmsvc/getallvms | grep -i sles
15 SLES-82 [datastore1] SLES 1/SLES 1.vmx sles11_64Guest vmx-08
59 SLES 12 VM [datastore1] SLES 12 VM/SLES 12 VM.vmx sles11_64Guest vmx-08
/vmfs/volumes/53071ba5-6f9682d4-5898-002590883ef6/SLES 12 VM # vim-cmd vmsvc/reload 59
/vmfs/volumes/53071ba5-6f9682d4-5898-002590883ef6/SLES 12 VM #

How can I access a VM console from the command line of another machine

I have a VMWare vSphere 5.5 Hypervisor with a RHEL VM running on it.
From my understanding of the documentation at http://libvirt.org/drvesx.html, I believe I should be able to interact fully with the VM using libvirt, via virsh.
However, after connecting to the hypervisor, when I attempt to start a console via:
virsh -c esx://$USER#$HOST?no_verify=1 console VMNAME
I receive the following:
Connected to domain VMNAME
Escape character is ^]
error: this function is not supported by the connection driver: virDomainOpenConsole
Am I doing something wrong or does libvirt not allow access to the VM console via an ESX Hypervisor?
By the error message, it looks like the ESX driver doesn't allow the user to open a VM console. There's not much to do then...

Dealing with GConf Error: No D-BUS daemon running error in Ubuntu 12.0.4 LTS

I would like to run some R scripts in terminal on an Ubuntu 12.04 LTS (no GUI) that is hosted as a virtual server inside a Windows 2008 Server. I log into the server through ssh and whenever I run R scripts or gnome-open command in the terminal I get the following error
(gnome-open:10138): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Unable to autolaunch a dbus-daemon without a $DISPLAY for X11
GConf Error: No D-BUS daemon running
I have tried everything including:
1.Installing Xvfb and configuring it.
2.Exporting display variable set in /etc/environment & ~/.bashrc
3.Trying to export dbus-launch to no avail
4.Getting & loading the session dbus id from file
X11 forwarding has been enabled
I need help dealing with this issue. Any ideas?
Try
apt-get install dbus-x11
this helps me on a ubuntu 12.04 with X installed and the same error message.

Unable to execute MPICH2 on multiple machines on ubuntu 12.04 (HYDU_sock_connect issue)

I am facing difficulty in executing MPI program on two machines. The OS is Ubuntu 12.04. And the MPI implementation is MPICH2
ssh is working fine:
root#ubuntu:/home# ssh 192.168.1.9
root#gpuguy's password:
Welcome to Ubuntu 12.04.3 LTS (GNU/Linux 3.8.0-29-generic i686)
* Documentation: https://help.ubuntu.com/
131 packages can be updated.
67 updates are security updates.
Last login: Thu Oct 24 17:36:25 2013 from ubuntu.local
root#gpuguy:~#
But when I run my MPI programs it fails:
root#ubuntu:/home# mpiexec -f hosts.cfg -n 4 hello
root#192.168.1.9's password:
[proxy:0:0#gpuguy] HYDU_sock_connect (./utils/sock/sock.c:171): unable to get host address for ubuntu (1)
[proxy:0:0#gpuguy] main (./pm/pmiserv/pmip.c:209): unable to connect to server ubuntu at port 42104 (check for firewalls!)
I have already disabled firewall on both machines that is the reason I can do ssh successfully. But how to solve this issue?
My MPI code runs successfully on single machine.
For MPICH (or any MPI implementation) to work, you need to have passwordless SSH set up. I should also mention that you really shouldn't have to be logged in as root to make this work. It's generally a very bad idea to be logged in as root all of the time.
In /etc/hosts file, add ip address of each server and its hostname.
You should do this for all the servers.
for example:
10.10.0.5 server1
10.10.0.6 server2
10.10.0.7 server3
Just check in /etc/hosts file, not use tab (\t) instead of space to separate between ip address and hostname.
This is wrong:
10.10.0.5 \t server1
This is true:
10.10.0.5 server1
Be careful to not delete or modify existed lines in /etc/hosts file. only add new lines at end of file.
Also, you do not need to disable firewall to fix this issue.

Resources