Author:
erics, Posted on Friday, February 26th, 2021 at 11:46:15am
On MacOSX 10.10.5 Yosemite, I was having trouble with Spotlight preventing the clean eject of an attached hard drive.
Using the fuser
command allowed me to see that it what the Spotlight-specific mds
process preventing the eject.
|
fuser -u /Volumes/Archive03 |
At first, I tried to disable the indexing via the mdutil
command, but that just gave me an error:
|
shell> sudo mdutil -Ei off /Volumes/Archive03 /Volumes/Archive03: Error: unable to perform operation. (-400) Error: unknown indexing state. |
I ended up having to force eject the drive:
|
shell> diskutil unmountDisk force /Volumes/Archive03 |
The actual solution was so very simple, just create an empty file at the root of each external drive you with to prevent being indexed:
|
touch /Volumes/Archive03/.metadata_never_index |
Categories: How-To's, Technology Tags: 10.10.5, apple, Disable, diskutil, eject, Halt, howto, Index, Indexing, Mac, MacOS, macosx, mdutil, metadata_never_index, Prevent, Spotlight, Stop, tips, Touch, umountDisk, Yosemite |
No comments
Author:
erics, Posted on Friday, February 19th, 2021 at 3:18:00pm
Create two template files in the wp-content/themes/{themeName}/ subdirectory:
|
page_blog.php page_blog_plus_content.php |
page_blog.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
<?php /* WARNING: This file is part of the core Genesis framework. DO NOT edit this file under any circumstances. Please do all modifications in the form of a child theme. */ /** * Template Name: Blog * This file handles blog post listings within a page. * * This file is a core Genesis file and should not be edited. * * @category Genesis * @package Templates * @author StudioPress * @license http://www.opensource.org/licenses/gpl-license.php GPL v2.0 (or later) * @link http://www.studiopress.com/themes/genesis */ genesis(); |
page_blog_plus_content.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
|
<?php /* WARNING: This file is part of the core Genesis framework. DO NOT edit this file under any circumstances. Please do all modifications in the form of a child theme. */ /** * Template Name: Blog Plus Content * This file handles blog post listings within a page. * * This file is a core Genesis file and should not be edited. * * @category Genesis * @package Templates * @author StudioPress * @license http://www.opensource.org/licenses/gpl-license.php GPL v2.0 (or later) * @link http://www.studiopress.com/themes/genesis */ // to see the page title and page content, uncomment this: add_action('genesis_loop', 'genesis_standard_loop' ,5); genesis(); |
Categories: How-To's, Technology Tags: Blog, Blog Paage, Categories, Category, genesis, howto, page_blog, query_args, tips, WordPress |
No comments
Author:
erics, Posted on Friday, February 19th, 2021 at 9:58:50am
|
# df -hT Filesystem Type Size Used Avail Use% Mounted on /dev/nvme0n1p1 xfs 20G 2.8G 18G 14% / # lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT nvme0n1 259:0 0 40G 0 disk ├─nvme0n1p1 259:1 0 20G 0 part / └─nvme0n1p128 259:2 0 1M 0 part |
Note how the partition at 259:1 is only 20GB, while the entire disk at 259:0 is 40GB. A partition resize is required in this case.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
# sudo growpart /dev/nvme0n1 1 CHANGED: partition=1 start=4096 old: size=41938911 end=41943007 new: size=83881951 end=83886047 # lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT nvme0n1 259:0 0 40G 0 disk ├─nvme0n1p1 259:1 0 40G 0 part / └─nvme0n1p128 259:2 0 1M 0 part # df -hT Filesystem Type Size Used Avail Use% Mounted on /dev/nvme0n1p1 xfs 20G 2.8G 18G 14% / # sudo xfs_growfs -d / meta-data=/dev/nvme0n1p1 isize=512 agcount=11, agsize=524159 blks = sectsz=512 attr=2, projid32bit=1 = crc=1 finobt=1 spinodes=0 data = bsize=4096 blocks=5242363, imaxpct=25 = sunit=0 swidth=0 blks naming =version 2 bsize=4096 ascii-ci=0 ftype=1 log =internal bsize=4096 blocks=2560, version=2 = sectsz=512 sunit=0 blks, lazy-count=1 realtime =none extsz=4096 blocks=0, rtextents=0 data blocks changed from 5242363 to 10485243 # df -hT /dev/nvme0n1p1 xfs 40G 2.8G 38G 7% / |
For more information, please visit the AMW Docs: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/recognize-expanded-volume-linux.html
Categories: How-To's, Technology Tags: Amazon, Amazon Linux 2, AWS, df, df -hT, Disk, EBS, Expand, Filesystem, Grow, howto, Linux, Linux2, lsblk, NVMe, partition, Resize, tips, volume, XFS |
No comments
Author:
erics, Posted on Monday, February 15th, 2021 at 11:43:31am
First, get the container ID using docker ps
:
|
shell> docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 3bcc0baffd68 dashboard:1.0.10-88 "docker-php-entrypoi…" 29 minutes ago Up 29 minutes 0.0.0.0:8080->80/tcp dashboard |
Now run docker exec -it {ContainerID} /bin/bash
:
|
shell> docker exec -it 3bcc0baffd68 /bin/bash root@3bcc0baffd68:/var/www/html# exit |
You can make a simple shell script to ease typing a bit:
|
shell> cat dshell #!/bin/sh # dshell # usage: dshell ContainerID docker exec -it $* /bin/bash |
Categories: How-To's, Technology Tags: Container, Docker, docker exec, docker ps, Exec, howto, login, ps, Shell, tips |
No comments
Author:
erics, Posted on Thursday, February 11th, 2021 at 8:36:14am
## to add a single backslash in front of whatever char was matched
|
my $password = q#abc'A1r%Fgt&jh[-#; $password =~ s/(['])/\\$1/g; print qq#'$password'\n#; 'abc\'A1r%Fgt&jh[-' |
## to double whatever char was matched
|
my $password = q#abc'A1r%Fgt&jh[-#; $password =~ s/(['])/$1$1/g; print qq#'$password'\n#; 'abc''A1r%Fgt&jh[-' |
## to convert ‘ to ‘\” for shell execution
|
my $password = q#abc'A1r%Fgt&jh[-#; $passwordShell =~ s/(['])/$1\\$1$1/g; print qq#'$password'\n#; 'abc'\''A1r%Fgt&jh[-' |
Categories: How-To's, Technology Tags: Backslash, Characters, double, double quotes, Escape, howto, perl, quote, quotes, Replace, Single, single quotes, Speci, Special, Special character, Substitute, tips |
No comments
Author:
erics, Posted on Monday, February 8th, 2021 at 12:36:33pm
Test Renewal of a Single Domain
|
certbot renew --cert-name yourdomain.com --dry-run |
Execute Renewal of a Single Domain
|
certbot renew --cert-name yourdomain.com |
Categories: How-To's, Technology Tags: cert-name, Certbot, certbot renew, dry-run, howto, LetsEncrypt, Renew, Renewal, tips |
No comments
Author:
erics, Posted on Tuesday, January 5th, 2021 at 10:22:03pm

Judith Diane Stone
It is with deep and profound sorrow that we announce the sudden and tragic passing of Judith (Resnick) Stone, long time resident of Lynbrook, NY most recently of Monroe, NY, on January 5, 2021.
She is survived by her beloved husband and childhood sweetheart of more than 62 years, Richard, her son Eric and daughter-in-law Naomi, her son Scott and daughter-in-law Deana, her cat DJ and a large circle of extended family and friends. She is remembered by all as always smiling and for her genuine and infectious laugh.
With her husband Richard, they owned and operated Dry Cleaning Plus, a leader in dry cleaning industry consulting and business matchmaking on the East Coast since 1989. She served as a leading industry consultant for more than 20 years and developed a unique assessment tool that determined the value of a dry cleaning business. Judith wrote a number of articles for various industry publications. Prior to that she was co-owner with her husband of Superior Valet Dry Cleaners of Lynbrook, NY where she developed a custom delivery service for an elite clientele. She was General Manager for nine years of Island Cleaners in Williston Park, NY. A specialist in wedding gown restoration, she founded a wedding gown rental business, Island Bridal Gown Rentals in Hicksville, NY. Judith was beloved throughout the Dry Cleaning industry all over the country. She also served as President of the Top of the Harbour Co-op board in Oyster Bay, NY and Secretary of the residential board of Windridge III Condominium in Monroe, NY.
Judith worked tirelessly for the good of humankind, always seeing and seeking the best in everyone and everything. In ways large and small, she continually tried to better every situation she encountered with endless goodwill and concern. Judy was a dedicated volunteer to the numerous charities that were dear to her heart.
She was a devoted mother, ever available to listen and genuinely interested in her sons’ well being. These traits carried over into all her personal relationships and friendships, especially with her extended family across the country. She was much loved by all, but most of all by her husband and sons.
She will be dearly missed! A celebration of life will be planned for later in the year.
Cards and stories of remembrance are welcome to be sent to 421 Heritage Lane, Monroe, NY 10950.
If you wish to honor Judith’s memory with an act of charity, we ask that you make a donation to your preferred local food pantry or animal shelter. Plans are underway to create a scholarship for the dry cleaning industry in Judith’s name to ensure her legacy of good works continues.

Judy and Lucy
Categories: Family Tags: death, Rip |
No comments
Author:
erics, Posted on Tuesday, January 5th, 2021 at 10:00:06am
|
global $wp; $slug_missing_outside_slashes = add_query_arg( array(), $wp->request ); $current_url = home_url( $slug_missing_outside_slashes ); $form_action = '/' . $slug_missing_outside_slashes . '/'; |
https://codex.wordpress.org/Determining_Plugin_and_Content_Directories
Categories: How-To's, Technology Tags: Current, howto, Page, Path, Slug, tips, URI, URL, WordPress |
No comments
Author:
erics, Posted on Saturday, December 5th, 2020 at 9:27:54am
|
S.example.doTask({task:'getdata',step:2}); var S = {}; S.example.doTask = function({task = '',step = 0} = {}) { alert('Task: '+task+', 'Step: '+step); } |
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Destructuring_assignment
Categories: How-To's, Technology Tags: Arg, Argument, howto, JavaSvript, JS, Named parameter, param, Parameter, tips |
No comments
Author:
erics, Posted on Thursday, December 3rd, 2020 at 9:44:09am
Problem
While running the aws
cli command from a Perl async command inside apid, I go the following error:
|
IOError: [Errno 10] No child processes |
Solution
The issue turned out to be a bug in Python2.7, so I upgraded to Python3.4, then uninstalled and re-installed the aws cli software so that it used the proper Python34 version.
Procedure
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
|
sudo -i cd ## Upgrade Python yum install python34 alternatives --config python ## "Uninstall" old aws cli mv /opt/aws /opt/aws.fcs cd /usr/bin/ mv aws aws.fcs mv aws_completer aws_completer.fcs ## Install new aws cli curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" unzip awscliv2.zip ./aws/install -i /opt/aws -b /usr/bin /usr/bin/aws --version |
https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2-linux.html
https://metacpan.org/pod/distribution/WWW-REST-Apid/bin/apid
Categories: How-To's, Technology Tags: alternatives, API, apid, AWS, aws cli, AWS Linux, Broken, cli, Cloudformation, Command, Curl, Error, Exec, Execute, howto, IOError, Linux, No child processes, perl, Python, Python27, Python34, tips, Yum |
No comments