SyntaxHighlighter JS


Ruby on Rails json LoadError

Running Ruby on Rails 'bin/rails s' and you get an error

in require: cannot load such file -- json (LoadError)

Edit the Gemfile and add

gem 'json'

Installing Ruby on Rails on AWS Linux

To install Ruby on Rails on the AWS Linux VM, you need to install some prerequisites first.

sudo su -
yum install -y ruby24
alternatives --set ruby /usr/bin/ruby2.4
yum install -y ruby24-devel rubygems ruby24-devel gcc zlib-devel patch sqlite-devel
curl -sL | bash -
yum install -y nodejs

gem install rails
rails --version


Add hard disk to VMware CentOS 7 VM

There are two easy steps to add a hard disk for a a VMware CentOS 7 VM

  1.  Assign a new hard disk in VMware vSphere
  2.  Configure the new hard disk in CentOS
See the full picture tutorial at


Get the original username of sudo

For auditing and logging purposes, I needed to get the original Unix login username and not the sudo account name.

The Unix command to get the original login username is


With the logname command, the operator can su and sudo to various accounts and it will still display the original login.

To try it on a Unix prompt

sudo su - oracle
echo My sudo id is $(whoami) and my login id is $(logname)

My sudo id is oracle and my login id is juttayaya