Showing posts from August, 2019

Digital Marketing

Stop and Start NFS and Related Services

Using restart option (i.e. service nfs restart) may crash / freeze your Linux computer if executed. Stop NFS server:   # service nfslock stop # service nfs stop # service portmap stop # umount /proc/fs/nfsd Start service in following order: # service portmap start # service nfs start # service nfslock start # mount -t nfsd nfsd /proc/fs/nfsd

Setting JDK in Eclipse

The list of available compilers are in the Window -> Preferences -> Java -> Installed JRE's tab.

Lambda is a fully managed compute service

Lambda is a fully managed compute service that runs your code in response to events generated by custom code or from various AWS services such as Amazon S3, DynamoDB, Kinesis, Amazon SNS, and Amazon Cognito.

The AWS SAM CLI is a separate command line tool that you can use to manage and test AWS SAM applications.

In addition to commands for uploading artifacts and launching AWS CloudFormation stacks that are also available in the AWS CLI, the SAM CLI provides additional commands for validating templates and running applications locally in a Docker container.

How to suspend and resume Linux processes

You can use kill to stop the process. For a 'polite' stop to the process (prefer this for normal use), send SIGTSTP: kill -TSTP [pid] For a 'hard' stop, send SIGSTOP: kill -STOP [pid] Note that if the process you are trying to stop by PID is in your shell's job table, it may remain visible there, but terminated, until the process is fg'd again. To resume execution of the process, sent SIGCONT: kill -CONT [pid]

You can use AWS CLI to add multiple FQDN in a single command while creating a new ACM certificate.

Following is the command you can use to achieve this, aws acm request-certificate --domain-name  --validation-method DNS --subject-alternative-names

A Gradle plugin that provides Maven-like dependency management functionality

A Gradle plugin that provides Maven-like dependency management functionality

Build Your Java Project with Apache Maven

Once you set up your project, you can build it using Maven's package command. mvn package This creates your .jar file in the target directory.

SQL server Express vs developer

Developer Edition supports more features and larger databases. For example, if you want to restore a 88gb database from your production server onto your workstation to do testing, you'll need Developer Edition. If you're working with Enterprise-only features like partitioning, compression or the Resource Governor. Those features aren't available in Express, but they are available in Developer Edition. And SQL Express is quite capable of handling fair loads. SQL Server Express does not require licensing but has a smaller set of features. Developing against full SQL Server (and Developer Edition matches Enterprise Edition) always leaves the chance that you rely on some feature that is not in the production edition.

By default, Postfix configuration files are in /etc/postfix.

The two most important Postfix configuration files are and; these files must be owned by root. Giving someone else write permission to or (or to their parent directories) means giving root privileges to that person.

Open source client for AnyConnect

"network-manager-openconnect-gnome" package in the Ubuntu Repository. It uses OpenConnect which is an open source client for AnyConnect. You can find the package in the Ubuntu Software Center or Synaptic by searching for "OpenConnect." If you wish to install it via the command-line, you can do so with: sudo apt install network-manager-openconnect-gnome

Run Unix commands from within Vim

:shell :sh[ell] start a shell :! :!{command} execute {command} with a shell

Create a basic Maven package

mvn -B archetype:generate \   -DarchetypeGroupId=org.apache.maven.archetypes \   -DgroupId=org.example.basicapp \   -DartifactId=myapp

Resources for preparing technical interviews

LeetCode  is a social platform for preparing IT technical interviews. It strives to provide you with the best learning experience in preparing interviews for companies in the IT industry. is to help programmers successfully prepare for technical interviews. It does this by presenting a variety of questions, grouped by subject matter. This site is a great resource for any level of programmer – whether you are an entry level “fresher” just starting out your career, or an experienced senior level programmer who is looking for more advanced questions, it presents a wide variety of real interview questions.

AWS SDK Eclipse Toolkit provides an Eclipse plugin for you to both create a deployment package and also upload it to create a Lambda function.

AWS SDK Eclipse Toolkit plugin enables you to author Java code, create and upload a deployment package, and create your Lambda function. 

Install docker on AWS EC2

 sudo amazon-linux-extras install docker

SDKMAN! is a tool for managing parallel versions of multiple Software Development Kits on most Unix-based systems.

Example: $ sdk install gradle 5.6.1

Build Anything by Gradle Build Tool

Write in Java, C++, Python or your language of choice. Package for deployment on any platform. Go monorepo or multi-repo. And rely on Gradle's unparalleled versatility to build it all.

Shell script to identify duplicate Java classes.

mkdir -p expanded unzip path/to/my/i88ca.jar -d expanded find ./expanded/lib -name ' *.jar ' | xargs -n1 zipinfo -1 | grep ' .*.class ' | sort | uniq -c | sort

Solution: Unable to locate package on Ubuntu

Updating the package index: sudo apt update Next, install Maven by typing the following command: sudo apt install maven

What version of Java is being used by Maven

mvn -version will output which java it's using. $ mvn -version Apache Maven 3.0.5 (Red Hat 3.0.5-17) Maven home: /usr/share/maven Java version: 1.8.0_222-ea, vendor: Oracle Corporation Java home: /usr/lib/jvm/java-1.8.0-openjdk- Default locale: en_US, platform encoding: UTF-8 OS name: "linux", version: "4.14.114-105.126.amzn2.x86_64", arch: "amd64", family: "unix"

How to solve: "ERROR: Maven JVM terminated unexpectedly with exit code 137"

In case your Jenkins CI fails to complete building your project but only logging the following: ERROR: Maven JVM terminated unexpectedly with exit code 137 It means maven does NOT have enough memory available. To solve this, simply increase your MAVEN_OPTS memory. Or you may need to increase your system's memory. This is very likely if you run your Jenkins on a virtual machine and you are stingy of memory.

shade is bound to the package phase and is used to create a shaded jar.

Apache Maven Shade Plugin provides the capability to package the artifact in an uber-jar, including its dependencies and to shade - i.e. rename - the packages of some of the dependencies.

The federal telecom regulator significantly lowered the wholesale rates

The federal telecom regulator significantly lowered the wholesale rates that smaller internet resellers pay to access broadband network infrastructure built by major providers like Bell Canada, Rogers. The CRTC said it did so to increase choice, affordability and ensure a competitive marketplace across Canada.

Intel Project Athena machines

Intel unveiled the new Comet Lake 10th-gen chips that will power all sorts of notebooks later this year.  Comet Lake chips will bring support for more cores, more RAM of the faster and more efficient variety, as well as faster Wi-Fi 6 support.  These chips will power a special set of laptops that Intel certifies under the “Project Athena” program. Project Athena machines are supposed to be ultraslim, light devices that feature all-day battery life, always-on internet, and AI support.  Project Athena machines also have to deliver increased performance and responsiveness, and that includes the ability to turn on instantly.

Get the list of event source mappings while using AWS Lambda with Amazon Simple Queue Service

You can get the list of event source mappings by running the following command. $ aws lambda list-event-source-mappings --function-name ProcessSQSRecord \ --event-source SQS-queue-arn The list returns all of the event source mappings you created, and for each mapping it shows the LastProcessingResult, among other things. This field is used to provide an informative message if there are any problems. Values such as No records processed (indicates that AWS Lambda has not started polling or that there are no records in the queue) and OK (indicates AWS Lambda successfully read records from the queue and invoked your Lambda function) indicate that there no issues. If there are issues, you receive an error message.

Get Dell Service Tag from the command line

Get your Dell Service Tag from the command line Windows: From a command prompt, type: wmic bios get serialnumber Linux: From a terminal, type: sudo -i dmidecode -s system-serial-number

MySQL uses DATEDIFF to compare two date type values.

DATEDIFF() returns expr1 − expr2 expressed as a value in days from one date to the other. expr1 and expr2 are date or date-and-time expressions. Only the date parts of the values are used in the calculation. mysql> SELECT DATEDIFF('2007-12-31 23:59:59','2007-12-30');         -> 1 mysql> SELECT DATEDIFF('2010-11-30 23:59:59','2010-12-31');         -> -31

How to find all watching JIRA issues

watcher = currentUser()