Author: Rahul

I, Rahul Kumar am the founder and chief editor of TecAdmin.net. I am a Red Hat Certified Engineer (RHCE) and working as an IT professional since 2009..

This article will help you to connect Node.js application with MongoDB. Also, configure MongoDB drive for nodejs using Mongoose node application on CentOS and Redhat systems. Step 1 – Prerequsities We assume you already have Node.js and MongoDB installed on your system. If not installed follow our below tutorial first to complete the required installation. Install MongoDB on CentOS & Fedora Install Node.js on CentOS & Fedora Step 2 – Install mongoose Module Mongoose provides a straightforward schema-based solution to modeling your application data and includes built-in typecasting, validation and many more. npm install mongoose Step 3 – Connect Nodejs…

Read More

DHCP (Dynamic Host Configuration Protocol) is a network protocol used for assigning IP address to network clients dynamically from a predefined IP pool. It is useful for LAN network, but not generally used for production servers. This article will help you for Configuring DHCP Server on CentOS, Red Hat System. Read more about dhcp here. Install DHCP Package First install DHCP packages using yum package manager on CentOS, Red Hat systems. DHCP rpms are available under base repositories, so we don’t need to add an extra repository. yum install dhcp Update /etc/sysconfig/dhcpd File Firstly we need to set ethernet interface…

Read More

JavaMail API supports the JavaMail (javax.mail) interface for sending email messages. It provides classes for sending email from remote smtp server with authentication like Gmail, sendgrid etc. In this article we are using JavaMail API for sending emails using Java programming language through remote smtp server. This articles example are using Gmail smtp server as a remote smtp server for sending emails. Step 1: Setup JavaMail Environment First we need to download jar file containing all classes in javax.mail. Download jar (mail.jar) file from oracle official website. Now set the classpath in system environment. Windows users make sure you have…

Read More

JavaMail API supports the JavaMail (javax.mail) interface for sending email messages. javax.mail has all the required classes for sending emails an other mail protocols like SMTP, POP3, and IMAP. In this article we are using JavaMail API for sending emails using Java programming language through local smtp server. make sure you are running smtp server on localhost. Step 1: Setup JavaMail Environment First we need to download jar file containing all classes in javax.mail. Download jar (mail.jar) file from oracle official website. Now set the classpath in system environment. Windows users make sure you have configured PATH variable for your…

Read More
PHP

All the programming languages provide functions for sending emails. PHP also provides mail() function to send emails. But the main point is to increase email delivery to inbox successfully. While sending simple emails the chances of getting email spam increase. Also, a simple PHP mail function has limited options for mail formatting and sending properly. To increase email deliverability and speed we are going to use PHPMailer, which providers lots of option for sending emails. It also provides an option to send email from SMTP servers. Step 1 – Setup PHPMailer Install the phpmailer module using composer under your application.…

Read More

This article will help you to Install MongoDB with NodeJs and configure their connectivity using Mongoose node app on Ubuntu and Debian systems. For PHP users use our previous article to configure MongoDB with PHP and Apache2 on Ubuntu servers. Prerequsities We assume you already have Node.js and MongoDB installed on your system. If not installed follow our below tutorial first to complete the required installation. MongoDB Installation: Install MongoDB on Ubuntu Install MongoDB on Debian Node.js Installation: Install Node.js on Ubuntu Install Node.js on Debian Install “mongoose” Module Mongoose provides a straight-forward, schema-based solution to modeling your application data…

Read More

MongoDB is an open source NoSQL database. These days mongodb is getting more popularity between web developers for their processing speed. And for PHP5 we all are aware that it is use widely use for faster development. In this article we are installing Latest MongoDB database with PHP5 and Apache2 web server on Ubuntu 14.04 LTS. This article will also work with other Ubuntu versions. Step 1: Install Apache2 First install Apache2 web server on our system using following command, this is available under default repositories of Ubuntu. $ sudo apt-get install apache2 After installing Apache2 it will by default…

Read More

Most of the Sysadmins don’t prefer to use / directory to store their files or databases. So if they have installed MongoDB database server, by default it stored all data in /var/lib/mongo (version/os specific). In this tutorial, we will change the MongoDB default data path to other directories where we have attached a new disk (EBS volume in AWS). Instruction’s to Change MongoDB Default Data Path: 1. Before making any changes, stop mongodb service sudo systemctl stop mongod.service 2. Now change the location mongo directory to elsewhere on the filesystem as per need. For this tutorial, create a data directory…

Read More

In Bash Shell Programming case is very useful for replacing a large elif (Else IF) ladder. For example in any situation where we are using multiple if..elif statements, that can be easily replace with case…esac statements In bash shell case statements are started with keyword case and ends with esac. case $VARIABLE in pattern1) <program code here> ;; pattern2) <program code here> ;; pattern10) <program code here> ;; *) <program code here> ;; esac In above syntax $VARIABLE will be the value which will be matched with patterns and the of matching pattern code block will be executed. All the…

Read More

What is GPT Partition ? GPT (GUID Partition Table) is a standard for the layout of the partition table on a physical hard disk, using globally unique identifiers (GUID). GPT is a part of the EFI standard that defines the layout of the partition table. GPT is useful for creating filesystem on disk larger than 2TB. For smaller size of disks generally we use MBR but it does not support disk over 2TB. sgdisk is a command-line GUID partition table (GPT) manipulator for Unix like systems. In this article we are using sgdisk command to Clone/Copy a GPT Partition Table…

Read More