Archive for the ‘Ubuntu’ Category

பிழைகள்/Error: dmesg கட்டளையின் கடைசி 4 வரிகள்

[ 306.140067] EXT4-fs (vda1): error count since last fsck: 2
[ 306.140096] EXT4-fs (vda1): initial error at time 1522993704: __ext4_get_inode_loc:4100: inode 6555: block 570
[ 306.140104] EXT4-fs (vda1): last error at time 1522993704: ext4_reserve_inode_write:5151: inode 6555: block 570
[10263.817652] EXT4-fs (vda1): Couldn’t remount RDWR because of unprocessed orphan inode list. Please umount/remount instead


கனிணியின் சேமிப்பக முறைமை சேதமடைந்ததால் மேற்கொண்டு கோப்புகளை உருவாக்கவோ மாற்றவோ முடியாது. ஆகவே கோப்பு முறைமையை  பின்வரும் கட்டளை வரிகளைக்  கொண்டு சரி செய்தல் அவசியம்

Since your file system is in read-only mode, you can not just remount with RW permissions. First, you must clean the orphaned inodes from your file system.

sudo su –

fsck -y /dev/vda1

#Here sda/vda means your hard-disk device name 1-partition number


Read Full Post »

Host Details

smtp-host: [ubuntu 14.04]
client-host: [ubuntu 14.04]
relayhost: Pub IP address [Your/ISP relay host IP]
Error: Relay access denied @client-host

1st Try: Send Email from Command Line Telnet

ubuntu@client-host:~$ telnet stmp-host 25
Connected to stmp-host.
Escape character is ‘^]’.
220 stmp-host ESMTP Postfix (Ubuntu)
MAIL FROM: sender@myemaildomain.com.jp
250 2.1.0 Ok
RCPT TO: receiver@myemaildomain.com.jp
454 4.7.1 <receiver@myemaildomain.com.jp>: Relay access denied

Error @ SMTP Server: /var/log/mail.log

Dec  7 12:50:33 smtp-host postfix/smtpd[26446]: connect from client-host[]
Dec  7 12:51:40 smtp-host postfix/smtpd[26446]: NOQUEUE: reject: RCPT from client-host[]: 454 4.7.1 <receiver@myemaildomain.com.jp>: Relay access denied; from=<sender@myemaildomain.com.jp> to=<receiver@myemaildomain.com.jp> proto=SMTP helo=<myemaildomain.com.jp>
Dec  7 12:51:58 smtp-host postfix/smtpd[26446]: disconnect from client-host[]


Current /etc/postfix/main.cf config @ smtp-host:

# This file is managed by salt – do not edit localy, changes will be overwritten.
# See /usr/share/postfix/main.cf.dist for a commented, more complete version

# Debian specific:  Specifying a file name will cause the first
# line of that file to be used as the name.  The Debian default
# is /etc/mailname.

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no

# appending .domain is the MUA’s job.
append_dot_mydomain = no

# Uncomment the next line to generate “delayed mail” warnings
#delay_warning_time = 4h

readme_directory = no

smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination
myhostname = client-host
myorigin = client-host
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases

mydestination = mail.1nc, localhost.localdomain, localhost, client-host
relayhost = relayhost-ip-address
mynetworks = [::ffff:]/104 [::1]/128
mailbox_size_limit = 0
recipient_delimiter = +


Allow Client network in smtp-hos: /etc/postfix/main.cf

mynetworks = [::ffff:]/104 [::1]/128


mynetworks = [::ffff:]/104 [::1]/128

sudo service postfix restart

2nd Try: Send Email from Command Line Telnet

ubuntu@client-host:~$ telnet smtp-host 25
Connected to smtp-host.
Escape character is ‘^]’.
220 smtp-host ESMTP Postfix (Ubuntu)
HELO myemaildomain.com.jp
250 smtp-host
MAIL FROM: sender@myemaildomain.com.jp
250 2.1.0 Ok
RCPT TO: receiver@myemaildomain.com.jp
250 2.1.5 Ok
354 End data with <CR><LF>.<CR><LF>
Subject: Test Email
Please Confirm..Testing
Bye from e-mail client host
250 2.0.0 Ok: queued as 0B81B46041
221 2.0.0 Bye
Connection closed by foreign host.

E-mail Sent – Successfully

Dec  7 13:42:08 smtp-host postfix/smtpd[26971]: connect from client-host[]
Dec  7 13:42:08 smtp-host postfix/smtpd[26971]: 0B81B46041: client=client-host[]
Dec  7 13:42:08 smtp-host postfix/cleanup[26976]: 0B81B46041: message-id=<642190740.2.1481089328039.JavaMail.root@client-host>
Dec  7 13:42:08 smtp-host postfix/qmgr[26941]: 0B81B46041: from=<sender@myemaildomain.com.jp>, size=666, nrcpt=1 (queue active)
Dec  7 13:42:08 smtp-host postfix/smtpd[26971]: disconnect from client-host[]
Dec  7 13:42:08 smtp-host postfix/smtp[26978]: 0B81B46041: to=<receiver@myemaildomain.com.jp>, relay=relayhost-ip-address[relayhost-ip-address]:25, delay=0.19, delays=0.01/0/0.01/0.17, dsn=2.6.0, status=sent (250 2.6.0 <642190740.2.1481089328039.JavaMail.root@client-host> [InternalId=720659] Queued mail for delivery)
Dec  7 13:42:08 smtp-host postfix/qmgr[26941]: 0B81B46041: removed


Thats all, the above setup was tested using LXC containers on Ubuntu 14.04 LTS.

Read Full Post »

What is Keepalived ?

Keepalived is a routing software written in C. The main goal of this project is to provide simple and robust facilities for loadbalancing and high-availability to Linux system and Linux based infrastructures. Loadbalancing framework relies on well-known and widely used Linux Virtual Server (IPVS) kernel module providing Layer4 loadbalancing. Keepalived implements a set of checkers to dynamically and adaptively maintain and manage loadbalanced server pool according their health. On the other hand high-availability is achieved by VRRP protocol. VRRP is a fundamental brick for router failover.

Visit here for more details : http://www.keepalived.org/


  1. Additional Packages required to build/compile keepalived from sourcesudo apt-get install build-essential libssl-dev keepalived psmisc
  2. Move Installed keepalivedmv /usr/sbin/keepalived /usr/sbin/keepalived.orig
  3. Change keepalived service script:

    vi /etc/init.d/keepalived

    Modify the path: “DAEMON=/usr/sbin/keepalived” to “DAEMON=/usr/local/sbin/keepalived”

  4. Need Additional 1 Virtual IP(VIP) address on top of existing IP

Download Source Code

sudo apt-get install wget

wget wget http://www.keepalived.org/software/keepalived-1.2.13.tar.gz

tar -zxvf keepalived-1.2.13.tar.gz

Build and Install from Source Code

cd keepalived-1.2.13
make install
keepalived -v
Keepalived v1.2.13 (11/30,2016)

Start Keepalived

/etc/init.d/keepalived start


service keepalived start/restart/stop

Error :

Nov 30 15:25:39 node-2 Keepalived[14392]: Starting Keepalived v1.2.13 (11/30,2016)
Nov 30 15:25:39 node-2 Keepalived[14393]: Starting Healthcheck child process, pid=14395
Nov 30 15:25:39 node-2 Keepalived[14393]: Starting VRRP child process, pid=14396
Nov 30 15:25:39 node-2 Keepalived_healthcheckers[14395]: Initializing ipvs 2.6
Nov 30 15:25:39 node-2 Keepalived_vrrp[14396]: Registering Kernel netlink reflector
Nov 30 15:25:39 node-2 Keepalived_vrrp[14396]: Registering Kernel netlink command channel
Nov 30 15:25:39 node-2 Keepalived_vrrp[14396]: Registering gratuitous ARP shared channel
Nov 30 15:25:39 node-2 Keepalived_vrrp[14396]: Opening file ‘/etc/keepalived/keepalived.conf’.
Nov 30 15:25:39 node-2 modprobe: ERROR: ../libkmod/libkmod.c:556 kmod_search_moddep() could not open moddep file ‘/lib/modules/3.19.0-26-generic/modules.dep.bin’
Nov 30 15:25:39 node-2 Keepalived_vrrp[14396]: Configuration is using : 63166 Bytes
Nov 30 15:25:39 node-2 Keepalived_vrrp[14396]: Using LinkWatch kernel netlink reflector…
Nov 30 15:25:39 node-2 Keepalived_vrrp[14396]: VRRP_Instance(V1) Entering BACKUP STATE
Nov 30 15:25:39 node-2 Keepalived_healthcheckers[14395]: IPVS: Can’t initialize ipvs: Protocol not available
Nov 30 15:25:39 node-2 Keepalived[14393]: Healthcheck child process(14395) died: Respawning


sudo modprobe ip_vs

service keepalived restart

Further Details will be updated, stay tuned.



Read Full Post »

Install MySQL 5.6.x

I have installed Ubuntu 14.10 server x64 on my server. After the installation I installed MySQL Server 5.6.34

sudo apt-get install mysql-server-5.6 mysql-client-5.6 mysql-client-core-5.6

Installation was successful but I noticed the following issues with MySQL-5.6. Using sudo service mysql start and sudo service mysql stop the database starts and stops correctly. But when I use sudo /etc/init.d/mysql stop the database service stops and than it gets spawn again automatically without any user input. Using ps -A | grep mysql I noticed that the spawn gets a new PID.

Have you noticed this issue with mysql. For the same reason mysqladmin -u root -p shutdown does the same thing as sudo /etc/init.d/mysql stop



sudo stop mysql

That’s it. Mysql process stopped without any error.




திருக்குறள் :: பொருட்பால் :: அரசியல் :: அறிவுடைமை: 423

எப்பொருள் யார்யார்வாய்க் கேட்பினும் அப்பொருள்
மெய்ப்பொருள் காண்ப தறிவு.

எந்தவொரு பொருள்குறித்து எவர் எதைச் சொன்னாலும், அதை அப்படியே நம்பி ஏற்றுக் கொள்ளாமல் உண்மை எது என்பதை ஆராய்ந்து தெளிவதுதான் அறிவுடைமையாகும்.


Read Full Post »

What is Nginx ?

nginx [engine x] is an HTTP and reverse proxy server, a mail proxy server, and a generic TCP/UDP proxy server, originally written by Igor Sysoev. For a long time, it has been running on many heavily loaded Russian sites including Yandex, Mail.Ru, VK, and Rambler. According to Netcraft, nginx served or proxied 27.80% busiest sites in October 2016. Here are some of the success stories: Netflix, WordPress.com, FastMail.FM.

The sources and documentation are distributed under the 2-clause BSD-like license.

Community website here.

Commercial support is available from Nginx, Inc.

How to Install Nginx from Ubuntu repository ?

sudo apt-get install nginx
nginx -v
nginx version: nginx/1.4.6

Here 1.4.6 is very old and stable release of Nginx. So then how to install the latest version.

Install Nginx Version 1.9.x/1.10.x/1.11.x:

Add repository URLs to “/etc/apt/sources.list.d/nginx.list”
deb http://nginx.org/packages/mainline/ubuntu/ trusty nginx
debsrc http://nginx.org/packages/mainline/ubuntu/ trusty nginx

Now add nginx signing key

wget q O http://nginx.org/keys/nginx_signing.key | sudo aptkey add

Update your system to latest package in nginx repos
sudo apt-get update
Install latest nginx
sudo apt-get install nginx
Now you can see v1.11.5 has been installed on you machine
nginx -v
nginx version: nginx/1.11.5

Read Full Post »


  • OpenSSL installed in Ubuntu
  • Following details for your SSL certificate
    • Country (2 digit ex, IN)=MY,
    • State or =Malaysia,
    • Locality or City=Kuala Lumpur,
    • Organization Name=Marutham Infra Services Sdn Bhd,
    • Organizational Unit Name=Cloud and Advance Services,
    • Common Name (e.g. server FQDN)=maruthuminfra.com.my

Generate CSR:

  • Now Generate Certificate Signing Request (CSR), It also generates Private Key file(Make sure it is protected and no one has access to this file). We use RSA 2048 bit Encryption with SHA256 Hashing algorithm as shown below.
  • openssl req -new -newkey rsa:2048 -nodes -sha256 -out test.csr -keyout test.key -subj “/C=MY/ST=Malaysia/L=Kuala Lumpur/O=Marutham Infra Services Sdn Bhd/OU=Cloud and Advance Services/CN=maruthaminfra.com.my”

  • CSR generation done. Now you may send you CSR file to CA Issuer.
  • Next Install SSL at Load balancer or WebServer or Proxy Server or Application Server where you SSL is getting terminated.

Any Questions, Please comment below

யாதும் ஊரே யாவரும் கேளிர் – புறநானூறு

Read Full Post »

1. Install Sun Java JDK 1.8.x

sudo apt install python-software-properties
sudo add-apt-repository ppa:webupd8team/java
sudo apt update
sudo apt install oracle-java8-installer

2. Download NetExtender.Linux.x.x.yyy.x86_64.tgz

அ) go to https://sslvpn.demo.sonicwall.com/cgi-bin/welcome
ஆ) log in with “demo/password”
இ) click on NetExtender icon, this will download a tar.gz with the client, save it

ஈ) Launch the Terminal and Run following commands

sudo ln -s /lib/x86_64-linux-gnu/libssl.so.1.0.0 /usr/lib/libssl.so.6
sudo ln -s /lib/x86_64-linux-gnu/libcrypto.so.1.0.0 /usr/lib/libcrypto.so.6

3) un-tar the client, make install script executable

tar -zxvf ~arunx/Downloads/NetExtender.Linux.8.5.793.x86_64.tgz -C /opt/

4. Install NetExtender

cd /opt/netExtenderClient


— Dell SonicWALL NetExtender 8.5.793 Installer —
Checking library dependencies…
Checking pppd…
Do you want non-root users to be able to run NetExtender?
If so, I can set pppd to run as root, but this could be
considered a security risk.

Set pppd to run as root [y/N]? y
mode of ‘/usr/sbin/pppd’ retained as 4754 (rwsr-xr–)
mode of ‘/usr/sbin/pppd’ changed from 4754 (rwsr-xr–) to 4755 (rwsr-xr-x)
mode of ‘/etc/ppp’ retained as 0755 (rwxr-xr-x)
mode of ‘/etc/ppp/peers’ changed from 2750 (rwxr-s—) to 2754 (rwxr-sr–)
mode of ‘/etc/ppp/peers/provider’ changed from 0640 (rw-r—–) to 0644 (rw-r–r–)
mode of ‘/etc/ppp/peers’ changed from 2754 (rwxr-sr–) to 2755 (rwxr-sr-x)
Copying files…


To launch NetExtender, do one of the following:

1. Click the NetExtender icon under the Applications menu
(look under the ‘Internet’ or ‘Network’ category)
2. Type ‘netExtenderGui’

5. Launch NetExtenderGUI

Input your Username/Password and Domain name to connect to VPN server


sudo netExtender -u <username> -p <password> -d <domain-name> <Server-IP>:<port-no>

NetExtender for Linux – Version 8.5.793
Dell SonicWALL
Copyright (c) 2016 Dell

Connecting to <Server-IP>:<port-no>
There is a problem with the site’s security certificate.
Warning: self signed certificate
Do you want to proceed? (Y:Yes, N:No, V:View Certificate)Y

Logging in…
Login successful.
failed to retrieve epc agent version
SSL Connection is ready
Using SSL Encryption Cipher ‘DES-CBC3-SHA’
Using new PPP frame encoding mechanism
Using PPP async mode (chosen by server)
Connecting tunnel…
Client IP Address:
You now have access to the following 5 remote networks:
NetExtender connected successfully. Type “Ctrl-c” to disconnect…

If any errors, please post here.

கற்றது கையளவு கல்லாதது உலகளவு – ஒளவையார்

Read Full Post »

Older Posts »