With VMWare Server running under Linux (Debain), I would like to have the following setup:
1st: NIC being used by many of the
images running under VMWare, as well
as being used by the Linux OS
2nd: NIC being used by only 1 image and to be unused by the Linux OS (as its part of a DMZ)
Although the second NIC won't be used by Linux, it is certainly recognised as a NIC (e.g. eth1).
Is this possible under VMWare Server, and if so, is it as simple as not binding eth1 under Linux and then bridging it to the image under VMWare Server?
I believe you can set the desired solution up by rerunning the vmware configuration script. And doing a custom network setup, so that both NIC's are mapped to your vmware instance. I would recommend making eth0 the 2nd NIC since it will be easier for Linux to use by default. Then make eth1 the 1st NIC.
Related
Linux is supporting virtual can interface. it was enabled by:
modprobe vcan
sudo ip link add dev vcan0 type vcan
sudo ifconfig vcan0 up
While using cam-utils such as camsniffer and cansend
cansend vcan0 321#1212
cansniffer vcan0
I could able to see can packets; but only within same host. I tried Ubuntu VirtualBox machine. Both guest and host OS are interconnected using host-only adapter vboxnet0.
Also tried SocketCAN socket(PF_CAN, SOCK_RAW, CAN_RAW) but not able to receive on other machine(works within same machine) While trying with broadcast manager socket(PF_CAN, SOCK_DGRAM, CAN_BCM) on executing stderr says `operation not supported
Simply, could one send and receive CAN packets between Linux hosts? Doesn't matter its Virtual Machine (vboxnet0) or physically connected (Ethernet).
Note: I used Ubuntu 16.04 and 12.04 as Host and Guest OS respectively.
CAN uses its own physial bus. The vcan devices are designed for testing software that communicates over the bus without requiring an actual physical connection, they're not actually supplied by the hypervisor, but are a part of SocketCAN.
By the looks of it, you're attempting to establish a Virtual CAN bus in Virtualbox, connecting multiple machines together as though they all had CAN controllers and were connected to a physical bus. I've looked, but it appears that such functionality doesn't exist, and beyond writing an extension for VirtualBox, is probably not likely to.
Is there a specific reason you're looking to use CAN? Trying to pull data from an ECU or communicate with embedded hardware that has a CAN controller? As far as desktop pc communication, ethernet is much more convenient, faster,a nd well supported.
I have a windows PC installed VMware Workstation and Linux run on it. I want When windows communicate with Internet I can capture packets in Linux, how can I do that?
The vmware network is Bridge, and I set eth0 use command "ifconfig eth0 procmisc".
linux IP is 192.168.0.103, windows IP is 192.168.0.102
Run "tcpdump not host 192.168.0.103" with no result.
Thank you for you time and please help me
While I haven't used VMWare workstation before, I have used Oracle VirtualBox in a similar setup as you describe.
I suspect that the problem is that your network adaptor on the Linux VM is not actually accessing the physical network adaptor directly. You will be using one of the network mapping types described in http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1006480 instead.
As such, you are not getting all the traffic that is going to your physical network adaptor. Instead you are getting the reduced set of traffic that VMWare is passing on to your guest.
The only way to get that is to do the snoop on your Windows host, using something like https://www.wireshark.org/
I am running CentOS 5.5 as VirtualBox guest on a Win 7 host.
It is a common problem in the forums that moving images across VMs encounters networking issues due to the MAC address persistence in /etc/udev/rules.d/70-persistent-net.rules. A solution typically proposed is to delete this file and reboot for it to be automatically regenerated.
In my case however, I cannot get the file to regenerate, despite multiple reboots with different VM network interface options. I became fairly hopeful when introduced to udevadm on an Ubuntu forum but could not find an equivalent for CentOS.
Specifying the new MAC address in /etc/sysconfig/network-scripts/ifcfg-eth0 has not helped, and neither has playing around with different network configurations in the manager.
Any pointers/assistance much appreciated.
I'm not a Centos expert, but know why this doesn't work in Ubuntu and a couple of other distributions. Have a read of the file which generates it which is normally /lib/udev/rules.d/75-persistent-net-generator.rules.
You will note that it will skip various types of ethernet interface, depending on MAC address and subsystem (i.e. where the interface comes from). Here's one from a RHEL like distro that skips Xen:
# ignore Xen virtual interfaces
SUBSYSTEMS=="xen", GOTO="persistent_net_generator_end"
Here are some from Ubuntu that skip other hypervisors:
# ignore KVM virtual interfaces
ENV{MATCHADDR}=="52:54:00:*", GOTO="persistent_net_generator_end"
# ignore VMWare virtual interfaces
ENV{MATCHADDR}=="00:0c:29:*|00:50:56:*", GOTO="persistent_net_generator_end"
# ignore Hyper-V virtual interfaces
ENV{MATCHADDR}=="00:15:5d:*", GOTO="persistent_net_generator_end"
# ignore Eucalyptus virtual interfaces
ENV{MATCHADDR}=="d0:0d:*", GOTO="persistent_net_generator_end"
# ignore Ravello Systems virtual interfaces
ENV{MATCHADDR}=="2c:c2:60:*", GOTO="persistent_net_generator_end"
As you can see, your distro is probably skipping the generation of net rules on VM interfaces, precisely because its normally annoying. For instance if you take a templated VM image with this file in, and rehydrate it elsewhere and it gets a different MAC, you don't normally want your eth0 to disappear and you to get a new eth1 instead. If you don't like this, you can introduce your own rules.d file to handle the persistent rules generation.
I am new to embedded linux development.I have inherited a particular way of Embedded linux development from the previous developer.
I was just wondering if there is a more industry standard way of working.
This is how he was working,
There is an ARM embedded linux board which is not on the corporate network and has a fixed IP address of 192.168.0.52.I have a virtualbox based linux host which is connected directly to this linux board via an Ethernet cable.This host has an NFS shared with the target for running the cross compiled binaries.I have to set a fixed IP address for the host of 192.168.0.50.Then I can telnet with the target to run the compiled binaries on the NFS folder. Also as the VM host is not connected to the corporate network.I cannot use the company issued SVN for version control.So what I do is have a shared folder via virtual box between Windows and Linux host and I manually keep transferring the files which I have to commit/test.
What I would I ideally like, is both networks connected to the corporate network,so that I can update the OS,use version control.Is there way by which the VM on Windows access the corporate network and also be connected to the target.IT is not willing to give a static IP to the target.If we connect the target via DHCP what is the best way to discover it on the network.Also IT is concerned about the traffic it will generate.Can I use a switch to create a subnetwork,so that the target can have a fixed address?
Another question is they are open to a linux based host as well.Is a VM based linux any worse off than a Linux PC.The only problem I have been having are networking based issues,not really Virtualbox issues.But I am curious to know if there are any limitations at all.
In order to have the VM connected to the corporate network, you can setup the VM network adapter in bridge mode.
In order to discover the embedded device, you can use the arp command (for instance: arm -i eth0 -a).
If you have got two network interfaces you could also connect the remote device directly through this interface and setup a dhcp server in your VM.
Personally, I think that with the VM you can do everything that you need (cross-compiling the Kernel and bootloader and creating the remote File System). I have been using a VM for embedded linux development on a AT91SAM board without problems at all.
I have a Linux Mint host system and a VMware guest system with Linux Debian. On my host system there are two physical network interfaces eth0 and wlan0. My guest system is set up to use its network connection in bridged mode. Whenever my WLAN is turned on it automatically choose this interface to bridge. When I turn off my WLAN it bridges over the ethernet port.
Is it possible to set a default interface for the host system to bridge over? I didn't find anything on the VMware GUI neither on google.
This page should explain how to do it, under the section 'Configuring Bridged Networking Options on a Windows Host'. Don't worry, I had trouble finding it too.
Basically, the settings are available in Edit > Virtual Network Editor.