Home PC Games Linux Windows Database Network Programming Server Mobile  
  Home \ Linux \ Ubuntu under VirtualBox virtual machine serial port settings     - jdbc Oracle database connection string writing pluggable (Database)

- JDK installation notes under CentOS (Linux)

- Linux operating system to solve a serious fault handling (Linux)

- The method of MySQL two kinds of incomplete recovery (Database)

- Java object serialization and deserialization (Programming)

- Java NIO in the world (Programming)

- A step by step teach have to install multi-node cluster configuration Hadoop (Server)

- Orionode source Linux Mint installation (Linux)

- Xshell key authentication mechanism using a remote login Linux (Linux)

- GAMIT 10.50 installed in Ubuntu 12.04 system (Linux)

- Ubuntu 14.10 splash screen brightness settings (Linux)

- Boost notes --Thread - problems encountered in the initial use on Ubuntu (Programming)

- Java loop list to solve the problem of Joseph ring (Programming)

- How to fix fatal error: security / pam_modules.h: No such file or directory (Linux)

- Singleton (Linux)

- Linux (CentOS) SSH login without password authentication (Linux)

- Spark source code compiler package (Linux)

- How to interactively create a Docker container (Server)

- Increase Linux system security --chattr (Linux)

- Asynchronous JavaScript loading (Programming)

  Ubuntu under VirtualBox virtual machine serial port settings
  Add Date : 2018-11-21      
  Serial communication mechanism VirtualBox virtual machine, there are two, one is through the virtual machine's serial port to connect to the host serial port, the other is the virtual machine serial port to connect to a named pipe on the host, the first way to now I do not practice it, just named pipe currently practiced otherwise successful.

1. Enable serial ports

New Virtual Machine After setting appears port panel, you can serial port settings, default can not afford to use the general port selection using COM1 corresponding to the virtual machine / dev / ttyS0, Port Mode Select Host Pipe, represents the virtual machine's serial port a named pipe to host, create a channel represents start a virtual machine VirtualBox corresponds create a named pipe HostOS in, and it corresponds to the virtual machine's serial port. Port path when selecting Host Pipe represents the path named pipes on Windows systems, it is \. Pipe xxx form, in Linux can be set to any path, for example, we will set it to / tmp / vbox. Note that if the port path corresponding named pipe can not be created, then the virtual machine will fail to start; port named pipe path can not be repeated to create.

You can also use the command line to enable a virtual machine and create a connection to the host named pipe, the following command will be Ubuntu 8.10 Dev OS virtual machine's COM1 serial port and host / tmp / vbox named pipes connected:

VBoxManage setextradata "Ubuntu8.10DevOS" "VBoxInternal / Devices / serial / 0 / Config / IRQ" 4

VBoxManage setextradata "Ubuntu8.10DevOS" "VBoxInternal / Devices / serial / 0 / Config / IOBase" 0x3f8

VBoxManage setextradata "Ubuntu8.10DevOS" "VBoxInternal / Devices / serial / 0 / LUN # 0 / Driver" Char

VBoxManage setextradata "Ubuntu8.10DevOS" "VBoxInternal / Devices / serial / 0 / LUN # 0 / AttachedDriver / Driver" NamedPipe

VBoxManage setextradata "Ubuntu8.10DevOS" "VBoxInternal / Devices / serial / 0 / LUN # 0 / AttachedDriver / Config / Location" "/ tmp / vbox"

VBoxManage setextradata "Ubuntu8.10DevOS" "VBoxInternal / Devices / serial / 0 / LUN # 0 / AttachedDriver / Config / IsServer" 1

2. The serial communication between the virtual machine and the host HostOS

Start the virtual machine Ubuntu8.10DevOS, then creates a new file in the vbox host / tmp / directory, use ls -l can see it is a sock type of file, use to communicate. Install minicom in HostOS in, minicom serial port can be used as a test:

sudo apt-get install minicom

Then we can configure minicom, it points to / tmp / vbox, Run

sudo gedit /etc/minicom/minirc.dfl and modify

pu port unix # / tmp / vbox

It can also be modified via the serial port settings in minicom. Baud rate and should ensure that the virtual machine minicom serial port settings of the serial port as before the test. Virtual machine serial port baud rate settings can refer to the following, minicom baud rate settings directly in the program Ctrl + A, O after modification, or modify the configuration files.

Testing process,

1) Start minicom in HostOS in:

sudo minicom

In a virtual machine in a terminal execute:

echo is that ok?> / dev / ttyS0

In HostOS echo in minicom the corresponding content

2) in a virtual machine in a terminal execute:

cat / dev / ttyS0

Then host minicom will appear in the input state, in which the input information will be echoed to the virtual terminal.

3. The serial communication between virtual machines and the virtual machine

Communication between the two virtual machines can also be accomplished by using a host named pipes. Principle can be simply described: Named Pipes to create a virtual machine on the host and its serial port connected to another virtual machine will be connected to your serial port on the host named pipe, two serial ports so that the virtual machine will be able to even up. Here are two virtual machines use their own COM1 port, the host of the named pipe is the same pipe / tmp / vbox, when configuring a channel is created (assuming Ubuntu8.10DevOS), the other is not created. Start the virtual machine to create a channel when you start, and then start the other virtual machines, each virtual machine to open two terminals, each with the following command COM1 port input and output are set to 115200 baud

stty ispeed 115200 ospeed 115200 -F / dev / ttyS0

Testing process:

Executed on one of the virtual machine A terminal

cat / dev / ttyS0

Execute on another virtual machine B

echo ok> / dev / ttyS0

A virtual machine then terminal B will receive messages sent ok.
- ORA-04031 error appears in the solution run utlrp.sql (Database)
- Windows7 system using Vagrant to build Linux virtualized development environment (Linux)
- Brief Linux commands (Linux)
- To install the mail client terminal Evolution 3.13.2 under Ubuntu 14.04 (Linux)
- Five Linux user space debugging tool (Linux)
- RedHat Linux 6.4 installation RTL8188CUS wireless network card driver (Linux)
- Install the latest Pinta graphics editing software on Ubuntu 14.04 (Linux)
- Eclipse remove all comments and code spaces (Linux)
- A drop datafile Oracle bug (Database)
- CMake Quick Start Tutorial (Linux)
- Linux stand-alone OGG synchronous Oracle 11g DB test (Database)
- MyEclipse configuration necessary (Linux)
- PostgreSQL export data dictionary documents (Database)
- installation and configuration of the PHP environment (Apache2) under Linux (Server)
- RPM package creation Getting Started (Linux)
- Git uses a standard process (Linux)
- Linux use iptables ban Ping (Linux)
- Analysis of MySQL Dockerfile 5.6 (Database)
- Deploy the project to the server from GitHub (Server)
- To read the Linux ext3 / ext4 format partitions under Windows system software (Linux)
  CopyRight 2002-2022 newfreesoft.com, All Rights Reserved.