Posts

Showing posts from February, 2021

Port 27017 is the default port for Amazon #DocumentDB.

Get Windows version

winver

Microsoft #Edge kiosk mode offers two lockdown experiences of the browser so organizations can create, manage, and provide the best experience for their customers.

The following 2 lockdown experiences are available: Digital/Interactive Signage experience - Displays a specific site in full-screen mode. Public-Browsing experience - Runs a limited multi-tab version of Microsoft Edge. Both experiences are running a Microsoft Edge InPrivate session, which protects user data.

Install Microsoft Edge in #Linux

https://www.microsoftedgeinsider.com/en-us/download/?platform=linux-deb

VSCode installer script

#Windows Sandbox is based on Hyper-V technology and allows you to spin up an isolated, temporary, desktop environment where you can run untrusted software.

Starting with Windows 10 build 18305, Microsoft introduced Windows Sandbox.

Windows Sandbox is a new lightweight desktop environment tailored for safely running applications in isolation.

Amazon Neptune supports open graph APIs for both Gremlin and SPARQL, and provides high performance for both of these graph models and their query languages.

Amazon Neptune lets you choose the Property Graph model and its open source query language, Apache TinkerPop Gremlin or the W3C standard Resource Description Framework (RDF) model and its standard query language, SPARQL. 

DynamoDB is a Document style database.

DynamoDB has the capability to scale depending upon the size of data.

Improve #MySQL delete performance

mysql > SET session transaction isolation level READ COMMITTED; Query OK, 0 rows affected Time: 0.001s mysql > SET session autocommit=1; Query OK, 0 rows affected Time: 0.001s mysql >

MySQL TRANSACTION ISOLATION LEVEL Example

mysql > SET TRANSACTION ISOLATION LEVEL READ COMMITTED; Query OK, 0 rows affected Time: 0.001s mysql > SET TRANSACTION ISOLATION LEVEL SERIALIZABLE; Query OK, 0 rows affected Time: 0.001s mysql > SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED; Query OK, 0 rows affected Time: 0.001s mysql > SET TRANSACTION ISOLATION LEVEL REPEATABLE READ; Query OK, 0 rows affected Time: 0.001s mysql >

The default isolation level for #InnoDB is REPEATABLE READ.

A #MySQL user can change the isolation level for a single session or for all subsequent connections with the SET TRANSACTION statement.

The default isolation level in #MySQL is REPEATABLE READ

Coinbase is a digital currency exchange headquartered in San Francisco, California, United States.

They broker exchanges of Bitcoin, Bitcoin Cash, Ethereum, Ethereum Classic, Litecoin, Tezos, and many other cryptocurrencies, with fiat currencies in approximately 32 countries, and bitcoin transactions and storage in 190 countries worldwide.

FTC Names Two Additional Defendants in Its Case Against Zurixx Real Estate Investment Training Scheme

The Federal Trade Commission and the Utah Division of Consumer Protection have named two additional defendants in their case against the operators of the Zurixx real estate investment training scheme. The FTC and the Division allege that Zurixx used deceptive promises of big profits in live sales events and telemarketing to lure consumers into spending thousands of dollars on Zurixx’s products and services. The second amended complaint adds Utah-based CAC Investment Ventures, LLC as a defendant in the case, and Stephenie Spangler as a relief defendant, meaning that she is not accused of wrongdoing but allegedly received funds that Zurixx illegally obtained from consumers. The FTC and the Division sued Zurixx in October 2019 and first amended their complaint in May 2020. The Court has issued a stipulated preliminary injunction against defendants. The receiver in the case has created a website with information for consumers who may have been affected at www.zurixx.com . Consume...

Purpose Investment’s bitcoin (BTC, +3.97%) ETF officially started trading on the Toronto Stock Exchange (TSX) under the ticker “BTCC” on Thursday.

Tmux Quick Reference

  Sessions Start a new session tmux tmux new tmux new-session :new Start a new session with the name goyun tmux new -s goyun new -s goyun kill/delete session goyun tmux kill-ses -t goyun tmux kill-session -t goyun kill/delete all sessions but the current tmux kill-session -a kill/delete all sessions but goyun tmux kill-session -a -t goyun Rename session Ctrl + b $ Detach from session Ctrl + b d Detach others on the session (Maximize window by detach other clients) attach -d Show all sessions tmux ls tmux list-sessions Ctrl + b s Attach to last session tmux a tmux at tmux attach tmux attach-session Attach to a session with the name goyun tmux a -t goyun tmux at -t goyun tmux attach -t goyun tmux attach-session -t goyun Move to previous session Ctrl + b ( Move to next session Ctrl + b ) Windows start a new session with the name goyun and window nextruby tmux new -s goyun -n nextruby Create window Ctrl + b c Rename current window Ctrl + b , Close current window Ctrl + b & Previous...

#Ethereum is the community-run technology powering the cryptocurrency, ether (ETH) and thousands of decentralized applications.

Execute cmd file Using Command Prompt

Example: Shell > start goyun.info.cmd

Fixed Centos mailx sending body as attachment

Remove those ' \r' by sed: Example:  ssh -t server.goyun.info 'df -h /; df -h /home' | sed "s/\r//g" | mailx -s "disk dize info" devops@goyun.info

sed with pipe in #Linux command example

 ssh -t server.goyun.info 'df -h /; df -h /home' | sed "s/\r//g" | mailx -s "disk dize info" devops@goyun.info

MSTSC Creates connections to Remote Desktop Session Host servers or other remote computers

Syntax mstsc.exe [<connectionfile>] [/v:<server>[:<port>]] [/admin] [/f] [/w:<width> /h:<height>] [/public] [/span] mstsc.exe /edit <connectionfile> mstsc.exe /migrate Parameters Parameters Parameter Description <connectionfile> Specifies the name of an .rdp file for the connection. /v: <server>[:<port>] Specifies the remote computer and, optionally, the port number to which you want to connect. /admin Connects you to a session for administering the server. /f Starts Remote Desktop Connection in full-screen mode. /w: <width> Specifies the width of the Remote Desktop window. /h: <height> Specifies the height of the Remote Desktop window. /public Runs Remote Desktop in public mode. In public mode, passwords and bitmaps aren't cached. /span Matches the Remote Desktop width and height with the local virtual desktop, spanning across multiple monitors if necessary. /edit  <connectionfile> Opens the specified .rdp fil...

Remote Desktop (RDP) Keyboard Shortcuts in Windows 10

Regular Windows keyboard combination Key combination for RDP Description of what hotkeys do Win key or Ctrl+Esc Alt+Home Opens the Start Menu or Start screen Alt+Tab Alt+Page Up Displays the Alt+Tab switcher where pressing Page Up while Alt is held down will switch programs from left to right Alt+Shift+Tab Alt+Page Down Displays the Alt+Tab switcher where pressing Page Down while Alt is held down will switch programs from right to left Alt+Esc Alt+Insert Cycles through open apps in most recently used order ( sends the current active window to the bottom of the Z-order ) Alt+Space Alt+Delete Opens the window menu of the active window Print Screen Ctrl+Alt+'+'(Plus key on numeric keypad) Takes a screenshot of the whole screen to the clipboard which you can paste in Paint Alt+Print Screen Ctrl+Alt+'-' (Minus key on the numeric keypad) Takes a screenshot of the active window to the clipboard which you can paste in Paint Ctrl+Alt+Del Ctrl+Alt+End Sends Ctrl+Alt+Del (Secure A...

#cisgender

denoting or relating to a person whose sense of personal identity and gender corresponds with their birth sex.

FTC to Hold Virtual Workshop Exploring Digital “Dark Patterns”

The Federal Trade Commission will host a virtual workshop on April 29, 2021 to examine digital “dark patterns,” a term that has been used to describe a range of potentially manipulative user interface designs used on websites and mobile apps. “Bringing Dark Patterns to Light: An FTC Workshop” will explore the ways in which user interfaces can have the effect, intentionally or unintentionally, of obscuring, subverting, or impairing consumer autonomy, decision-making, or choice. For example, some sites sneak extra items into a consumer’s online shopping cart, or require users to navigate a maze of screens and confusing questions to avoid being charged for unwanted products or services. The FTC workshop will bring together researchers, legal experts, consumer advocates, and industry professionals to examine what dark patterns are and how they might affect consumers and the marketplace. Some of the topics the workshop will examine include: how dark patterns differ from sales tactic...

Start browsers in private mode from command line on Windows

start  msedge www.bing.com -inprivate start  firefox -private chrome -incognito

Start Microsoft Edge in private mode from command line

start  msedge www.bing.com -inprivate

Switch from WSL back to CMD or PowerShell

From within wsl, run cmd.exe or powershell.exe goyun.info@DESKTOP-goyun.info:/mnt/c/Users/goyun.info$ powershell.exe Windows PowerShell Copyright (C) Microsoft Corporation. All rights reserved. Try the new cross-platform PowerShell https://aka.ms/pscore6 PS C:\Users\goyun.info> wsl * keychain 2.8.5 ~ http://www.funtoo.org * Found existing ssh-agent: 145 * Known ssh key: /home/goyun.info/.ssh/id_rsa goyun.info@DESKTOP-goyun.info:/mnt/c/Users/goyun.info$ cmd.exe Microsoft Windows [Version 10.0.19042.804] (c) 2020 Microsoft Corporation. All rights reserved. C:\Users\goyun.info>

The config file for mycli is located in the home folder (~/.myclirc)

Display Options from Option Files using my_print_defaults

my_print_defaults displays the options that are present in option groups of option files.  The output indicates what options are used by programs that read the specified option groups. bit@goyun.info:~$ my_print_defaults mysql client --auto-vertical-output --auto-rehash --compress --protocol=TCP --user=goyuninfo bit@goyun.info:~$ mysql --print-defaults mysql would have been started with the following arguments: --auto-vertical-output --auto-rehash --compress --protocol=TCP --user=goyuninfo

Exit existing SSH #ControlMaster and reconnect

bit@goyun.info:/tmp $ ssh -O check u.goyun.info Master running (pid=2252) bit@goyun.info:/tmp $ ssh -O exit u.goyun.info Exit request sent. bit@goyun.info:/tmp $ ssh u.goyun.info

Fixed gpg: There is no assurance this key belongs to the named user

gpg --edit-key <KEY_ID> gpg> trust 1 = I don't know or won't say 2 = I do NOT trust 3 = I trust marginally 4 = I trust fully 5 = I trust ultimately m = back to the main menu Choose 5. gpg> quit

Changing Private Key Passphrase

If you ever need to change your private key passphrase, you can do so with this command: ssh-keygen -f ~/.ssh/id_rsa -p Enter your old passphrase and then enter a new passphrase.

Lock (Disable) User Account on Linux

Passwd command can be used to lock or disable a user account. To lock: # passwd openvpn –l Above command changes the shadow file and adds “!” in front of the user password To unlock # passwd openvpn -u You can also enable account by removing manually the “!” character from the user’s password line in /etc/shadow. bit@goyun.info : ~ $ sudo passwd openvpn -l passwd: password expiry information changed. bit@goyun.info : ~ $ sudo grep openvpn /etc/shadow openvpn:!$6$PotCU3QmMD7JsvbS$cAM5Ti0pcPxgFXw87hwCGJqUWXPhN10eD8SMrRXMu/kUKJAh5sgHcTgSPAGUjeGd1HgmwRB4xDekGASyOBpVj0:18681:0:99999:7::: nm-openvpn:*:18530:0:99999:7::: openvpn_as:!:18673:0:99999:7::: bit@goyun.info : ~ $ sudo passwd openvpn -u passwd: password expiry information changed. bitcoin@goyun.info : ~ $ sudo grep openvpn /etc/shadow openvpn:$6$PotCU3QmMD7JsvbS$cAM5Ti0pcPxgFXw87hwCGJqUWXPhN10eD8SMrRXMu/kUKJAh5sgHcTgSPAGUjeGd1HgmwRB4xDekGASyOBpVj0:18681:0:99999:7::: nm-openvpn:*:18530:0:99999:7::: openvpn_as:!:18673:0:99999:7:::...

Get size of BLOB in MySQL

  SELECT OCTET_LENGTH(blob_content) FROM blob_table WHERE id = 88 ;

Install xfce on WSL2 Ubuntu

It is currently works with the remote desktop app mstsc.exe, not the rdp app from Microsoft Store.

Enable hibernate in windows 10

Run Command Prompt or PowerShell as an administrator: powercfg /hibernate on You can verify it is now available: powercfg /availablesleepstates

Automatically start service on WSL on Windows:

First configure it to start the service without asking a password. Create line in /etc/sudoers.d/ (at WSL to prevent asking password): %sudo   ALL=(ALL) NOPASSWD: /usr/sbin/service xrdp * Create .bat file in  Windows startup directory  with for example the following lines: wsl sudo service dbus start wsl sudo service xrdp start

Windows startup directory

You can find Windows startup directory by key:  Win + R  and  shell:startup

Use an ssh-agent on Ubuntu

Use keychain  package  $ sudo apt-get install keychain Then append to your ~/.bashrc /usr/bin/keychain --nogui $HOME/.ssh/id_rsa source $HOME/.keychain/$HOSTNAME-sh

my_print_defaults — Display #MySQL Options from Option Files

my_print_defaults displays the options that are present in option groups of option files. The output indicates what options are used by programs that read the specified option groups.

The #mysql_config_editor utility enables you to store authentication credentials in an obfuscated login path file named .mylogin.cnf.

The file location is the %APPDATA%\MySQL directory on Windows and the current user's home directory on non-Windows systems.

National Consumer Protection Week 2021 Begins Sunday, February 28

Image
FTC, partners to share advice on scams, identity theft, and other consumer protection issues The Federal Trade Commission and more than 100 federal, state, and local agencies, consumer groups, and national advocacy organizations, will participate in the 23 rd annual National Consumer Protection Week (NCPW) , held February 28 – March 6, 2021. NCPW is a coordinated campaign designed to focus on the importance of keeping consumers informed while providing them with free resources explaining their rights in the marketplace. This year, the FTC and its partners will participate in a series of events including webinars, Facebook Live events, and Twitter chats throughout the week. These virtual events will cover a range of topics, including avoiding coronavirus scams, government imposters, and cyber fraud. This year’s schedule of NCPW activities include: Sunday, February 28 – Saturday, March 6 Follow FTC and USAGov on social media for quick, shareable consumer tips all week long: Fac...

#ETFs offer #tax advantages to investors.

ETFs are more tax efficient than mutual funds because of the way they are created and redeemed. As passively managed portfolios, ETFs and index funds tend to realize fewer capital gains than actively managed mutual funds. 

Denormalization helps to avoid joins and improve query #performance.

An inverted index is a common secondary index design pattern with DynamoDB.

With an inverted index, you create a secondary index that is the inverse of the primary key for your table. The HASH key for your table becomes the RANGE key in your index, and the RANGE key for your table becomes the primary key for your index.

DynamoDB concepts

Table: A collection of DynamoDB data records. Item: A single data record in a DynamoDB table. It is comparable to a row in a relational database. Attribute: A single data element on an item. It is comparable to a column in a relational database. However, unlike columns in a relational database, attributes do not need to be specified at table creation, other than the primary key. Attributes can be simple types such as strings, integers, or Boolean, or they can be complex types such as lists or maps. Primary key: A primary key is a unique identifier for a single item in a DynamoDB table. The primary key name and type must be specified on table creation, and a primary key of the specified type must be included with each item written to a table. A simple primary key consists of a single attribute, and a composite primary key consists of two attributes: a partition key and a sort key. For example, you can create a simple primary key using “UserID” as an identifier, or create a composite pri...

When using #DynamoDB, it is important to consider your access patterns before you model your data.

When building an application, you should always take time to design the data models needed in your application logic. This data model design should consider data access needs that will be needed in your application, both for reading and writing data.

Using the Jar Command to Unzip Files

jar -xvf /path/to/zip/file/or/jar/file

There are only 2.5 million #bitcoin (11%) of total supply left to mine.

#Cryptocurrencies broadly have seen increased adoption from established #financial firms.

#Cryptocurrencies go mainstream

The easiest way to capture and save a picture of your entire Windows screen

If you want to capture and save a picture of your entire screen, the easiest way is to hit the Windows key + Print Screen key, and that picture will be saved to the Pictures > Screenshots folder. 

With #DynamoDB, you can create database tables that can store and retrieve any amount of data and serve any level of request traffic.

You can scale up or scale down your tables' throughput capacity without downtime or performance degradation. You can use the AWS Management Console to monitor resource utilization and performance metrics.

Helidon is an extremely versatile Java library for accessing data in #microservices.

Sample Log4j2 XML configuration for rolling file and console

<? xml version = " 1.0 " encoding = " UTF-8 " ?> < Configuration status = " DEBUG " > < Loggers > < Root level = " TRACE " > < AppenderRef ref = " RollingFileAppender " level = " INFO " /> < appender-ref ref = " Console " level = " TRACE " /> </ Root > </ Loggers > < Appenders > < Console name = " Console " target = " SYSTEM_OUT " > < PatternLayout pattern = " %d{HH:mm:ss.SSS} [%t] %highlight{%level}{FATAL=bg_red, ERROR=red, WARN=yellow, INFO=green, DEBUG=blue} - %msg%n " /> </ Console > < RollingFile name = " RollingFileAppender " fileName = " logs/goyun.info.log " filePattern = " logs/$${date:yyyy-MM}/email-%d{MM-dd-yyyy}-%i.log.zip " > < Pattern...