twitter linkedin youtube
  • About
  • Blog
  • My Services
  • Twitter
  • LinkedIn
  • Email
All tags

    Python PDB

    An interactive debugger which allows you to interact via the python shell at specific places within your code. The two important parts are import pdb --> Use the pdb library pdb.set_trace() --> Use this in each part of the code where you want to invoke the…

    Read More
    • Python

    VIM Block Edits

    Select the block Ctrl-V for Visual Block mode This will allow you to work with columns and rows. For example, you can insert new characters to the beginning of a set of new lines (think adding indentation, comment # symbols, etc) } for paragraph (or G to end of file, etc) Insert…

    Read More
    • vim
    • linux

    Getting started with Python Virtualenv

    Create a new Virtualenv virtualenv {name_of_virtualenv} Interactively load the virtualenv source ./{name_of_virtualenv}/bin/activate Work in the virtualenv cd ~/{name_of_virtualenv} git clone {repo} pip install -r ./{repo}/requirements.txt ./{repo}/{some_thing}.py Or, to run a python script within a virtualenv once (e.…

    Read More
    • Python
    • linux

    RedHat/CentOS boots into emergency mode if it can't mount a filesystem listed in fstab

    I encountered this on CentOS 7.2 Overview A server had a bad entry in /etc/fstab. This wasn't critical for the operation of the Linux OS (i.e. it wasn't / , /var etc), just a data filesystem. In this case, LVM hadn't quite been…

    Read More
    • linux
    • centos

    Kickstart Metadata Parameters when using Cobbler as a Puppet ENC

    When using Cobbler as Puppet's External Node Classifier, the Kictstart Metadata parameters configured in Cobbler override those derived from Puppet (e.g. using facts). Cobbler Metadata example [root@cobblerserver ~]# cobbler distro report --name=centos7.4-x86_64 | grep Metadata Kickstart Metadata : {'operatingsystemrelease': '7.2.1511'…

    Read More
    • cobbler
    • puppet
    • linux

    Load more posts
    Subscribe!
    All content copyright © 2025 • All rights reserved.
    Proudly published with Ghost