Saturday, March 18, 2017

CoreOS install over existing CentOS

Log for installing CoreOS on a machine with centos7 using the CD Iso to boot

-create ISO image of stable CoreOS from https://coreos.com/os/docs/latest/booting-with-iso.html

boot from iso

sudo su - root

coreos-install -d /dev/sda

I get disk resource busy BLKRRPART: Device or resource busy

solution is to wipe the disks

dd if=/dev/zero of=/dev/sda bs=512 count=1
dd if=/dev/zero of=/dev/sdb bs=512 count=1
reboot

parted -s /dev/sda print - this shows nothing after this

sudo su - root

coreos-install -d /dev/sda

reboot

now select boot from c drive

CANNOT LOGIN...NO PASSWORD

SOLUTION: generate public and private key with putty

http://www.cnx-software.com/2012/07/20/how-use-putty-with-an-ssh-private-key-generated-by-openssh/

upload the cloud-config to linux machine

use the public key

#cloud-config

ssh_authorized_keys:
  - "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQC0g+ZTxC7weoIJLUafOgrm+h..."

use this site to validate the content:  https://coreos.com/validate/

during the CoreOS install from ISO

sudo -su root
scp user@linuxhostwithconfig:/home/cloud.config.yaml .

now execute the install

coreos-install -d /dev/sda -c cloud-config.yaml

install the OS

Now configure private key in putty session and login (as core)




No comments: