Linux

Articles and posts about using the linux operating system

PHP What is Opcode Cache and When to Use it

Are you wondering: What is Opcode Cache and When to Use it? I just read an excellent article entitled PHP Performance I: Everything You Need To Know About OpCode Caches published by Engine Yard. The article is a transcript of a video on PHP opcode cache, actually. Engine Yard goes into just enough detail, allowing… Read more PHP What is Opcode Cache and When to Use it

Use ps to view Processes, sort them, and kill them

This is a quick note on how to work with linux/Unix/Mac processes. If you want to go straight for the ‘kill’ Start by getting the process ID with pgrep process name. Then use kill to kill the process. But, be nice about it, ok? $>pgrep mongod $>kill <PID> Use ps to List Processes $> ps… Read more Use ps to view Processes, sort them, and kill them

Linux mkdir for Make Directory with -m and/or -p

linux Make Directory command mkdir -m is for Permissions (because -p was taken for parents) -m is for permissions. By default, new directories are created with the read, write and execute permissions enabled for the owner of the directory and group and the read and execute permissions enabled for other users. To create a directory named… Read more Linux mkdir for Make Directory with -m and/or -p

How to set up ubuntu secure ssh login (AWS & Digital Ocean)

Ubuntu Initial Setup: setup ubuntu secure ssh login on digitalocean or Amazon Web Services EC2 instance Download PDF:  Download Secure Login Cheat Sheet PDF This post is a “cut to the chase”, “gitter dun” list of things to do for initial setup of an ubuntu server. To gain a deeper understanding of the process of securing… Read more How to set up ubuntu secure ssh login (AWS & Digital Ocean)

How to use multiple ssh keys for different accounts

I wanted to have multiple rsa keys for various different hosts to help prevent hidden connection issues. Issues may arises when an rsa key is changed on one host that may have been used on another host effectively severing the connection without your knowledge. By having different rsa keys when dealing with a host that… Read more How to use multiple ssh keys for different accounts

How To Create a Password Hash with Python passlib

Create a password hash with python passlib A quick and easy way to create a password hash is with python passlib. Install passlib with pip like this:

Then, run the command below. Of course, you will replace the text “myplaintextpassword” with YOUR OWN plain text password, right?

You’ll get back something that looks… Read more How To Create a Password Hash with Python passlib

How to Reset the ROOT Password for MySQL on Mac OS 10.10

This post explains how to reset the MySQL root user on a Mac running OS 10.10. This procedure is for the case that you are unable to log in as the root user and need to reset the root user’s password. Note that there are 2 colored sets of examples. One is for MySQL installed… Read more How to Reset the ROOT Password for MySQL on Mac OS 10.10

Restart Apache on Mac 10.10

If you do not stop and restart apache often, it’s easy to forget how. apachectl -help says to uses -k flag with the following options start|restart|graceful|graceful-stop|stop.

So, to restart apache, do the following command.