Shell

Create Swap File

#!/bin/bash -e # Set default variable values : ${SWAP_SIZE_MEGABYTES:=1024} : ${SWAP_FILE_LOCATION:=/var/swap.space} if (( $SWAP_SIZE_MEGABYTES <= 0 )); then echo 'No… Read More

November 8, 2012 8:54 am

Find Directories & Add Group Sticky Bit

Probably make another post explaining what a sticky bit is and how it's used, but for now I'm giving you… Read More

November 8, 2012 8:52 am

Output Directories to Shell

find . -maxdepth 99 -mindepth 1 -type d -printf %P\\n ls -1l | grep '^d' | awk '{print $8}' find… Read More

November 8, 2012 8:49 am

CHMOD Directories Only

Change UNIX permissions on directories only. find . -type d -print0 | xargs -0 chmod 755 Read More

November 8, 2012 8:46 am