SlideShare a Scribd company logo
1 of 4
Download to read offline
Stacki Tutorial #1: The Basics of Networking in Stacki
Introduction
This series of tutorials is designed to offer short, easy to follow steps to customize your use of
Stacki. Each tutorial will offer one set of functionality, and fully explain how that functionality
can be achieved in Stacki - the world’s fastest open source installer.
Summary
Stacki, as it is initially installed, will quickly install as many machines as you need with in-
telligent default settings. But it is rare that your environment requires default settings, so the
tutorial series will teach you how to customize the installed servers to suit your environment.
Since everyone needs networking, and every environment is different, we decided this was a
good place to start our tutorial series.
What you will learn
Today’s tutorial will walk you through creating networks in the Stacki server, and adding NICs
to backend servers that make use of those networks. There is a lot more of networking in Stacki,
but we’ll get to those other items in future tutorials.
Pre-requisites
This tutorial assumes:
1. You have downloaded Stacki from www.stacki.com
2. You have followed the directions here to install a Stacki server.
3. You have followed the directions here to install backend server(s).
4. You have access to a command line on the Stacki server.
5. You have information about the network(s) you want to add to Stacki.
Naming hosts/host groups
Most stacki commands take the name of a host. This can be in any of the following forms:
hostname - Actual host DNS name host-0-0.local – This machine.
hostname* - All hosts whose name match the pattern. Host* - All machines whose names
start with host.
appliance name - all machines of that appliance type backend – All machines of appliance
type backend.
Page 1www.stacki.com | Stacki Google Group | Stacki GitHub
Let’s Get Started!
Log in to the Stacki server, and type the following command:
stack list network
You should see output like this, assuming you’ve not changed anything yet:
These are all of the networks Stacki knows about by default. The private network is used for
installations, the public so that you can log into the Stacki server remotely, and get updates in
the future. This tutorial will show you how to create new networks, and to modify the “public”
network of these. Since “private” is used to do installations, we’ll not do anything with that one
until a later tutorial, when we have more information about what can be done with networks.
By default, all servers exist on the private network. To see this, type the following…
Stack list host interface backend*
You should see output like the following:
Notice that the interface has a lot of information on it. We’ll get to that in a future installment.
To add a network to the list of networks, simply type:
stack add network protected 10.10.10.1 255.255.255.0
As you likely guessed already, ‘protected’ will be the network name, ’10.10.10.1 the base address,
and 255.255.255.0 the netmask – meaning the network covers all of the 10.10.10.* network.
And you can check that the network exists by typing:
stack list network
again.
[root@stackidon ~]# stack list network
NETWORK	 SUBNET		 NETMASK		 MTU	 DNSZONE	SERVEDNS
private:	10.1.1.0	255.255.255.0		1500	local		True
public:	 192.168.0.0	255.255.255.0		 1500	stackiq.com	False
[root@stackidon ~]#
[root@stackidon ~]# stack list host interface backend*
HOST		 SUBNET	 IFACE	 MAC	 IP	 NETMASK	MODULE NAME		 VLAN OPTIONS CHANNEL
backend-0-0:	private	eth0	 08:00:27:6e:88:08 10.1.1.253 255.255.255.0 ------
backend-0-0 ---- ------- -------
backend-0-1:	private	eth0	 08:00:27:3a:e0:e4 10.1.1.254 255.255.255.0 ------
backend-0-1 ---- ------- -------
[root@stackidon ~]#
Page 2
Page 2www.stacki.com | Stacki Google Group | Stacki GitHub
[root@stackidon ~]# stack add network protected 10.10.10.1 255.255.255.0
[root@stackidon ~]# stack list network
NETWORK    SUBNET      NETMASK       MTU   DNSZONE     SERVEDNS
private:   10.1.1.0    255.255.255.0 1500  local       True
protected: 10.10.10.1  255.255.255.0 1500  protected   False
public:    192.168.0.0 255.255.255.0 1500  stackiq.com False
[root@stackidon ~]#
Now Stacki knows about the protected network, and we can tell backend machines to attach
NICs to it. Let’s do so. First, add the interface to the stacki database:
stack add host interface backend-0-0 iface=eth1 ip=10.10.10.100 subnet=protected name=prot1
This tells Stacki to add eth1 to server backend-0-0, give it ip 10.10.10.100, attach it to subnet pro-
tected, and name it prot1 locally.
Now if you type:
stack list host interface backend-0-0
You’ll see our new interface in the list, but if you go to a terminal on backend-0-0, you will not
find it listed with ifconfig. That is because Stacki knows about it, but hasn’t updated the server
yet. To update the server type:
Stack sync host network backend-0-0
It will tell the host about its new interface, and bring the interface up. If you go to the backend
servers’ terminal and type ifconfig, you will see eth1 is now there, and it is fully functional (as-
suming you put it on the right network with a valid IP).
[root@stackidon ~]# stack add host interface backend-0-0 iface=eth1 ip=10.10.10.100 subnet=pro-
tected name=prot1
[root@stackidon ~]# stack list host interface backend-0-0
SUBNET IFACE MAC IP NETMASK MODULE NAME VLAN OPTIONS
CHANNEL
private eth0 08:00:27:6e:88:08 10.1.1.253 255.255.255.0 ------ backend-0-0 ---- ------- ---
----
protected eth1 ----------------- 10.10.10.100 255.255.255.0 ------ prot1 ---- ------- ---
----
[root@stackidon ~]# stack sync host network backend-0-0
[root@stackidon ~]#
Page 3www.stacki.com | Stacki Google Group | Stacki GitHub
Now we can check on the host…
That’s it for this tutorial! You now can access a variety of networks in your environment simply by defining
the network and interfaces on the command line.
That’s it for this tutorial! You now can access a variety of networks in your environment simply by defining
the network and interfaces on the command line.
[root@stackidon ~]# ssh backend-0-0
Last login: Wed Jul 1 14:00:06 2015
[root@backend-0-0 ~]# ifconfig
eth0 Link encap:Ethernet HWaddr 08:00:27:6E:88:08
inet addr:10.1.1.253 Bcast:10.1.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:308 errors:0 dropped:0 overruns:0 frame:0
TX packets:282 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:48737 (47.5 KiB) TX bytes:38985 (38.0 KiB)
eth1 Link encap:Ethernet HWaddr 08:00:27:D0:67:B5
inet addr:10.10.10.100 Bcast:10.10.10.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:55 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:5148 (5.0 KiB) TX bytes:168 (168.0 b)
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:5 errors:0 dropped:0 overruns:0 frame:0
TX packets:5 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:780 (780.0 b) TX bytes:780 (780.0 b)
[root@backend-0-0 ~]#
Stacki Tutorial #1: The Basics of Networking in Stacki
© 2015 StackIQ, Inc. | www.stacki.com
Page 4www.stacki.com | Stacki Google Group | Stacki GitHub

More Related Content

More from StackIQ

StackiFest 2017 Technology Update
StackiFest 2017 Technology UpdateStackiFest 2017 Technology Update
StackiFest 2017 Technology UpdateStackIQ
 
Automation of your OpenStack Infrastructure with Stacki
Automation of your OpenStack Infrastructure with StackiAutomation of your OpenStack Infrastructure with Stacki
Automation of your OpenStack Infrastructure with StackiStackIQ
 
StackiFest 2017 Welcome & Opening Address
StackiFest 2017 Welcome & Opening AddressStackiFest 2017 Welcome & Opening Address
StackiFest 2017 Welcome & Opening AddressStackIQ
 
Provisioning Heterogenous Bare Metal with Stacki
Provisioning Heterogenous Bare Metal with StackiProvisioning Heterogenous Bare Metal with Stacki
Provisioning Heterogenous Bare Metal with StackiStackIQ
 
Provisioning with Stacki at NIST
Provisioning with Stacki at NISTProvisioning with Stacki at NIST
Provisioning with Stacki at NISTStackIQ
 
Public vs. Private Cloud Performance by Flex
Public vs. Private Cloud Performance by FlexPublic vs. Private Cloud Performance by Flex
Public vs. Private Cloud Performance by FlexStackIQ
 
SF Bay Area OpenStack Meetup Stacki Presentation
SF Bay Area OpenStack Meetup Stacki Presentation SF Bay Area OpenStack Meetup Stacki Presentation
SF Bay Area OpenStack Meetup Stacki Presentation StackIQ
 
Stacki at the Seattle Scalability Meetup
Stacki at the Seattle Scalability MeetupStacki at the Seattle Scalability Meetup
Stacki at the Seattle Scalability MeetupStackIQ
 
StackiFest16: Building a Cluster with Stacki - Greg Bruno
StackiFest16: Building a Cluster with Stacki - Greg BrunoStackiFest16: Building a Cluster with Stacki - Greg Bruno
StackiFest16: Building a Cluster with Stacki - Greg BrunoStackIQ
 
StackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg Bruno
StackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg BrunoStackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg Bruno
StackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg BrunoStackIQ
 
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha StackIQ
 
StackiFest16: What's Next in Stacki - Mason Katz
StackiFest16: What's Next in Stacki - Mason Katz StackiFest16: What's Next in Stacki - Mason Katz
StackiFest16: What's Next in Stacki - Mason Katz StackIQ
 
StackiFest16: CoreOS/Ubuntu on Stacki
StackiFest16: CoreOS/Ubuntu on Stacki StackiFest16: CoreOS/Ubuntu on Stacki
StackiFest16: CoreOS/Ubuntu on Stacki StackIQ
 
StackiFest16: Building a Cart
StackiFest16: Building a CartStackiFest16: Building a Cart
StackiFest16: Building a CartStackIQ
 
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce StackIQ
 
StackiFest 16: Stacki Overview- Anoop Rajendra
StackiFest 16: Stacki Overview- Anoop Rajendra StackiFest 16: Stacki Overview- Anoop Rajendra
StackiFest 16: Stacki Overview- Anoop Rajendra StackIQ
 
Introduction to Stacki at Atlanta Meetup February 2016
Introduction to Stacki at Atlanta Meetup February 2016Introduction to Stacki at Atlanta Meetup February 2016
Introduction to Stacki at Atlanta Meetup February 2016StackIQ
 
Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016StackIQ
 
Private Cloud vs. Public Cloud
Private Cloud vs. Public CloudPrivate Cloud vs. Public Cloud
Private Cloud vs. Public CloudStackIQ
 
Datacenter Word Search
Datacenter Word SearchDatacenter Word Search
Datacenter Word SearchStackIQ
 

More from StackIQ (20)

StackiFest 2017 Technology Update
StackiFest 2017 Technology UpdateStackiFest 2017 Technology Update
StackiFest 2017 Technology Update
 
Automation of your OpenStack Infrastructure with Stacki
Automation of your OpenStack Infrastructure with StackiAutomation of your OpenStack Infrastructure with Stacki
Automation of your OpenStack Infrastructure with Stacki
 
StackiFest 2017 Welcome & Opening Address
StackiFest 2017 Welcome & Opening AddressStackiFest 2017 Welcome & Opening Address
StackiFest 2017 Welcome & Opening Address
 
Provisioning Heterogenous Bare Metal with Stacki
Provisioning Heterogenous Bare Metal with StackiProvisioning Heterogenous Bare Metal with Stacki
Provisioning Heterogenous Bare Metal with Stacki
 
Provisioning with Stacki at NIST
Provisioning with Stacki at NISTProvisioning with Stacki at NIST
Provisioning with Stacki at NIST
 
Public vs. Private Cloud Performance by Flex
Public vs. Private Cloud Performance by FlexPublic vs. Private Cloud Performance by Flex
Public vs. Private Cloud Performance by Flex
 
SF Bay Area OpenStack Meetup Stacki Presentation
SF Bay Area OpenStack Meetup Stacki Presentation SF Bay Area OpenStack Meetup Stacki Presentation
SF Bay Area OpenStack Meetup Stacki Presentation
 
Stacki at the Seattle Scalability Meetup
Stacki at the Seattle Scalability MeetupStacki at the Seattle Scalability Meetup
Stacki at the Seattle Scalability Meetup
 
StackiFest16: Building a Cluster with Stacki - Greg Bruno
StackiFest16: Building a Cluster with Stacki - Greg BrunoStackiFest16: Building a Cluster with Stacki - Greg Bruno
StackiFest16: Building a Cluster with Stacki - Greg Bruno
 
StackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg Bruno
StackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg BrunoStackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg Bruno
StackiFest16: How PayPal got a 300 Nodes up in 14 minutes - Greg Bruno
 
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha
StackiFest16: Automation for Event-Driven Infrastructure - Dave Boucha
 
StackiFest16: What's Next in Stacki - Mason Katz
StackiFest16: What's Next in Stacki - Mason Katz StackiFest16: What's Next in Stacki - Mason Katz
StackiFest16: What's Next in Stacki - Mason Katz
 
StackiFest16: CoreOS/Ubuntu on Stacki
StackiFest16: CoreOS/Ubuntu on Stacki StackiFest16: CoreOS/Ubuntu on Stacki
StackiFest16: CoreOS/Ubuntu on Stacki
 
StackiFest16: Building a Cart
StackiFest16: Building a CartStackiFest16: Building a Cart
StackiFest16: Building a Cart
 
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce
StackiFest16: Stacki 1600+ Server Journey - Dave Peterson, Salesforce
 
StackiFest 16: Stacki Overview- Anoop Rajendra
StackiFest 16: Stacki Overview- Anoop Rajendra StackiFest 16: Stacki Overview- Anoop Rajendra
StackiFest 16: Stacki Overview- Anoop Rajendra
 
Introduction to Stacki at Atlanta Meetup February 2016
Introduction to Stacki at Atlanta Meetup February 2016Introduction to Stacki at Atlanta Meetup February 2016
Introduction to Stacki at Atlanta Meetup February 2016
 
Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016Salesforce at Stacki Atlanta Meetup February 2016
Salesforce at Stacki Atlanta Meetup February 2016
 
Private Cloud vs. Public Cloud
Private Cloud vs. Public CloudPrivate Cloud vs. Public Cloud
Private Cloud vs. Public Cloud
 
Datacenter Word Search
Datacenter Word SearchDatacenter Word Search
Datacenter Word Search
 

Recently uploaded

Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)
Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)
Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)Gáspár Nagy
 
What need to be mastered as AI-Powered Java Developers
What need to be mastered as AI-Powered Java DevelopersWhat need to be mastered as AI-Powered Java Developers
What need to be mastered as AI-Powered Java DevelopersEmilyJiang23
 
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product UpdatesGraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product UpdatesNeo4j
 
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAOpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAShane Coughlan
 
Naer Toolbar Redesign - Usability Research Synthesis
Naer Toolbar Redesign - Usability Research SynthesisNaer Toolbar Redesign - Usability Research Synthesis
Naer Toolbar Redesign - Usability Research Synthesisparimabajra
 
Lessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfLessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfSrushith Repakula
 
Malaysia E-Invoice digital signature docpptx
Malaysia E-Invoice digital signature docpptxMalaysia E-Invoice digital signature docpptx
Malaysia E-Invoice digital signature docpptxMok TH
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfarchitecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfWSO2
 
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...Andrea Goulet
 
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...rajkumar669520
 
Crafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationCrafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationWave PLM
 
how-to-download-files-safely-from-the-internet.pdf
how-to-download-files-safely-from-the-internet.pdfhow-to-download-files-safely-from-the-internet.pdf
how-to-download-files-safely-from-the-internet.pdfMehmet Akar
 
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...Alluxio, Inc.
 
Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024Soroosh Khodami
 
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
KLARNA -  Language Models and Knowledge Graphs: A Systems ApproachKLARNA -  Language Models and Knowledge Graphs: A Systems Approach
KLARNA - Language Models and Knowledge Graphs: A Systems ApproachNeo4j
 
JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)Max Lee
 
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...OnePlan Solutions
 
SQL Injection Introduction and Prevention
SQL Injection Introduction and PreventionSQL Injection Introduction and Prevention
SQL Injection Introduction and PreventionMohammed Fazuluddin
 

Recently uploaded (20)

Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)
Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)
Tree in the Forest - Managing Details in BDD Scenarios (live2test 2024)
 
What need to be mastered as AI-Powered Java Developers
What need to be mastered as AI-Powered Java DevelopersWhat need to be mastered as AI-Powered Java Developers
What need to be mastered as AI-Powered Java Developers
 
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product UpdatesGraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
GraphSummit Stockholm - Neo4j - Knowledge Graphs and Product Updates
 
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCAOpenChain Webinar: AboutCode and Beyond - End-to-End SCA
OpenChain Webinar: AboutCode and Beyond - End-to-End SCA
 
Naer Toolbar Redesign - Usability Research Synthesis
Naer Toolbar Redesign - Usability Research SynthesisNaer Toolbar Redesign - Usability Research Synthesis
Naer Toolbar Redesign - Usability Research Synthesis
 
Lessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdfLessons Learned from Building a Serverless Notifications System.pdf
Lessons Learned from Building a Serverless Notifications System.pdf
 
5 Reasons Driving Warehouse Management Systems Demand
5 Reasons Driving Warehouse Management Systems Demand5 Reasons Driving Warehouse Management Systems Demand
5 Reasons Driving Warehouse Management Systems Demand
 
Malaysia E-Invoice digital signature docpptx
Malaysia E-Invoice digital signature docpptxMalaysia E-Invoice digital signature docpptx
Malaysia E-Invoice digital signature docpptx
 
Top Mobile App Development Companies 2024
Top Mobile App Development Companies 2024Top Mobile App Development Companies 2024
Top Mobile App Development Companies 2024
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfarchitecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdf
 
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
Entropy, Software Quality, and Innovation (presented at Princeton Plasma Phys...
 
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
 
Crafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM IntegrationCrafting the Perfect Measurement Sheet with PLM Integration
Crafting the Perfect Measurement Sheet with PLM Integration
 
how-to-download-files-safely-from-the-internet.pdf
how-to-download-files-safely-from-the-internet.pdfhow-to-download-files-safely-from-the-internet.pdf
how-to-download-files-safely-from-the-internet.pdf
 
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
 
Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024Secure Software Ecosystem Teqnation 2024
Secure Software Ecosystem Teqnation 2024
 
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
KLARNA -  Language Models and Knowledge Graphs: A Systems ApproachKLARNA -  Language Models and Knowledge Graphs: A Systems Approach
KLARNA - Language Models and Knowledge Graphs: A Systems Approach
 
JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)JustNaik Solution Deck (stage bus sector)
JustNaik Solution Deck (stage bus sector)
 
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
Optimizing Operations by Aligning Resources with Strategic Objectives Using O...
 
SQL Injection Introduction and Prevention
SQL Injection Introduction and PreventionSQL Injection Introduction and Prevention
SQL Injection Introduction and Prevention
 

Stacki: The Basics of Networking (Tutorial)

  • 1. Stacki Tutorial #1: The Basics of Networking in Stacki Introduction This series of tutorials is designed to offer short, easy to follow steps to customize your use of Stacki. Each tutorial will offer one set of functionality, and fully explain how that functionality can be achieved in Stacki - the world’s fastest open source installer. Summary Stacki, as it is initially installed, will quickly install as many machines as you need with in- telligent default settings. But it is rare that your environment requires default settings, so the tutorial series will teach you how to customize the installed servers to suit your environment. Since everyone needs networking, and every environment is different, we decided this was a good place to start our tutorial series. What you will learn Today’s tutorial will walk you through creating networks in the Stacki server, and adding NICs to backend servers that make use of those networks. There is a lot more of networking in Stacki, but we’ll get to those other items in future tutorials. Pre-requisites This tutorial assumes: 1. You have downloaded Stacki from www.stacki.com 2. You have followed the directions here to install a Stacki server. 3. You have followed the directions here to install backend server(s). 4. You have access to a command line on the Stacki server. 5. You have information about the network(s) you want to add to Stacki. Naming hosts/host groups Most stacki commands take the name of a host. This can be in any of the following forms: hostname - Actual host DNS name host-0-0.local – This machine. hostname* - All hosts whose name match the pattern. Host* - All machines whose names start with host. appliance name - all machines of that appliance type backend – All machines of appliance type backend. Page 1www.stacki.com | Stacki Google Group | Stacki GitHub
  • 2. Let’s Get Started! Log in to the Stacki server, and type the following command: stack list network You should see output like this, assuming you’ve not changed anything yet: These are all of the networks Stacki knows about by default. The private network is used for installations, the public so that you can log into the Stacki server remotely, and get updates in the future. This tutorial will show you how to create new networks, and to modify the “public” network of these. Since “private” is used to do installations, we’ll not do anything with that one until a later tutorial, when we have more information about what can be done with networks. By default, all servers exist on the private network. To see this, type the following… Stack list host interface backend* You should see output like the following: Notice that the interface has a lot of information on it. We’ll get to that in a future installment. To add a network to the list of networks, simply type: stack add network protected 10.10.10.1 255.255.255.0 As you likely guessed already, ‘protected’ will be the network name, ’10.10.10.1 the base address, and 255.255.255.0 the netmask – meaning the network covers all of the 10.10.10.* network. And you can check that the network exists by typing: stack list network again. [root@stackidon ~]# stack list network NETWORK SUBNET NETMASK MTU DNSZONE SERVEDNS private: 10.1.1.0 255.255.255.0 1500 local True public: 192.168.0.0 255.255.255.0 1500 stackiq.com False [root@stackidon ~]# [root@stackidon ~]# stack list host interface backend* HOST SUBNET IFACE MAC IP NETMASK MODULE NAME VLAN OPTIONS CHANNEL backend-0-0: private eth0 08:00:27:6e:88:08 10.1.1.253 255.255.255.0 ------ backend-0-0 ---- ------- ------- backend-0-1: private eth0 08:00:27:3a:e0:e4 10.1.1.254 255.255.255.0 ------ backend-0-1 ---- ------- ------- [root@stackidon ~]# Page 2 Page 2www.stacki.com | Stacki Google Group | Stacki GitHub
  • 3. [root@stackidon ~]# stack add network protected 10.10.10.1 255.255.255.0 [root@stackidon ~]# stack list network NETWORK    SUBNET      NETMASK       MTU   DNSZONE     SERVEDNS private:   10.1.1.0    255.255.255.0 1500  local       True protected: 10.10.10.1  255.255.255.0 1500  protected   False public:    192.168.0.0 255.255.255.0 1500  stackiq.com False [root@stackidon ~]# Now Stacki knows about the protected network, and we can tell backend machines to attach NICs to it. Let’s do so. First, add the interface to the stacki database: stack add host interface backend-0-0 iface=eth1 ip=10.10.10.100 subnet=protected name=prot1 This tells Stacki to add eth1 to server backend-0-0, give it ip 10.10.10.100, attach it to subnet pro- tected, and name it prot1 locally. Now if you type: stack list host interface backend-0-0 You’ll see our new interface in the list, but if you go to a terminal on backend-0-0, you will not find it listed with ifconfig. That is because Stacki knows about it, but hasn’t updated the server yet. To update the server type: Stack sync host network backend-0-0 It will tell the host about its new interface, and bring the interface up. If you go to the backend servers’ terminal and type ifconfig, you will see eth1 is now there, and it is fully functional (as- suming you put it on the right network with a valid IP). [root@stackidon ~]# stack add host interface backend-0-0 iface=eth1 ip=10.10.10.100 subnet=pro- tected name=prot1 [root@stackidon ~]# stack list host interface backend-0-0 SUBNET IFACE MAC IP NETMASK MODULE NAME VLAN OPTIONS CHANNEL private eth0 08:00:27:6e:88:08 10.1.1.253 255.255.255.0 ------ backend-0-0 ---- ------- --- ---- protected eth1 ----------------- 10.10.10.100 255.255.255.0 ------ prot1 ---- ------- --- ---- [root@stackidon ~]# stack sync host network backend-0-0 [root@stackidon ~]# Page 3www.stacki.com | Stacki Google Group | Stacki GitHub
  • 4. Now we can check on the host… That’s it for this tutorial! You now can access a variety of networks in your environment simply by defining the network and interfaces on the command line. That’s it for this tutorial! You now can access a variety of networks in your environment simply by defining the network and interfaces on the command line. [root@stackidon ~]# ssh backend-0-0 Last login: Wed Jul 1 14:00:06 2015 [root@backend-0-0 ~]# ifconfig eth0 Link encap:Ethernet HWaddr 08:00:27:6E:88:08 inet addr:10.1.1.253 Bcast:10.1.1.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:308 errors:0 dropped:0 overruns:0 frame:0 TX packets:282 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:48737 (47.5 KiB) TX bytes:38985 (38.0 KiB) eth1 Link encap:Ethernet HWaddr 08:00:27:D0:67:B5 inet addr:10.10.10.100 Bcast:10.10.10.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:55 errors:0 dropped:0 overruns:0 frame:0 TX packets:4 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:5148 (5.0 KiB) TX bytes:168 (168.0 b) lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:5 errors:0 dropped:0 overruns:0 frame:0 TX packets:5 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:780 (780.0 b) TX bytes:780 (780.0 b) [root@backend-0-0 ~]# Stacki Tutorial #1: The Basics of Networking in Stacki © 2015 StackIQ, Inc. | www.stacki.com Page 4www.stacki.com | Stacki Google Group | Stacki GitHub