Requirements Background
The embedded development environment is based on the compilation server (Linux system) as the core, the developer uses the Windows system more, through several tools, can implement the developer to use the Windows Development tool, writes the code, then compiles, executes, debugs the code on the Linux system the process. For example, two elements are different hosts that communicate over a network connection:
This is the actual working state of the requirements, the server has a strong computational power, can compile a large function. So the problem comes, often in personal situations, regardless of server computing power, only one of their own notebook, then how to implement this build tool on a single machine?
The answer is of course the virtual machine, install the virtual machine on the laptop, install the Linux Server version on the virtual machine, and then the notebook as the client. Detailed descriptions are described below.
Related softwareVirtualBox
Oracle VirtualBox, a virtual machine software produced by the German Innotek software company, is now being developed by Oracle and is part of Oracle's XVM virtualization platform technology. It provides the operating system for virtual other x86 on 32-bit or 64-bit Windows, Solaris, and Linux operating systems. Users can install and execute systems such as Solaris, Windows, DOS, Linux, Os/2 Warp, OpenBSD, and FreeBSD as client operating systems on VirtualBox.
Official website: https://www.virtualbox.org/wiki/Downloads
Select your system-consistent version download.
Ubuntu Server
Ubuntu Server is the leading platform for scalable computing. No matter whether you want to deploy an OpenStack cloud, a Hadoop cluster, or a 50,000-node render farm, no server can deliver more value and scalability than the Ubuntu server.
Official website: http://www.ubuntu.org.cn/download/server
Xshell
Xshell is a Windows SSH telnet to Linux software that provides secure Telnet access via SSH.
Xshell is a powerful secure terminal emulation software that supports SSH1, SSH2, and the Telnet protocol of the Microsoft Windows platform. Xshell's secure connection to remote hosts via the Internet and its innovative design and features help users enjoy their work in a complex network environment.
The Xshell is suitable for both novice and advanced users. It has a friendly interface and provides more powerful features for advanced users.
Website address: http://www.netsarang.com/products/xsh_overview.html
: http://www.netsarang.com/xshell_download.html
Free for home and school use.
installation Process
1, download VirtualBox, after installation, set up on the Ubuntu server virtual machine
The network configuration defaults to NAT and needs to be modified to Bridge adaptor mode so that the virtual machine and the host can get the same network segment address and can communicate with each other.
2. Installing an SSH server on Ubuntu server
Reference http://shenji.io/ubuntu-server-using-the-ssh-service-and-remote-management.html
3. Installing the Samba server on Ubuntu server
Reference http://blog.csdn.net/i_chips/article/details/19191957
$ sudo apt-get install Samba
In general, this directory has a permission of 755, and it is changed to 777 after the permission is written by other users other than owner.
$ sudo chmod 777/home/share
$ sudo vim/etc/samba/smb.conf
Last added in smb.conf:
[Share]
Path =/home/share
browseable = yes
writable = yes
Comment = SMB share test
Third, create Samba users
Note that before you create a samba user, you must first ensure that you have a Linux user with the same name, or the samba user will create a failure.
$ sudo smbpasswd-a smbuser
Iv. Restart Samba Services
$ sudo service smbd restart
4, Installation Xshell
View the server IP, log in to SSH using the server's account, and then the user can use system commands such as LS cat MV
5. Accessing server files using Samba
Look at the server IP, run the window input \\IP, and then enter the third set of accounts in the pop-up authentication window, Windows can view the Linux shared directory, you can drag a file up, and then to the Xshell login session using the LS test.
At this point, the environment is built, the command input uses Xshell, the file is written and modified using Samba, that is, implementing windows to write code using Windows tools, and then use the Linux compiler program.
Experiment
The notebook computer address is as follows:
The virtual Ubuntu Server IP is as follows:
Windows accesses Linux's shared directory through Samba and uses the editor sublime to build HELLOWORLD.C
Execute HELLOWORLD.C with Xshell compilation
Virtualbox+ubuntuserver+xshell Build Linux development environment