Skip to main content
  • Download Google Drive files with WGET

    Publish Date: April 21st, 2018 | Posted in Advanced LAMP Techniques, Ubuntu Linux | Last Updated

    Overview: How to Download Google Drive Files from the Linux Command Line If you need to update Claymore remotely (i.e., there is no physical access to your mining rig’s USB ports), the following options allow you to download Google Drive files via the command line in 1 line of code. Note: These scenarios work on […]

  • Multicolored Grep

    Publish Date: September 27th, 2015 | Posted in Ubuntu Linux | Last Updated

    GREP_COLORS and How to Change the Color of Grep Output Note: You may use either double or single quotes. Choose your favorite and stick with it for consistency. We decided to use double and single in these examples for illustrative purposes. Scenario 1 – Access Logs: Which IPs accessed my WordPress plugins directory on Sep […]

  • Monitor Log Files in Real-time

    Publish Date: September 23rd, 2015 | Posted in Ubuntu Linux | Last Updated

    Monitor Logs Files in Real-time By default the tail command displays the last n=10 lines of any file[1]. Hence, this can be used to monitor any log file (e.g, Apache, MySQL, error logs, etc). The FreeBSD Tail man page has the most robust explanation on usage. Here’s the basic format: $ tail -f /path_to_log/file.log Where: […]

  • Creating Aliases Using Bash

    Publish Date: September 22nd, 2015 | Posted in Advanced LAMP Techniques, Ubuntu Linux | Last Updated

    How to Create Command Line Aliases in Linux This nifty tip was provided by Maco on StackEchange’s AskUbuntu forum: $ sudo nano ~/.bash_aliases Now, add the following line to the file: alias grep=’grep -n –color=always’ Additional Notes There is an include directive in ~/.bashrc that loads ~/.bash_aliases if it exists Shell settings go into ~/.bashrc. […]

  • Grep: Searching for Keywords in a File

    Publish Date: August 28th, 2015 | Posted in Ubuntu Linux | Last Updated

    Grep: Find Which Files Contain a Keyword Use the grep command to search within files for a keyword grep -Ri my_keyword /directory/to_search/ grep “Aug 28 .*2015” /directory/to_search/file_to_search.log |more Where: Reference: Search for Apache’s ServerTokens Directive Grep for text With Wildcard in between

  • Removing Entries from Linux History

    Publish Date: September 25th, 2014 | Posted in Ubuntu Linux | Last Updated

    Removing Entries from the Linux Command Line History File First you can avoid have commands saved to the history file by preceding them with a leading space. Here’s an example: $ nano /path/to/my/file/passwords.txt ^– additional space character If there are pre-existing commands that you want removed, just open the history file in nano and delete […]