Skip to content

Latest commit

 

History

History
executable file
·
120 lines (76 loc) · 3.03 KB

FIX.md

File metadata and controls

executable file
·
120 lines (76 loc) · 3.03 KB

+++ date = "2016-02-25" draft = false weight = 20 title = "FIX" +++

Fixes

  1. Reset aliceanderson password example
    keystone user-password-update aliceanderson --pass fa5tpa55w0rd

  2. How to "unsource" your bash session
    source .bashrc

A fix to avoid slow yum mirror in anisble lab when a mirror is down and yum slows to a craw or completely fails.

  1. Why are YUM updates taking so long!!
  1. In your home directory, make a new directory called "files"

  2. copy /etc/yum.conf to /~/files

  3. Edit your new yum.conf file by adding retries=1 to the bottom of the config as shown below.

[main]
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=5
bugtracker_url=http://bugs.centos.org/set_project.php?project_id=23&ref=http://bugs.centos.org/bug_report_page.php?category=yum
distroverpkg=centos-release
retries=1
  1. Save the file

  2. After you have downloaded sl.yml file, modify it to look like this:

 
- hosts: openstack
  remote_user: root
  tasks:
  - name: Look at me adding my first line of devops code! The next line of code updates yum.conf on all my hosts, this is really cool.
    copy: src=/home/centos/files/yum.conf dest=/etc/yum.conf owner=root group=root mode=0644
  - name: Install sl even though I have no idea what sl does... yet.
    yum: name=sl state=installed

Now run the sl.yml playbook and it should go a lot faster.

How to save files from my Openstack Lab to view later

  1. First do lab 13 which will set up an account with github

  2. Then SSH into your controller and issue these commands

    `mkdir ~/myopenstack``

    cd myopenstack

    yum install git

    git config --global user.name "---Your Name Here---"

    git config --global user.email "[email protected]"

    git config --list

    git init

    touch readme.txt

    vim readme.txt

    This is my test file to see if I can push a file up to gut hub.

    git status

    git add readme.txt

    git commit -m 'This is supposed to add Readme.txt to my repository'

    git add

    CREATE REPOSITORY on github called 'myopenstack'

    git remote add origin https://github.com/YOUR-ACCOUNT-NAME-HERE/myopenstack.git

    git push origin master

    # respond to login
    # respond to password

Out of sync? Do this

git remove origin

remote add origin https://github.com/YOUR-ACCOUNT-NAME-HERE/myopenstack.git

git pull origin master

This will sync github with your current directly

git push origin master

Now that you are synced with github, this should work