Showing posts from January, 2021

IT Swiss Tools

Using #Windows startup folder to launch scripts

Open the Run dialog with WindowsKey+R and enter shell:startup. Startup folder for user and global: %APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup %ProgramData%\Microsoft\Windows\Start Menu\Programs\StartUp

WSL starting directory on Windows Terminal

Example: { " guid " : " {07b52e3e-de2c-5db4-bd2d-ba888ed6c888} " , " hidden " : false , " name " : " Ubuntu-20.04 " , " source " : " Windows.Terminal.Wsl " , " startingDirectory " : " C: \\ Users/goyuninfo/OneDrive " }

You can launch Windows terminal in a specific configuration by using the wt.exe command.

Install cron on #Linux

Install the latest version of a module and its dependencies from the #Python Packaging Index

python -m pip install SomePackage

The #Python Package Index (PyPI) is a repository of software for the Python programming language.

PyPI helps you find and install software developed and shared by the Python community. The Python Packaging Index is a public repository of open source licensed packages made available for use by other Python users.

A #Python virtual environment is a semi-isolated Python environment that allows packages to be installed for use by a particular application, rather than being installed system wide.

Starting with #Python 3.4, pip is included by default with the Python binary installers.

A #Bash here document is a special-purpose code block.

A #Bash here document uses a form of I/O redirection to feed a command list to an interactive program or a command, such as ftp, cat, or the ex text editor. COMMAND <<InputTagHERE ... ... ... InputTagHERE

A zero return value from the script upon exit indicates success to the #Bash shell

Check if in right directory on Linux

cd $MY_DIR if [ `pwd` != "$MY_DIR" ] # or if [ "$PWD" != "$MY_DIR" ] # Not in the right directory then echo "Can't change to $MY_DIR." exit $E_XCD #E_XCD=86 fi

Only users with $UID 0 have root privileges on #Linux

Clean up a file in Bash shell

cat /dev/null > file_to_clean_up.

FTC Sends More Than $250,000 in Additional Refunds to Victims of Mortgage Modification Scheme

The Federal Trade Commission is sending a third round of checks totaling more than $250,000 to victims of a mortgage modification scheme dating back to 2009. The FTC began mailing refunds in this matter in 2012 . In total, the FTC has distributed more than $900,000. According to the FTC, First Universal Lending, LLC, Sean Zausner, David Zausner, and David J. Feingold deceived distressed homeowners with phony claims that they would negotiate with lenders to modify their mortgages. The FTC charged that the defendants encouraged homeowners to stop making mortgage payments, saying lenders would not negotiate unless they were at least a few months behind in their payments. After charging consumers up to $7,000 in up-front fees, the defendants did little or nothing to help them. The FTC is providing $253,615 in refunds to 6,935 victims. Those who receive checks should deposit or cash their checks within 60 days, as indicated on the check. The FTC never requires people to pay money or p

Enable Copy on Select in Windows Terminal

Adding the following line to the global defaults area of your settings file. "copyOnSelect": true,

Mysql workbench prerequisites Download the Microsoft Visual C++ Redistributable for Visual Studio 2015, 2017 and 2019 . The following updates are the latest supported Visual C++ redistributable packages for Visual Studio 2015, 2017 and 2019. Included is a baseline version of the Universal C Runtime see MSDN for details. x86: vc_redist.x86.exe x64: vc_redist.x64.exe ARM64: vc_redist.arm64.exe The following prerequisites are available at the Microsoft Download Center : Microsoft .NET Framework Microsoft Visual C++ Redistributable for Visual Studio

FTC Marks Identity Theft Awareness Week with Events to Help Consumers Identify Risks of Identity Theft During the COVID-19 Pandemic

The Federal Trade Commission is launching Identity Theft Awareness Week, February 1-5, 2021, with a series of events to highlight steps consumers can take to help reduce their risk of identity theft and recover if identity theft occurs. Identity theft happens when someone steals personal information about you such as your Social Security number or credit card information, and uses it to commit fraud. Reports about any type of identity theft topped the list of consumer complaints submitted to the FTC through the third quarter of 2020. As part of Identity Theft Awareness Week, the FTC will participate in webinars and other events to highlight what you can do to protect your personal information, red-flag warning signs of possible identity theft, and steps to take if identity theft happens to you. Events include a webinar on Monday, February 1, with Identity Theft Resource Center and FTC experts discussing identity theft during the pandemic, and a Facebook Live discussion on Thursda

Get wsl version on Windows 10

> wsl -l -v   NAME            STATE           VERSION * Ubuntu-20.04    Running         1

Change the #Python default version in #Ubuntu

$ sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 1 update-alternatives: using /usr/bin/python3 to provide /usr/bin/python (python) in auto mode

The most effective way to run an alternative version of #Python is within a virtual environment (venv).

There is no reason to remove older versions of python as there may be scripts on the operating system which require their presence. 

Fixed Microsoft Edge’s Downloading Proxy Script issue

Open your computer’s proxy Settings Uncheck “Automatically detect Settings”

A #proxy or Proxy Server acts as a gateway between the Internet and the local network.

Identifying and removing unused #indexes is a best practice that should be performed on a regular basis on your #database.

#Database Transaction Best Practices

Keep transactions to the smallest number of commands needed. If you have transactions with multiple statements that can be divided up into multiple smaller transactions, it is advisable to do so to reduce the likelihood of a timeout. Always aim to create short transactions, not long-running reads. Always commit or abort the transaction after it is complete. Leaving a transaction in an incomplete state ties up database resources and can cause write conflicts.

#Database Transactions

Transactions simplify application development by enabling you to perform atomic, consistent, isolated, and durable (ACID) operations across one or more database instances within an cluster.

FTC Returns More Than $482 Million to Consumers in 2020

FTC law enforcement actions lead to refunds to more than 1.6 million consumers nationwide New data released by the Federal Trade Commission shows that FTC actions led to more than $482 million in refunds to consumers across the country in 2020. A core part of the FTC’s mission is to return money to consumers who have been harmed by fraud or other illegal business practices. More than 50 different FTC cases resulted in distributions to consumers in 2020. The FTC Act allows the FTC to seek refunds from companies whose actions harm consumers. During 2020, more than 1.6 million consumers received refunds from the FTC as a result of law enforcement cases. The FTC usually sends refunds to consumers by check, but in 2020, the agency also issued PayPal payments to consumers in 11 cases. By sending electronic payments, the FTC made it possible to get money back to people even when their physical mailing address information was not available.  When consumers don’t cash their refund chec

MongoDB show databases

Use show dbs command from mongo shell to list all the available databases on MongoDB server. This will show the database name with there size. rs0:PRIMARY> show dbs rs0:PRIMARY> 

FTC Brings First-Ever Cases Under the BOTS Act

Ticket brokers will face partially suspended judgment of more than $31 million in civil penalties The Federal Trade Commission is taking legal action against three ticket brokers based in New York who allegedly used automated software to illegally buy up tens of thousands of tickets for popular concerts and sporting events, then subsequently made millions of dollars reselling the tickets to fans at higher prices. The three ticket brokers will be subject to a judgment of more than $31 million in civil penalties for violating the Better Online Ticket Sales (BOTS) Act, under a proposed settlement reached with the FTC. Due to their inability to pay, the judgment will be partially suspended, requiring them to pay $3.7 million. This is the first case brought under the BOTS Act, which was enacted in 2016 and gives the FTC authority to take law enforcement action against individuals and companies that use bots or other means to circumvent limits on online ticket purchases. “These ticket broke

AWS cli get the current region

aws configure get region will get you the current region at that point in your script. If you are using a profile, then type aws configure get --profile $PROFILE_NAME.

At FTC’s Request, Court Finalizes Orders and Monetary Judgments against Ringleaders of the Sanctuary Belize Real Estate Investment Scheme

Andris Pukke, Peter Baker Ordered to Pay $120.2 Million A federal district court entered final orders against the three primary individual defendants—Andris Pukke, Peter Baker, and Luke Chadwick, and related corporations—in the Federal Trade Commission’s case involving the allegedly deceptive sale of real estate properties in Belize to U.S. consumers. The orders announced today finalize a September 2020 memorandum opinion requiring Pukke and Baker jointly to pay $120.2 million to the Commission—representing the amount of money consumers lost through the Sanctuary Belize real estate development scheme—with Chadwick also jointly responsible for $91.9 million of that amount. The FTC plans to use the money collected to provide refunds to defrauded consumers. The court’s final order against Pukke, Baker, and Chadwick also bans Pukke from selling or assisting others in selling most real estate, and ban all three defendants from any involvement with Sanctuary Belize or related entities in t

Always use var or let to declare #JavaScript variables.

MySQL Example Databases

sakila database TGZ | Zip View US Ltr | A4 employee data (large dataset, includes data and test/verification suite) GitHub View US Ltr | A4

Swap two MySQL table names

Make sure that a table with the intermediary name tmp_table does not already exist: RENAME TABLE old_table TO tmp_table,              new_table TO old_table,              tmp_table TO new_table;

A house is condemned when the government deems it to be unfit to live in.

No one is allowed to live in or use the property because it is a safety hazard.  If there are occupants living in the house at the time it is condemned, they will need to move and cannot return unless necessary renovations are made to the house to address the reasons it was condemned.

FTC Publishes Annual Performance Report

The Federal Trade Commission published its Fiscal Year 2020 Performance Report as required under the Government Performance and Results Modernization Act of 2010. The report documents the progress made by the Commission in achieving the mission and performance goals established in the Fiscal Year 2020-2021 Performance Plan. Also, as required by the Government Performance and Results Modernization Act during a transition in administration, the Commission will submit its Fiscal 2021-2022 Performance Plan along with its Fiscal Year 2022 budget request in support of the President’s FY 2022 budget for the federal government later this year. The Commission vote to submit the Performance Report  to Congress was 5-0 The Federal Trade Commission works to promote competition , and protect and educate consumers . You can  learn more about consumer topics  and report scams, fraud, and bad business practices online at . Like the FTC on Facebook , follow us on Twitter , read o

#EAT in #SEO stands for Expertise, Authoritativeness, and Trustworthiness.

EAT has an important role in determining where your business website to be placed on the Google result page.

Simhash is useful #hash function when you want to check for similar items.

Dijkstra’s algorithm is used to calculate the shortest path for a weighted #graph.

Breadth-first search is used to calculate the shortest path for an unweighted #graph.

You can’t use negative-weight edges with Dijkstra’s #algorithm.

FTC Comment to Department of Veterans Affairs Supports Agency’s Interim Final Rule on VA Professionals’ Authority to Practice Health Care

The Federal Trade Commission staff has submitted a comment to the Department of Veterans Affairs (VA)  in response to its request for comment on its Interim Final Rule titled Authority of VA Professionals to Practice Health Care . The comment supports the Rule, which confirms the VA’s current practice of allowing licensed VA health care professionals to deliver health care services in a state other than the health care professional’s state of licensure, and also confirms the VA’s authority to establish national standards of practice for health care professionals in all VA medical facilities. As the comment explains, the COVID-19 public health emergency, for which the VA has had to rapidly deploy licensed health care professionals to locations where they may not be licensed, has highlighted the need for this regulatory preemption. By improving access to care, avoiding delays in care, and potentially improving outcomes, the Rule benefits veterans, especially those at underserved locati

Developer of Popular Women’s Fertility-Tracking App Settles FTC Allegations that It Misled Consumers About the Disclosure of their Health Data

The developer of a period and fertility-tracking app used by more than 100 million consumers has settled Federal Trade Commission allegations that the company shared the health information of users with outside data analytics providers after promising that such information would be kept private. The proposed settlement  requires Flo Health, Inc. to, among other things, obtain an independent review of its privacy practices and get app users’ consent before sharing their health information.  “Apps that collect, use, and share sensitive health information can provide valuable services, but consumers need to be able to trust these apps,” said Andrew Smith, Director of the FTC’s Bureau of Consumer Protection. “We are looking closely at whether developers of health apps are keeping their promises and handling sensitive health information responsibly.” In its complaint , the FTC alleges that Flo promised to keep users’ health data private and only use it to provide the app’s services t

Listing Stored Procedures from Databases in the MySQL Server

To show all stored procedures of a particular database, you use the following query:  SELECT routine_name FROM information_schema.routines WHERE routine_type = 'PROCEDURE' AND routine_schema = '<database_name>'; 

Fedora official EPEL repository

For the open EPEL repository, run the commands: sudo dnf install Accept installation when prompted.

Enable the EPEL Repository on Oracle Linux 8

sudo vim /etc/yum.repos.d/ol8-epel.repo  Paste the contents below into the file. [ol8_developer_EPEL] name= Oracle Linux $releasever EPEL ($basearch) baseurl=$basearch/ gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle gpgcheck=1 enabled=1

California Company Settles FTC Allegations It Deceived Consumers about use of Facial Recognition in Photo Storage App

A California-based developer of a photo app has settled Federal Trade Commission allegations that it deceived consumers about its use of facial recognition technology and its retention of the photos and videos of users who deactivated their accounts.  As part of the proposed  settlement , Everalbum, Inc. must obtain consumers’ express consent before using facial recognition technology on their photos and videos. The proposed order also requires the company to delete models and algorithms it developed by using the photos and videos uploaded by its users. “Using facial recognition, companies can turn photos of your loved ones into sensitive biometric data,” Andrew Smith, Director of the FTC’s Bureau of Consumer Protection, said. “Ensuring that companies keep their promises to customers about how they use and handle biometric data will continue to be a high priority for the FTC.” Everalbum offered an app called “Ever” that allowed users to upload photos and videos from their mobile devic

Don’t Wear the Same #Mask All Day

If you go out in public multiple times a day with a stop at home in between, it's a good idea to be safe and change masks for each trip. 

Calgary pastor says church will continue to break #COVID-19 restrictions

MySQL benchmark

SELECT benchmark(50000000,(1234*5678/37485-1298+8596^2)); #should take less than 20 seconds mysql> SELECT benchmark(50000000,(1234*5678/37485-1298+8596^2)); +---------------------------------------------------+ | benchmark(50000000,(1234*5678/37485-1298+8596^2)) | +---------------------------------------------------+ | 0 | +---------------------------------------------------+ 1 row in set (13.11 sec)

Configuration to Log all MySQL dead locks

SET GLOBAL innodb_print_all_deadlocks = 'ON'; The option is dynamic, and can be enabled without a service restart.   If you want to make it persistent after a service restart, you may want to add it to the my.cnf file as: [mysqld] ... ... innodb_print_all_deadlocks = 1

How to get Active Transactions and Dead Locks from MySQL

To get a list of active transactions and locks that are currently executing against our target database Simply use: SELECT waiting_trx_id, waiting_pid, waiting_query, blocking_trx_id, blocking_pid, blocking_query FROM sys . innodb_lock_waits ; If a NULL value is reported for the blocking query, see Identifying a Blocking Query After the Issuing Session Becomes Idle .  For MySQL 8, use  performance_schema SELECT r . trx_id waiting_trx_id, r . trx_mysql_thread_id waiting_thread, r . trx_query waiting_query, b . trx_id blocking_trx_id, b . trx_mysql_thread_id blocking_thread, b . trx_query blocking_query FROM performance_schema . data_lock_waits w INNER JOIN information_schema . innodb_trx b ON b . trx_id = w . blocking_engine_transaction_id INNER JOIN information_schema . innodb_trx r ON r . trx_id = w . requesting_engine_transaction_id ; MySQL captures transaction and lock information in the INNODB_TRX, INNODB_LOCKS, and IN