Preparation before installation:
While writing this note, CoreOS's stable version number is: 899.15.0, maybe the version you downloaded will not be the same as me.
Download CoreOS ISO image, recommended stable version: Http://stable.release.core-os.net/amd64-usr/current/coreos_production_iso_image.iso
Download CoreOS installation file: http://stable.release.core-os.net/amd64-usr/current/coreos_production_image.bin.bz2
Download CoreOS's signature file: Http://stable.release.core-os.net/amd64-usr/current/coreos_production_image.bin.bz2.sig
Both the installation file and the signature file must be downloaded.
PS: It is recommended to use the offline download of thunder, otherwise this site is the wall is miserable.
If you are looking at my this article has been a long time, if you do not mind, I also have the version of the configuration file is uploaded to of the cloud disk for download:
Https://yunpan.cn/cqx66N743UkbH Access Password 8918
(Please change the download profile to XXX to your own address)
Open VirtualBox new virtual machine, configured as follows:
650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M00/7E/7B/wKiom1cB0X-AcXLEAABiYw1Jd_4816.png "title=" 1.png " alt= "Wkiom1cb0x-acxleaabiyw1jd_4816.png"/>
The name was random,
Memory official online recommendation 1G (PS: Can not be too small, if too small ISO image loading is not successful, the symptom is an unlimited restart), the hard drive official website is not recommended but in the production of CoreOS VDI hard disk image when there is a note: # Resize Virtual Disk to ten GB, So recommended 10G size bar, too small to install. Number of processors look at the PC, EFI boot is not available.
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M00/7E/7B/wKiom1cB0zCBj6fmAACwLzwd3UM705.png "title=" 2.png " alt= "Wkiom1cb0zcbj6fmaacwlzwd3um705.png"/>
Network configuration recommended bridging network card:
650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M01/7E/77/wKioL1cB1EzQh0v6AAC2HZf2NDU981.png "title=" 3.png " alt= "Wkiol1cb1ezqh0v6aac2hzf2ndu981.png"/>
Add the ISO image you just downloaded in the store.
Then start CoreOS
After entering the system, first switch to the root user:
Sudo-i
To view the network interface name:
IP link
General Enp0s3, gentlemen, take a look, write down the name, create a static.network file
vi/etc/systemd/network/static.network# Add the following [Match]name=enp0s3[network]address=xxx.xxx.xxx.xxx/xxgateway=xxx. Xxx.xxx. Xxxdns=xxx.xxx.xxx.xxx
Save, exit.
Enable this network connection:
Systemctl start Systemd-networkdip link set enp0s3 up
Ping the IP address of the machine where the VirtualBox is located:
Ping XXX.XXX.XXX.XXX
If successful, continue, if it fails, re-close the port, then open, then restart the SYSTEMD-NETWORKD service
IP link Set enp0s3 downip link set enp0s3 upsystemctl restart SYSTEMD-NETWORKD
Again ping test, if still not, see is not virtualbox inside the network settings is not bridging mode.
In addition, personal experience, my test environment is a laptop, the system win10, there is a wireless router, but unfortunately, the first is the WIN10 firewall to disable the ping, the symptom is that ping does not pass my notebook, but the notebook can ping through other machines, You need to turn on ECHO requests in the firewall (don't search for a workaround). Second, I put the router Ip/mac address binding enabled (not necessarily routers, other brand routers have this feature), so the virtual machine to ping the outside of the ping when pinging, the two problems for a long time to solve. In addition, if you are not using WIN10, but also installed security guard, must be LAN protection in the LAN stealth function is closed, or ping does not pass. Things always have two sides, security is more trouble, convenient and unsafe, we always look for a balance between this, these lessons come out to share it!
All right, go ahead.
The following steps need to be self-built Web server, cause core-os.net This site was wall, resulting in Cloud-install installation file execution failed.
However, I landed on April 4, 2016 When this address can open, very happy, but I am not sure if it will be able to visit, or use my way. Because my system running VirtualBox is windows, it's too easy to build a Web server (Linux and Mac users can open Apache or nginx), Download Babyweb software similar to AWS.exe, both of which can be, but the native IIS do not start, or port conflicts.
Follow the configuration below:
650) this.width=650; "src=" Http://s2.51cto.com/wyfs02/M00/7E/78/wKioL1cB3LbSBVkwAACWzyl3Er8348.png "title=" 4.png " alt= "Wkiol1cb3lbsbvkwaacwzyl3er8348.png"/>
You can use browser access to try: http://127.0.0.1, the success of the words should show the few files.
All right, go ahead.
To establish a system configuration file:
vi cloud-config.yaml# Add the following, notice to replace XXX with their own, the other ssh-rsa need to login CoreOS machine generation, Windows system with putty or Xshell can, Linux and Mac are generated directly in the terminal, and the #ssh-keygen command is generated in the. SSH directory in the user directory. Copy the contents of the suffix. pub file to the following ssh-rsa. #cloud-confighostname: "coreos1" ssh-authorized-keys: - "ssh-rsa aaaab3nzac1yc2eaaaabiwaaaqea9tj5adc8qlos0hn8alm/q9zv5guo6iqamdl9a/zmt16nwj8wlaz/glbn5/ olsgdhyprvl4isyel3gshcq3yhsorfpe0w78fxavufiw0xtnl6co6uts+erjmcqtsqjpzscpmejscmuxensgcjv+ b1wbypoeiakndkhcaqpo9elenqerjdng+gnwz6r7wipge1m9zg6x1pi6qjcupvbef9mqzu6cg8acx2z14zxnvpomook/ dk1hwuyb8zoozqhgcrrqhl9+vidsvs2qxlcvlcsdhtcyfgdqs5ycond0pq2bosznrgovglaijvks+3jxk9qckpxdw/9jhujifxyp/rxq== " write_files: - path: "/etc/systemd/network/static.network" permissions: "0644" owner: "root" content: | [Match] Name=XXXXXX [network] dhcp=no address=xxx.xxx.xxx.xxx/xx gateway=xxx.xxx.xxx.xxx dns=xxx.xxx.xxx. xxxcoreos: etcd: addr: "$private _ipv4:4001" peer-addr: "$private _ipv4:7001" units: - name: "Etcd.service" command: "Start" - name: " Fleet.service " command: " Start " - name: "XXXXXX" command: "Start" users: - groups: - "sudo" - "Docker"
Note: The TAB key in all Cloud-config configuration files cannot be recognized, so remember to use the SPACEBAR when indenting.
This site can verify the correctness of the Cloud-config.yaml configuration: https://coreos.com/validate/
Save, exit.
Add the Hosts file and write the following:
vi/etc/hosts# replace XXX with the IP address of the machine running VirtualBox, XXX.XXX.XXX.XXX release.core-os.net
Save, exit.
Download installation script :https://raw.github.com/coreos/init/master/bin/coreos-install
Copy it to the directory where you just installed the files.
Note: If it is a Windows user, the new text document is pasted into the installation script, I am not guaranteed to be able to use it and have not tried it. It is recommended to use EditPlus, notepad++, etc., after the new line must be modified (Windows is not the same as Linux, Mac).
It is then downloaded and modified in the virtual machine.
wget Http://XXX.XXX.XXX.XXX/coreos-installvi coreos-install# Look for the Base_url field, change the value inside the quotation mark to http://release.core-os.net/ amd64-usr/899.15.0, because I have these installation files are 899.15.0 so write this value later, if you download and my version is not the same please replace your version number with my version number.
If the address is not open, there is also a script installed in the virtual machine, located in:/usr/bin/coreos-install, can be copied to the current directory using:
Cp/usr/bin/coreos-install Coreos-install
The same action is performed to replace the Base_url.
Save, exit.
Assign the Coreos-install file to execute permissions:
chmod +x Coreos-install
Finally execute the installation command:
./coreos-install-d/dev/sda-c Stable-c Cloud-config.yaml
Show success! after success
650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M01/7E/7C/wKiom1cB9xXj_dmnAAAlm6365YQ194.png "title=" 5.png " alt= "Wkiom1cb9xxj_dmnaaalm6365yq194.png"/>
~~~~...~~>>>~>~.~>~>~>~. Oh, come on, this sticker is the one I used when I was using version 13. ~~~~!!! [Email protected]! @!
Take a look at how much space CoreOS is using, and will be nearly 5G in space.
Reboot, remove the disc and boot from the hard drive.
Log in with Xshell, ladies!
This article is from the "end of Philosophy" blog, please be sure to keep this source http://lucien1970.blog.51cto.com/10670905/1761097
ISO image installation with CoreOS in VirtualBox CoreOS