Thursday, October 26, 2023

Bookmark: How to set iTerm2/3 tabbing behavior to sequential order rather than recency

 Background:

iTerm2/3 has built-in functionality to switch between tabs between the most recently used one.  

Problem:

If you're used to changing tabs similar to how Chrome, Edge, and Firefox behave, this can be a frustrating experience in context switching how to move between tabs when working in iTerm in a multiple-tabbed session. 

Solution:

So, if you're not used to this behavior (i.e. you prefer incrementally switching tabs to the right via Ctrl-Tab or to the left via Ctrl-Shift-Tab), this can be remapped within the iTerm profile keyboard settings, to replace the internal intepretation of Ctrl-Tab to Next Tab and Ctrl-Shift-Tab to Previous Tab.


References:

Additional details available here including the original bug filed as well as a more-detailed steps in their solution:
https://gitlab.com/gnachman/iterm2/-/issues/8219


Monday, September 27, 2021

Install multiple versions of JDK and switch between them via CLI on MAC OSX:

(Updated to include newer JDK versions)

1.11: https://www.oracle.com/java/technologies/javase/jdk11-archive-downloads.html
1.17: https://www.oracle.com/java/technologies/downloads/#JDK17


2) Add the following to the ~/.bashrc or ~/.zshrc
#Set JAVA_HOME to latest version of JAVA_HOME (recommended)
export JAVA_HOME=$(/usr/libexec/java_home)
 

#Set alias options to dynamically change JAVA_HOME to particular JDK
alias jdk6=
' export JAVA_HOME=$(/usr/libexec/java_home -v 1.6.0) '
alias jdk7=' export JAVA_HOME=$(/usr/libexec/java_home -v 1.7.0) '
alias jdk8=' export JAVA_HOME=$(/usr/libexec/java_home -v 1.8.0) '
alias jdk11=' export JAVA_HOME=$(/usr/libexec/java_home -v 11) '
alias jdk17=' export JAVA_HOME=$(/usr/libexec/java_home -v 17) '



3) To switch between the versions of JDK, run the command jdkXX, for example:

#Default version as listed above will always set the JAVA_HOME to the latest version as determined by java_home:
$ java -version
java version "1.8.0_60"
Java(TM) SE Runtime Environment (build 1.8.0_60-b27)
Java HotSpot(TM) 64-Bit Server VM (build 25.60-b23, mixed mode)
 

$ jdk6
$ java -version
java version "1.6.0_65"
Java(TM) SE Runtime Environment (build 1.6.0_65-b14-468-11M4833)
Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-468, mixed mode)
 

$ jdk7
$ java -version
java version "1.7.0_72"
Java(TM) SE Runtime Environment (build 1.7.0_72-b14)
Java HotSpot(TM) 64-Bit Server VM (build 24.72-b04, mixed mode)

jdk11
$ java -version
java version "11.0.11" 2021-04-20 LTS
Java(TM) SE Runtime Environment 18.9 (build 11.0.11+9-LTS-194)
Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11.0.11+9-LTS-194, mixed mode)

$ jdk17
$ java -version
java version "17" 2021-09-14 LTS
Java(TM) SE Runtime Environment (build 17+35-LTS-2724)
Java HotSpot(TM) 64-Bit Server VM (build 17+35-LTS-2724, mixed mode, sharing)



Monday, August 10, 2020

Show count and instance IDs of existing EC2 instances in all regions of AWS:

I'm kicking myself for not posting this earlier in my past life-- but here's a handy shell script that can list the number of instances in each region in AWS.


Show count and instance IDs of existing EC2 instances in all regions of AWS:


Single line:

Set my AWS profile to my personal account rather than work.  
To setup, use aws --profile personal configure   

$ export aws_profile=personal


If the buffer space can handle long entries, you can run this in a single line, otherwise there's a multi line below to run as a script.

    $ for i in $(aws --profile $aws_profile ec2 describe-regions --output json | grep "RegionName" | cut -d '"' -f4 | sort); do export buf=$(aws --profile $aws_profile ec2 --region $i describe-instances --output json | grep InstanceId | cut -d '"' -f4); export buf_num=$(echo $buf | grep -c .); echo "=== $i -> $buf_num instance(s) ===";echo $buf ; done

    Multi Line:

    Good for placing into a script to run, also listed this way for readability:
    1. #!/bin/bash export aws_profile=personal for i in $(aws --profile $aws_profile ec2 describe-regions --output json| grep "RegionName" | cut -d '"' -f4 | sort); do export buf=$(aws ec2 describe-instances \ --profile $aws_profile \ --region $i \ --output json | \ grep InstanceId | \ cut -d '"' -f4); export buf_num=$(echo $buf | grep -c .); echo "=== $i -> $buf_num instance(s) ==="; echo $buf; done

    Sample Output:

    1. === ap-northeast-1 -> 0 instances === === ap-northeast-2 -> 0 instances === === ap-south-1 -> 0 instances === === ap-southeast-1 -> 0 instances === === ap-southeast-2 -> 0 instances === === ca-central-1 -> 0 instances === === eu-central-1 -> 0 instances === === eu-north-1 -> 0 instances === === eu-west-1 -> 0 instances === === eu-west-2 -> 0 instances === === eu-west-3 -> 0 instances === === sa-east-1 -> 0 instances === === us-east-1 -> 0 instances === === us-east-2 -> 0 instances === === us-west-1 -> 0 instances === === us-west-2 -> 1 instances === i-012345678901234ab

    Friday, February 28, 2020

    Backing up dot files in my home folder

    In spending some time with customizing my machine, I have some heavily modified configuration files within my home folder.  As a good measure, here's a way to help backup dot files in your home folder:

    $ tar cvfz my_dotfile_backup-$(date +"%Y-%m-%d").tar.gz --exclude .file_to_exclude --exclude .vscode  ~/\.*

    The above will:
      • c = create a tarball
      • v = verbose
      • f = write the output to the specificed file
      • z = compress the output file with gzip. 
      • Output filename will be "my_dotfile_backup-" + the date the command was run in YYYY-MM-DD format + ".tar.gz"
      • Exclude files matching .file_to_exclude, and .vscode
      • ~ = My home folder
      • \.* Escaped dot character then wildcard (meaning the filename needs to start with a .)
    Here's an example output of when the command above was run:

    $ ls -l my_dot*

    -rw-r--r--  1 arojas  staff  30093272 Feb 28 12:17 my_dotfile_backup-2020-02-28.tar.gz

    Monday, February 10, 2020

    Update Sublime Text to automatically default a particular filetype



    Found this nugget today on Stack Overflow:
    https://stackoverflow.com/questions/7574502/set-default-syntax-to-different-filetype-in-sublime-text-2

    In a nutshell, Colin R a user from Stack Overflow suggested that the following steps can be used to set the defaults for all future new files opened in Sublime Text, which is much easier than having to hack around the JSON preferences.

    In a nutshell, Sublime Text -> View -> Syntax -> Open all with Current Extension As... ->  Select default option.

    Not exactly sure why certain options aren't available as a default, will continue digging into that:

    Thursday, October 24, 2019

    Windows 10 and EFI System Partitions

    I recently was trying to swap some SSD drives between laptops and still keep the same OSes on the respective machines, which involved some backup and disk cloning.  That wasn't difficult, it was the point when I couldn't leave well enough alone, I saw one of the SSD drives with ~ 500MB of a FAT32 partition that was unused, so I figured I could move around some partitions using a partition editor to shuffle up the hidden partitions, and expand the main OS partition.  Well that was well and good until I tried slightly extending the EFI partition, and that broke a lot of stuff.   Then I realized the hard way that the EFI partition is a special partition that can't be cloned to from another disk image that has a good EFI partition.  (I didn't wan't to clone the entire drive again because there was more work I did on the new system that wasn't on the backup, silly me).

    Thankfully, digging around the interwebs, I was able to find some resources from a few sites about EFI partitions and how to unfubar oneself.  (Credits and links to the original sites below):


    Per Wikipedia: https://en.wikipedia.org/wiki/EFI_system_partition:
    "The EFI (Extensible Firmware Interface) system partition or ESP is a partition on a data storage device (usually a hard disk drive or solid-state drive) that is used by computers adhering to the Unified Extensible Firmware Interface (UEFI)."


    EFI should really be renamed Eventually Fubared Instantly.



    If the EFI partition ever gets nuked, wrecked, or just plain fubar, consider running through these steps:


    To Delete the EFI System Partition in Windows 10:
    1. If you can't boot the system perform step 1a, then go to step 2.  If you can boot the system, skip step 1a and continue with step 1b:.

    1a. Boot using a Windows 10 USB Key, selecting Repair;  Go to Advanced Tools and select a Command Prompt.  

    1b. On the Start menu find and run the Command Prompt as Administrator

    2. Run DISKPART, the Windows Disk Partition Tool
    C:\> diskpart

    On the DISKPART> prompt, go through the following steps:
    3. List the disks that are detected:
    DISKPART> list disk

    4. After identifying the main disk containing the EFI partition (or where it used to be) select it:
    DISKPART> select disk 1

    5.List the disk partitions to identify which partition the EFI partition was or the partition you would like it to be:
    DISKPART> list part

    6. Select the partition:
    DISKPART> select part 1

    7. Delete the partition:
    DISKPART> delete part



    To Create the EFI System Partition in Windows 10:
    1. If you can't boot the system perform step 1a, then go to step 2.  If you can boot the system, skip step 1a and continue with step 1b:.

    1a. Boot using a Windows 10 USB Key, selecting Repair;  Go to Advanced Tools and select a Command Prompt.  

    1b. On the Start menu find and run the Command Prompt as Administrator

    2. Run DISKPART, the Windows Disk Partition Tool

    On the DISKPART> prompt, go through the following steps:
    3. List the disks that are detected:
    DISKPART> list disk

    4. After identifying the main disk containing the EFI partition (or where it used to be) select it:
    DISKPART> select disk 1

    5.List the disk partitions to identify which partition the EFI partition was or the partition you would like it to be:
    DISKPART> list part

    6. Select the partition:
    DISKPART> select part 1

    7. Create the partition:
    DISKPART> create partition efi

    8. Format the partition to FAT32:
    DISKPART> format quick fs=fat32

    9. Identify the volume where the Windows OS is installed (i.e. C:\WINDOWS).  Note the drive letter here may be different than C, this may be temporary:
    DISKPART> list volume

    10. Exit Diskpart and run the tool to copy the needed files to the EFT partition, noting the drive letter where Windows was installed on Step 9 above:  (Replace the D below with the proper drive letter):
    C:\> bcdboot D:\windows

    11:  Close out the command prompt and reboot the system, you should be good to go!


    Credit to AnyRecover for their original instructions:
    https://www.anyrecover.com/hard-drive-recovery-data/how-to-create-and-delete-efi-system-partition-in-windows/#tip1

    Tuesday, September 17, 2019

    Testing Gzipped Tarball in Bash

    Originally sourced from stack exchange. modified a bit:
    https://unix.stackexchange.com/questions/129599/test-tar-file-integrity-in-bash

    Modified from the source link above, the following command will iteratively test each .tgz file within the current directory for errors, and if any are detected, will report an error.

    $ for i in *.tgz; do echo "Testing $i..."; if tar xOfz $i &> /dev/null;  then echo "Error with tarball $i"; fi; done


    Options used:
     x  - Extract from archive
     O  - Write output to standard out instead of disk
     f  - Read input from a file
     z  - Tarball is compressed with Gzip (Some OSes may automatically detect Gzip and not need this option)
     &> /dev/null  -   Redirect both stdout and stderr to /dev/null

    Misc. Linux Sysadmin tips

    Got around to updating the home office machines, and thought it would be a good idea to keep some recurring tips handy:



    Disabling SSH login for root user

    1.  Edit /etc/ssh/sshd_config
    2. Set PermitRootLogin to no (Remove # if present)
    3. Add AllowUsers  
    4. Save, then restart sshd: 
      $ service sshd restart

    Setup Passwordless SSH:
    1. Create SSH keypair with options, such as:
      $ ssh-keygen -b 5120
    2. chmod created keypair: 
      $ chmod 600
    3. SCP the public key to target machine.
    4. On target machine:
      $ mkdir ~/.ssh$ chmod 700 ~/.ssh
    5. If ~/.ssh/authorized_keys doesn't exist:
       move the public key from home folder to ~/.ssh/authorized_keys then
      $ chmod 600 ~/.ssh/authorized_keys
    6. If it does exist, then append the public key to the authorized_keys: 
      $ cat >> ~/.ssh/authorized_keys, then delete the public key.
    7. Test by SSHing to the target machine

    Editing Hostnames
    1. Edit /etc/sysconfig/network.  modify HOSTNAME= to FQDN
    2. Edit /etc/hosts.  Add IP address with FQDN and shortname
    3. Restart network services:
      $ /etc/init.d/network restart

    Wednesday, April 4, 2018

    com.apple.preference.displays.MirrorDisplays): Service only ran for 0 seconds. Grrrrrr.




    I've had my Mac Pro 6,1 for a few months and noticed that the display crashes every few weeks, where the symptoms range from 1) screen is "frozen as-is", 2) while mouse cursor can move 3) Cannot click on anything on the screen. 4) System clock on screen is stuck at the time the displays froze, and 5) System is still responsive through SSH.

    While there was some discussion on various boards about the issue being due to the AMD FirePro D500 and D700 cards, I have a pair of D300s in this unit, which aren't supposed to be impacted by the known Apple Issue.


    This occurred again recently and after getting some time to dig into things further, I looked into /var/log/system.log file to see what was the most recent entries prior to the latest freeze episode.

    Found the following:

    Output snippet from /var/log/system.log
    Apr  4 11:01:18 macpro com.apple.xpc.launchd[1] (com.apple.preference.displays.MirrorDisplays): Service only ran for 0 seconds. Pushing respawn out by 10 seconds.
    Apr  4 11:01:28 macpro com.apple.xpc.launchd[1] (com.apple.preference.displays.MirrorDisplays): Service only ran for 0 seconds. Pushing respawn out by 10 seconds.
    Apr  4 11:01:38 macpro com.apple.xpc.launchd[1] (com.apple.preference.displays.MirrorDisplays): Service only ran for 0 seconds. Pushing respawn out by 10 seconds.
    Apr  4 11:01:58 macpro com.apple.xpc.launchd[1] (com.apple.preference.displays.MirrorDisplays): Service only ran for 0 seconds. Pushing respawn out by 10 seconds.
    Apr  4 11:02:28 macpro com.apple.xpc.launchd[1] (com.apple.preference.displays.MirrorDisplays): Service only ran for 0 seconds. Pushing respawn out by 10 seconds.


    In digging around the web, found the above link on Stackexchange that talks about this issue being related to a particular issue with out an Apple plugin is behaving badly, and lists instructions on how to temporarily disable it:

    Here's the overall steps taken:
    Sourced from Stackechange article:
    https://apple.stackexchange.com/questions/304745/mirrordisplays-error-every-30-seconds-in-system-log



    1. Disable System Integrity Protection so you can edit the .plist file. Do this by rebooting into the recovery partition with cmd-R, open Terminal from the Utilities menu, and type:
      $ csrutil disable
    2. Reboot, then edit the .plist file with this command:
      $ sudo vi /System/Library/LaunchAgents/com.apple.preference.displays.MirrorDisplays.plist
    3. Comment out the line that causes the MirrorDisplays tool to load. Change this line:
         
    4. To this:
    5. Then, reboot and re-enable System Integrity Protection using the recovery partition as described above and type:
      $ csrutil enable
    6. Reboot 

    After implementing the changes, it appears that this has stopped the occurrence:


    $ grep "MirrorDisplays): Service only ran" system.log | cut -d ':' -f1 | uniq -c

     164 Apr  4 11

     172 Apr  4 12
      47 Apr  4 13
       3 Apr  4 14

    The above command is grepping the system.log for the event occurrence, then parsing based on the first colon ':' which filters out everything of the error past the Day and Hour. So the above output shows that at 11am it occurred 164 times, 12pm occurred 172 times, 1pm 47 and so on...

    It's now almost 4pm and no occurrences since disabling!  Keeping fingers crossed that this will fix the freezing scenario, otherwise will continue trudging through the system.log file on the next freeze.


    Tuesday, January 9, 2018

    Random sleep time in Bash

    Recently, I needed to setup a script that would sleep a certain number of seconds between 1 and 8.  Stumbled across this particular item, which was adapted to my need:


    $ sleep $[ ( $RANDOM % 8 ) + 1 ]s

    This would sleep anywhere from 1 second to 8 seconds before continuing.  If the need comes up to set to a different limits, you can change the 8 to the max number and the 1 to the minimum.  Note that increasing the minimum value will affect the max number as well if min > 1.

    Sourced from: http://blog.buberel.org/2010/07/howto-random-sleep-duration-in-bash.html


    Saturday, September 16, 2017

    Adding Ctrl-Shift-Tab and Ctrl-Tab to Logitech Mouse buttons in Ubuntu

    What was very helpful was setting up Ubuntu 16.10 to allow the "back" and "forward" buttons on my wireless Logitech mouse to map to Ctrl-Shift-Tab and Ctrl-Tab respectively, to more closely mimic a better workflow for navigating through massive web tabs.

    1) Install needed libs in Ubuntu 16.10:
    $ sudo apt-get install -y xbindkeys xautomation xev

    2) Create xbindkeys rc file if not already created:
    $ xbindkeys --defaults > ~/.xbindkeysrc

    3) Append this to ~/.xbindkeysrc:
    4) Re-run xbindkeys
    $ kill $(ps aux | grep xbindkeys$ | awk '{print$2}');  xbindkeys


    Information originally sourced from these links:
    https://linux.die.net/man/1/xte
    https://askubuntu.com/questions/152297/how-to-configure-extra-buttons-in-logitech-mouse

    Monday, August 14, 2017

    Enabling 1080p recording on Techsmith's Camtasia (Mac)

    Sourced from: https://feedback.techsmith.com/techsmith/topics/1080p-recording


    The webcam recording in Camtasia is factory-limited to 720p for performance reasons, but can be user-modified.  There are two preferences needed to implement the change, maxCameraWidthRecordingScreen and maxCameraWidthNotRecordingScreen.

    To set the preferences, implement the following in a Mac Terminal:


    $ defaults write com.techsmith.camtasia2.plist maxCameraWidthRecordingScreen -int 1920$ defaults write com.techsmith.camtasia2.plist maxCameraWidthNotRecordingScreen -int 1920
    This should be done when Camtasia is not running.


    NOTE regarding the Camtasia Application:
    If you are running the non App Store build, the plist is 
    ~/Library/Preferences/com.techsmith.camtasia2.plist  .  

    If you are running an App Store build, it is ~/Library/Containers/com.techsmith.camtasia2/Data/Library/Preferences/com.techsmith.camtasia2.plist .

    Thursday, June 1, 2017

    Allow .mp4 files to be streamable on simple Apache Webserver


    Sourced from http://blog.servergrove.com/2012/04/18/configuring-your-apache-web-server-for-html5-video-formats/

    To ensure that a simple Apache Webserver is able to stream video, ensure to add the following to the .htaccess file:

    AddType video/ogg .ogv
    AddType video/mp4 .mp4
    AddType video/webm .webm

    Tuesday, March 28, 2017

    Uncompress file to HDFS without unzipping on local FS

    Sourced from: http://bigdatanoob.blogspot.com/2011/07/copy-and-uncompress-file-to-hdfs.html


    Quick and dirty method to be able to uncompress a large file directly into HDFS without having to uncompress locally:

    Syntax:
           $ gunzip -c localfile.gz | hadoop fs -put - /user/user1/localfile


    Explanation of options:
           gunzip -c  = The -c option causes the output of the gunzip operation to be written to the
           console.

           The '-' specified in the hadoop fs -put operation points the source file to be originated
           from the console.


    So with this example:
           $ gunzip -c 3GB_json.gz | hadoop fs -put - /user/cloudera/3GB_json

    The shell will run gunzip using the a compressed 3GB Json file (3GB_json.gz) sending its output to the console, which is then piped into the hadoop fs -put operation, which will then place the payload into the file /user/cloudera/3GB_json.







    Friday, November 4, 2016

    Quick and Dirty Web Service (to serve Parcels and Packages) from a Mac

    The following command can be run from a Mac to allow service to run a simple Web server to allow connectivity to access the files located on /path/to/parcels.  Very useful for spinning up a quick CM/CDH repro cluster and needing to post a repo to host CM/CDH/Other parcels.  

    $ cd /path/to/parcels; ifconfig | grep inet; sudo python -m SimpleHTTPServer 80

    (Originally sourced from: http://lifehacker.com/start-a-simple-web-server-from-any-directory-on-your-ma-496425450, modified to fit this use-case)


    The breakdown of the above command:
    1) Change dir to the specified location to share/make available
    2) Report all of the available network interfaces and display their IP address
    3) Run the python package for SimpleHTTPServer on port 80.

    Thursday, September 29, 2016

    Quickly update user password in an automated fashion


     Helpful when updating a user password in a script for small test clusters:

    $  ssh remoteserver 'useradd newuser;  $PASSWD_COMMAND'

    where $PASSWD_COMMAND  is one of the following:

        echo -e "newpassword\newpassword" | passwd newuser

        echo "newuser:newpassword" | chpasswd


        echo "newpassword" | passwd --stdin newuser

    Saturday, September 17, 2016

    Install Mac OSX El Capitan to a USB stick via CLI


    On the command line, copy and paste the following.  NOTE: Substitute the path of the actual USB stick in place of  /Volumes/:

    sudo /Applications/Install\ OS\ X\ El\ Capitan.app/Contents/Resources/createinstallmedia --volume /Volumes/ --applicationpath /Applications/Install\ OS\ X\ El\ Capitan.app


    Sourced from:
    http://www.macworld.com/article/2981585/operating-systems/how-to-make-a-bootable-os-x-10-11-el-capitan-installer-drive.html




    Friday, September 16, 2016

    Install Cisco's Webex Plugin on the Opera Web Browser

    Confirmed to install and run with the following versions of software:


    • Opera Web Browser 39.0.2256.71
    • Cisco Webex Extension Version 1.0.1 (Updated on 9/5/2014)
    Dependencies:
    • Opera needs to have the following extension installed to allow installation of Chrome plugins:

    Per the Webex support document for installing the Webex Extension, the following link is used to install the Webex extension:

    https://chrome.google.com/webstore/detail/cisco-webexextension/jlhmfgmfgeifomenelglieieghnjghma?hl=en&authuser=1


    Installation Steps:

    1. Install the CRX Extension Source Viewer in Opera
    2. Navigate to the Cisco Webex Extension plugin install page
    3. Click on the yellow CRX button  on the top of the Opera page 
    4. Click on Install 
    5. Opera will now navigate to the Opera Extensions page, and will prompt to install.   Click on the install button  and the Cisco Webex plugin should install.
    6. Once completed, the Cisco Webex Extension should now appear in the Opera Extensions page:



    Tuesday, August 16, 2016

    Sort a group of log4j-based log files by timestamp

    Assuming that each log file consists of complete timestamps on the beginning and end (i.e. it's not abruptly truncated), here's a quick command to list first and last timestamps of a set of log4j log files, sorted in ascending order by first timestamp:
    $ (for i in *.log.out*; do echo -n $i'\t'$(sed '1p;$!d' $i | cut -d ' ' -f-2 | tr '\n' '\t')'\n'; done) | sort -k2

    To sort by last timestamp on each file, change sort argument from -k2 to -k4

    Example:
    $ (for i in *.log.out*; do echo -n $i'\t'$(sed '1p;$!d' $i | cut -d ' ' -f-2 | tr '\n' '\t')'\n'; done) | sort -k2
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.30 2016-08-12 13:09:30,297 2016-08-12 13:53:27,785
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.29 2016-08-12 13:53:27,791 2016-08-12 16:02:24,046
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.28 2016-08-12 16:02:24,051 2016-08-12 16:13:18,553
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.27 2016-08-12 16:13:18,555 2016-08-12 16:40:21,115
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.26 2016-08-12 16:40:21,123 2016-08-12 17:26:27,145
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.25 2016-08-12 17:26:27,153 2016-08-12 17:27:35,976
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.24 2016-08-12 17:27:37,404 2016-08-12 17:56:26,459
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.23 2016-08-12 17:56:26,463 2016-08-12 18:25:09,816
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.22 2016-08-12 18:25:09,822 2016-08-12 19:10:34,036
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.21 2016-08-12 19:10:34,081 2016-08-12 19:44:30,899
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.20 2016-08-12 19:44:30,996 2016-08-12 20:01:21,222
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.19 2016-08-12 20:01:21,363 2016-08-12 21:23:20,933
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.18 2016-08-12 21:23:21,183 2016-08-12 23:14:29,238
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.17 2016-08-12 23:14:29,429 2016-08-13 00:47:05,370
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.16 2016-08-13 00:47:05,376 2016-08-13 01:01:45,803
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.15 2016-08-13 01:01:45,808 2016-08-13 02:23:24,499
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.14 2016-08-13 02:23:24,499 2016-08-13 09:41:18,893
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.13 2016-08-13 09:41:18,898 2016-08-13 11:05:50,145
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.12 2016-08-13 11:05:50,149 2016-08-13 11:58:56,914
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.11 2016-08-13 11:58:56,919 2016-08-13 13:58:17,794
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.10 2016-08-13 13:58:17,800 2016-08-13 15:55:48,996
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.9 2016-08-13 15:55:49,001 2016-08-13 17:05:04,935
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.8 2016-08-13 17:05:04,939 2016-08-13 17:58:42,547
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.7 2016-08-13 17:58:42,552 2016-08-13 18:13:34,622
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.6 2016-08-13 18:13:34,627 2016-08-13 19:41:18,039
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.5 2016-08-13 19:41:18,045 2016-08-13 21:13:34,207
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.4 2016-08-13 21:13:34,209 2016-08-13 23:13:13,734
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.3 2016-08-13 23:13:13,737 2016-08-14 00:04:13,013
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.2 2016-08-14 00:04:13,017 2016-08-14 00:58:07,933
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out.1 2016-08-14 00:58:07,937 2016-08-14 01:43:06,945
    hadoop-cmf-hdfs2-NAMENODE-namenode01.company.com.log.out 2016-08-14 01:43:07,107 2016-08-14 01:56:02,070

    Thursday, May 19, 2016

    Mac OSX (El Capitan) Software Update tool via CLI


    List available software updates via CLI (but don't install them):

    $ sudo softwareupdate -l
    Software Update Tool
    Copyright 2002-2015 Apple Inc.

    Finding available software
    Software Update found the following new or updated software:
       * OS X El Capitan Update-10.11.5
    OS X El Capitan Update (10.11.5), 740450K [recommended] [restart]
       * RAWCameraUpdate6.19-6.19
    Digital Camera RAW Compatibility Update (6.19), 7575K [recommended]
       * iTunesXPatch-12.4
    iTunes (12.4), 144804K [recommended]



    Install all pending software updates via CLI:

    $ sudo softwareupdate -i -a
    Software Update Tool
    Copyright 2002-2015 Apple Inc.

    Finding available software

    Downloading OS X El Capitan Update
    Downloading Digital Camera RAW Compatibility Update
    Downloading iTunes
    Downloaded Digital Camera RAW Compatibility Update
    Downloaded iTunes
    Downloaded OS X El Capitan Update
    Installing OS X El Capitan Update, Digital Camera RAW Compatibility Update, iTunes
    Done with OS X El Capitan Update
    Done with Digital Camera RAW Compatibility Update
    Done with iTunes
    Done.

    You have installed one or more updates that requires that you restart your

    computer.  Please restart immediately.