Skip to content

Instantly share code, notes, and snippets.

View ksingh7's full-sized avatar

karan singh ksingh7

View GitHub Profile
@ksingh7
ksingh7 / nova.conf
Last active January 7, 2022 11:09
Failed to connect to server (code 1006) openstack VNC
Problem : Unable to connect to Openstack instance console using VNC using openstack Horizon
Error Message : Failed to connect to server (code 1006)
Environnment : OpenStack RDO Juno , CentOS7
Solution: You need to update vncserver_proxyclient_address with the openstack controller IP address OR novavncproxy_base_url IP address as shown below
[root@os-node1 ~(keystone_admin)]# cat /etc/nova/nova.conf | grep -v "#" | grep -i vnc
novncproxy_host=0.0.0.0
novncproxy_port=6080
novncproxy_base_url=https://192.168.1.111:6080/vnc_auto.html
@ksingh7
ksingh7 / UML_Diagram_Spacewalk_OS_deployment
Last active October 30, 2016 15:42
UML diagram for Spacewalk OS Deployment
```sequence
Note left of Node:Power UP
Node->Spacewalk Service:PXE broadcast
Spacewalk Service-->Node: PXE boot
Spacewalk Service-->Node: PXE check for OS
Spacewalk Service-->Node: PXE: If OS already deployed
Note left of Spacewalk Service:Boot node from Local disk
Spacewalk Service-->Node: PXE: If fresh install required
Note left of Spacewalk Service:Boot node from network
Node->DHCP Service:Request IP address ?
@ksingh7
ksingh7 / gist:8d214b5cf24ad702f8f4
Created May 22, 2015 10:38
HP ADU report ( Array Diagnostic Utility ) Report
# hpacucli ctrl all diag file=/tmp/ADUReport.zip
@ksingh7
ksingh7 / openstack error
Last active August 29, 2015 14:23
openstack nova : No valid host was found OR Build of instance ID was re-scheduled internal error no supported architecture for os type 'hvm'
Environment:
Openstack Juno installed on 3 nodes of virtualbox ( compute , network and controller )
CentOS7
Just after fresh installation i received below error while launching instnace
2015-06-15 19:27:25.498 10480 ERROR nova.scheduler.utils [req-2237e384-b3a9-4aa1-ac96-898f5c5d72db None] [instance: 3def536d-858d-4631-954a-ca09e56bd71b] Error from last host: compute (node compute): [u'Traceback (most recent call last):\n', u' File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2033, in _do_build_and_run_instance\n filter_properties)\n', u' File "/usr/lib/python2.7/site-packages/nova/compute/manager.py", line 2164, in _build_and_run_instance\n instance_uuid=instance.uuid, reason=six.text_type(e))\n', u"RescheduledException: Build of instance 3def536d-858d-4631-954a-ca09e56bd71b was re-scheduled: internal error: no supported architecture for os type 'hvm'\n"]
2015-06-15 19:27:25.568 10480 WARNING nova.scheduler.driver [req-2237e384-b3a9-4aa1-ac96-898f5c5d72db None] [instance: 3def
@ksingh7
ksingh7 / vagrant-provision-shell
Created June 17, 2015 13:52
vagrant-provision-shell
puppet.vm.provision 'shell', inline: 'systemctl stop firewalld'
puppet.vm.provision 'shell', inline: 'setenforce 0'
puppet.vm.provision 'shell', inline: "sed -i s'/SELINUX.*=.*enforcing/SELINUX=disabled'/g /etc/selinux/config"
puppet.vm.provision 'shell', inline: 'rpm -ivh http://yum.puppetlabs.com/puppetlabs-release-el-7.noarch.rpm'
puppet.vm.provision 'shell', inline: 'yum install -y puppet-server'
puppet.vm.provision 'shell', inline: 'puppet resource package puppet-server ensure=latest'
puppet.vm.provision 'shell', inline: 'yum update -y'
puppet.vm.provision 'shell', inline: 'systemctl enable puppetmaster'
puppet.vm.provision 'shell', inline: 'systemctl start puppetmaster'
puppet.vm.provision 'shell', inline: 'systemctl disable firewalld'
@ksingh7
ksingh7 / Vagrantfile
Last active August 29, 2015 14:24
CentOS7 virtual machines for openstack deployment
# Licensed under the Apache License, Version 2.0
# Copyright Karan Singh (Karan_singh1@live.com)
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
### IMPORTANT NOTE ###
# make sure you install $ sudo vagrant plugin install vagrant-hostmanager
VAGRANTFILE_API_VERSION = "2"
@ksingh7
ksingh7 / uninstall_rdo.sh
Created July 19, 2015 10:36
uninstalling-openstack-RDO
for x in $(virsh list --all | grep instance- | awk '{print $2}') ; do
virsh destroy $x ;
virsh undefine $x ;
done ;
yum remove -y nrpe "*nagios*" puppet "*openstack*" "*nova*" "*keystone*" "*glance*" "*cinder*" "*swift*";
mysql -u root -e "drop database nova; drop database cinder; drop database keystone; drop database glance; drop database neutron;"
# Uncomment this for Cinder volume group
@ksingh7
ksingh7 / dd_disk_test.sh
Last active August 29, 2015 14:25
DD test for Spinning and SSD disk
## Change these variables for your environment
SPINNING_DISK_OUTPUT_FILE_PATH=
SSD_DISK_OUTPUT_FILE_PATH=
COUNT=262000
BLOCK_SIZE=4k
##############
TEMP_FILE=/dev/zero
> /tmp/dd_output ;
@ksingh7
ksingh7 / Default ceph osd config parameters - Ceph Hammer
Last active September 27, 2015 10:16
Default ceph configuration parameters
[root@ceph-node1 ceph]# ceph --admin-daemon ceph-osd.0.asok config show
{
"name": "osd.0",
"cluster": "ceph",
"debug_none": "0\/5",
"debug_lockdep": "0\/1",
"debug_context": "0\/1",
"debug_crush": "1\/1",
"debug_mds": "1\/5",
"debug_mds_balancer": "1\/5",
@ksingh7
ksingh7 / HP_ILO_user_management
Last active August 9, 2022 13:51
HP ILO user create from CLI
# Script to create admin and administrator user
#!/bin/bash
IPs=`echo 86.50.1.{150..168}`
for ip in $IPs
do
echo Starting $ip
sshpass -p 'ROOTPWD' ssh -o StrictHostKeyChecking=no -l root $ip "create /map1/accounts1 username=Administrator password=ADMINISTRATORPWD name=Administrator group=admin,config,oemhp_rc,oemhp_power,oemhp_vm"
sshpass -p 'ROOTPWD' ssh -o StrictHostKeyChecking=no -l root $ip "create /map1/accounts1 username=admin password=ADMINPASSWORD name=admin group=admin,config,oemhp_rc,oemhp_power,oemhp_vm"