Skip to main content

Posts

Showing posts from February, 2018

Powershell: Copy-Item

Let's practice using Powershell cmdlet  Copy-Item [instead of copy or xcopy ] when we want to copy files and/or folders. Powershell: Copy-Item Example: Copy D:\MinnaNoNihongo folder to E:\ drive Powershell: Copy D:\MinnaNoNihongo folder to E:\ drive

You are fired unless ...

...unless "The illiterate of the 21st century will not be those who cannot read and write, but those who cannot Learn , Unlearn , and Relearn ." -  Alvin Toffler

Blessed are the peacemakers, for they shall be called sons of God

"Blessed are the peacemakers, for they shall be called sons of God." - Luke 5:9

Java: error - could not find or load main class

Java Error: Could not find or load main class Java: Common mistake of beginners

Powershell: Remove-Item

Use Remove-Item to delete files, folders, and more than that

Do to others as you would have them do to you

"Do to others as you would have them do to you." — Luke 6:31

Ubuntu: Create swap partition

A swap file allows an operating system to use hard disk space to simulate extra memory.

Do not let your left hand know what your right hand is doing

"But when you give to the needy, do not let your left hand know what your right hand is doing,   so that your giving may be in secret. Then your Father, who sees what is done in secret, will reward you." - Matthew 6:3-4

Windows: Cleanup Installer folder

Let's cleanup orphaned files in %windir%\Installer folder to reclaim space from our expensive SSD.

Ubuntu: Install bind9 - dns service

BIND - Berkeley Internet Name Domain sudo apt-get install -y bind9 dnsutils

Ask, seek, and knock

"So I say to you: Ask and it will be given to you; seek and you will find; knock and the door will be opened to you." - Luke 11:9

MongoDB: Install client on Windows 10

Download link:  https://www.mongodb.com/download-center#enterprise Mongo Shell help Run mongo shell, then run help to display commands. help Try using mongo shell to connect to 100YWeatherSmall database mongo "mongodb://cluster0-shard-00-00-jxeqq.mongodb.net:27017,cluster0-shard-00-01-jxeqq.mongodb.net:27017,cluster0-shard-00-02-jxeqq.mongodb.net:27017/100YWeatherSmall?replicaSet=Cluster0-shard-0" --authenticationDatabase admin --ssl --username m001-student --password m001-mongodb-basics

MSSQL: Change initial size for tempdb data files

/*Modify tempdev files' size [from 1024MB] to 2048MB*/ USE [master] GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev', SIZE = 2097152KB ) GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev2', SIZE = 2097152KB ) GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev3', SIZE = 2097152KB ) GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev4', SIZE = 2097152KB ) GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev5', SIZE = 2097152KB ) GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev6', SIZE = 2097152KB ) GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev7', SIZE = 2097152KB ) GO ALTER DATABASE [tempdb] MODIFY FILE ( NAME = N'tempdev8', SIZE = 2097152KB ) GO /*End of script*/

Do not judge, and you will not be judged

"Do not judge, and you will not be judged. Do not condemn, and you will not be condemned. Forgive, and you will be forgiven." - Luke 6:37

RHEL: firewall-cmd

firewall-cmd - firewall d c om m an d line client

Powershell: Test-NetConnection

PS C:\Users\tuyen> get-help Test-NetConnection NAME     Test-NetConnection SYNTAX     Test-NetConnection [[-ComputerName] <string>] [-TraceRoute] [-Hops <int>] [-InformationLevel {Quiet |     Detailed}]  [<CommonParameters>]     Test-NetConnection [[-ComputerName] <string>] [-CommonTCPPort] {HTTP | RDP | SMB | WINRM}     [-InformationLevel {Quiet | Detailed}]  [<CommonParameters>]     Test-NetConnection [[-ComputerName] <string>] -Port <int> [-InformationLevel {Quiet | Detailed}]     [<CommonParameters>]     Test-NetConnection [[-ComputerName] <string>] -DiagnoseRouting [-ConstrainSourceAddress <string>]     [-ConstrainInterface <uint32>] [-InformationLevel {Quiet | Detailed}]  [<CommonParameters>] ALIASES     TNC REMARKS     Get-Help cannot find the Help files for this cmdlet on this computer. It is displaying only partial help.         -- To download and install Help files for the m

Linux command: printenv

printenv - print all or part of environment NAME        printenv - print all or part of environment SYNOPSIS        printenv [OPTION]... [VARIABLE]... DESCRIPTION        Print  the  values  of the specified environment VARIABLE(s).  If no VARIABLE is speci‐        fied, print name and value pairs for them all.        -0, --null               end each output line with NUL, not newline        --help display this help and exit        --version               output version information and exit        NOTE: your shell may have its own version of printenv,  which  usually  supersedes  the        version  described  here.  Please refer to your shell's documentation for details about        the options it supports. AUTHOR        Written by David MacKenzie and Richard Mlynarik. REPORTING BUGS        GNU coreutils online help: <http://www.gnu.org/software/coreutils/>        Report printenv translation bugs to <http://translationproject.org/team/>

Treat people the same way you want them to treat you

"In everything, therefore, treat people the same way you want them to treat you, for this is the Law and the Prophets." - Matthew 7:12

macOS: How to capture screen

Shortcut keys to capture screen in macOS 

macOS for Beginners

Mac keyboard shortcuts By pressing a combination of keys, you can do things that normally need a mouse, trackpad, or other input device. fn + Arrow up: Page UP fn + Arrow down: Page DOWN Free Mac OS X Basics Tutorial at GCFLearnFree Whether you're using OS X Sierra, OS X El Capitan, or OS X Yosemite, you can still learn quite a bit from this free OS X Basics tutorial.