Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts

How to install Tonido private cloud server on Ubuntu Linux

 

Tonido is a free application that allows you to access files on your computer from a web browser, from your handheld or any DLNA capable device. The Tonido server enables you to sync files between different devices and to share them securely with your friends so you have a private and secure Cloud.


Tonido is available for all major operting systems incl. Linux, Mac and Windows, there are also apps available for Android, Iphone and Blackberry. Tonido can also be used to backup files from your phone on your desktop. Please note that Tonido is not open source software, but there is a free versions available that I will cover in this tutorial.
This tutorial is about installing Tonido server on Ubuntu Linux.

Tonido installation
The following installation instructions are for a 64 bit system, for 32 bit systems I request you to visit here.

Dual boot : Windows8 and Debian mint

if you want to dual-boot Windows 8 and Linux Mint Debian Edition 2 on a computer with UEFI firmware, this steps given in this tutorial will work also.
Getting From Here To There: To successfully set up a dual-boot system with Windows 7 and Linux Mint Debian 2, you’ll need to have access to a Windows 7 computer. After that, enough space has to be recovered from the C drive to use for installing LMDE 2. Then you’ll download an installation image of LMDE 2, transfer it to a USB stick and then install it alongside Windows 7 on the target hard disk.
To install LMDE 2, the following partitions have to be created:
  • Root partition – mounted at /
  • Home partition – mounted at /home
  • Swap partition
If you’re new to disk partitioning in Linux, take a moment to read Beginners to disks and disk partitions in Linux before embarking on this fun adventure.

SSH in simple five steps

SSH (Secure SHELL) is an open source and most trusted network protocol that is used to login into remote servers for execution of commands and programs. It is also used to transfer files from one computer to another computer over the network using secure copy (SCP) Protocol.
In this article we will show you how to setup password-less login on RHEL/CentOS 7.x/6.x/5.x and Fedorausing ssh keys to connect to remote Linux servers without entering password. Using Password-less login with SSH keys will increase the trust between two Linuxservers for easy file synchronization or transfer.
SSH Passwordless Login
Setup SSH Passwordless Login

NginX as Reverse proxy : Multiple applications on single domain

Usually when you install a Web Application you assign its own domain for it, but there are a handful times when you want to install two or even more applications under the same domain. For example, let’s say you have a Wordpress blog, and you want to use ZenPhoto for your photo album, and just to complicate it a little more you want to have a forum managed by Discourse. Sure you can just use Wordpress plugins to make Wordpress manage all of these, or use Drupal or any other thing, but for this example let’s suppose you want to do it this way.

NITROSHARE 0.3.0: EASILY SEND FILES TO OTHER MACHINES ON THE LOCAL NETWORK

NitroShare is a tool that can be used to easily transfer files between computers on your local network, available for Linux, Windows and Mac OS X.

NitroShare features:
  • no configuration required: each device running NitroShare broadcasts its presence to other devices on the network;
  • supports transferring files as well as directories;
  • displays desktop notifications for completed transfers or when someone on the local network starts or quits NitroShare;
  • simple, easy to use user interface.

Tails : Limitations & Warnings

Tor is about hiding your location, not about encrypting your communication.
Instead of taking a direct route from source to destination, communications using the Tor network take a random pathway through several Tor relays that cover your tracks. So no observer at any single point can tell where the data came from or where it's going.
A Tor connection usually goes through 3 relays with the last one establishing the actual connection to the final destination
The last relay on this circuit, called the exit node, is the one that establishes the actual connection to the destination server. As Tor does not, and by design cannot, encrypt the traffic between an exit node and the destination server, any exit node is in a position to capture any traffic passing through it.

Tails : Next gen operating system

Tails is a live system that aims to preserve your privacy and anonymity. It helps you to use the Internet anonymously and circumvent censorship almost anywhere you go and on any computer but leaving no trace unless you ask it to explicitly.
It is a complete operating system designed to be used from a DVD, USB stick, or SD card independently of the computer's original operating system. It is Free Software and based on Debian GNU/Linux.

Activate WhatsApp Calling Feature


WhatsApp's latest voice calling feature that had been under testing is finally available. The WhatsApp voice calling feature is enabled in the latest version of the WhatsApp Messenger that is now available for download for Android devices on Google Play (version 2.11.561).
However, the feature doesn't come right away to the users. Those who want to have the voice calling feature will need an invite, in the form of a WhatsApp call from any other WhatsApp user who has the feature activated on his/her app.
The steps involved are fairly simple:
1. Go to Google Play and download/update the free WhatsApp Messenger app.
2. Ask any other WhatsApp user you know with the voice calling feature activated to call you via WhatsApp.
Post the call, a user can find the WhatsApp voice calling feature activated on their phones and a new 'Calls' tab to the left of the Chats and Contacts tab on the WhatsApp home screen.
While there have been unofficial APKs floating around promising the feature, but it is advisable that users install the app from Google Play or the official WhatsApp website.

How to enable WhatsApp voice calls (with root)

In case none of this is still working for you, there is another way for rooted users to force the feature onto their phones, but it is a bit of a pain, as you’ll need to be connected to your PC and open a terminal every time you want to WhatsApp call someone (until it is enabled permanently for you).
Just open a terminal emulator and enter the following command:

su -c am start -n com.whatsapp/com.whatsapp.HomeActivity

Way2SMS PHP integration

Way2SMS PHP Integration 


Way2Sms is free SMS provider in India as well as abroad, It is best in class service provider. We need SMS verification like OTP (One Time Password ), Notification and information for our website/applications. I also have same requirement for my web application where I need to send OTP for user authentication. I search a lot for free services but  now days, everyone busy to make money so There is no free service for SMS Gateway than I found a way to right a script in PHP which communicate with way2sms and send a message. Hope so it is also work for you.

Requirement : 
PHP 5.5 + 
support for PHP curl
valid way2sms account.
create cookie.txt and temporary.txt in same directory.

HAProxy (High Availability Proxy)

HAProxy(High Availability Proxy) is an open source load balancer which can load balance any TCP service. It is particularly suited for HTTP load balancing as it supports session persistence and layer 7 processing.





HA Proxy Setup  :

I was working with Apache Webserver from very long but when I jumped into the world of NodeJS I started loving websockets. Soon I was planning to integrate my PHP applications with NodeJS. I was happy to use both, till I was not running both the applications on default web service port 80. But when I tried to configure Apache virtual hosting for proxying my request to NodeJS server port, it was not allowing my websocket communication to happen. I tried alot of modules but didn’t got success. And after alot of googling I found something which helped me to achieve what I need. Once I configured HAProxy on my system I was able to serve both applications, PHP and NodeJS through port 80 just by virtual hosting of HAProxy.

Docker : An Introduction to LXC

Docker is an open source project, which packages applications and their dependencies in a virtual container that can run on any Linux server. Docker has immense possibilities as it facilitates the running of several OS's on the same server.


Technology is changing faster than styles in than fashion world, and there are many new entrants specific to the open source, cloud, virtualisation, and DevOps technologies. Docker is one of them. The aim of this article is to give you a clear idea of Docker, its architecture and its functions, before getting started with it. 
Docker is a new open source tool based on Linux container technology(LXC), designed to change how you think about workload/application deployments. It helps you to easily create light-weight, self-sufficient, portable application containers that can be shared, modified and easily deployed to different infrastructure such as cloud/compute servers or bare metal servers. The Idea is to provide a comprehensive abstraction layer that allows developers to 'containerise' or 'package' any application  and have it run on any infrastructure.
Docker is based on container virtualisation and it is not new. There is no better tool than Docker to help manage kernel level technologies such as LXC, cgroups and a copy-on-write filesystems. It helps us manage the complicated kernel layer technologies through tools and APIs.

Setting up a SVN Server on a EC2 Instance (Ubuntu 14.04 LTS)

Setting up an SVN server on my EC2 instance (on AWS), is a major problem whenever we connect svn using key-file(key.pem for AWS).
Here’s my situation:
  • I have a micro EC2 instance hosted with Amazon.
  • I used a non-standard port for ssh access
  • I have a pem file provided by Amazon for access through ssh
  • I run Ubuntu 14.04 Server on my EC2 instance
  • On the client side, I’m running Ububtu 14.04 Desktop
With that out of the way, the first thing I had to do was insure svn was installed on my server and Desktop :
sudo apt-get install -y subversion

Then, on my EC2 instance, I want to create both the directory where I’ll store repositories, and the subsequently, create the repository itself. Permissions and ownership are of the utmost importance. This worked for me:
sudo mkdir -p /srv/svn/
sudo chown ubuntu:ubuntu /srv/svn/
svnadmin create /srv/svn/{repo_name}
Mind the {rep_name} placeholder above 

vim /svnrepos/conf/svnserve.conf
In that file add these three lines:
anon-access = none
auth-access = write
password-db = passwd
Create a password file:
vi /svnrepos/conf/passwd
In that file add a line for your user:
# add users in the format : user = password
tony = mypassword

Ubuntu : Netbeans Installation

This Guide is useful for Netbeans Installation on Ubuntu. Generally we face problems during installation of Netbeans like JDK path, package not available, permissions denied etc. This guide gives  you step by step instructions to easy installation of Netbeans. Hope so it helps you a lot !

1. Update your Ubuntu 14.04 :
Ubuntu is open-source operating system which provides updates frequently for users to overcome security breaches and enhance user experience. Just type this command on your terminal : (open terminal using Ctrl+Alt+t or type terminal in ubuntu search bar )       
sudo add-apt-update

For LAMP stack use following commands :
sudo apt-get install apache2
sudo apt-get install php5
sudo apt-get install mysql-server mysql-client
sudo apt-get install phpmyadmin
 
2. Download Netbeans from official website :  
Select your os type(32/64 bit) and download from following link :
                               https://netbeans.org/downloads/

Linux Basic Tutorials Part - 8


UNIX/Linux Tutorial 

UNIX Variables

Variables are a way of passing information from the shell to programs when you run them. Programs look "in the environment" for particular variables and if they are found will use the values stored. Some are set by the system, others by you, yet others by the shell, or any program that loads another program. 
Standard UNIX variables are split into two categories, environment variables and shell variables. In broad terms, shell variables apply only to the current instance of the shell and are used to set short-term working conditions; environment variables have a farther reaching significance, and those set at login are valid for the duration of the session. By convention, environment variables have UPPER CASE and shell variables have lower case names.

Linux Basic Tutorials Part - 7


UNIX/Linux Tutorial

Other useful UNIX commands  

quota

All students are allocated a certain amount of disk space on the file system for their personal files, usually about 100Mb. If you go over your quota, you are given 7 days to remove excess files.
To check your current quota and how much of it you have used, type
% quota -v

Linux Basic Tutorials Part - 6


UNIX/Linux Tutorial 

File system security (access rights)

In your unixstuff directory, type
% ls -l (l for long listing!)
You will see that you now get lots of details about the contents of your directory, similar to the example below.
Each file (and directory) has associated access rights, which may be found by typing ls -l. Also, ls -lg gives additional information as to which group owns the file (beng95 in the following example):
-rwxrw-r-- 1 ee51ab beng95 2450 Sept29 11:52 file1
In the left-hand column is a 10 symbol string consisting of the symbols d, r, w, x, -, and, occasionally, s or S. If d is present, it will be at the left hand end of the string, and indicates a directory: otherwise - will be the starting symbol of the string. 

Linux Basic Tutorial Part - 5


UNIX/Linux Tutorial

Wildcards

The * wildcard

The character * is called a wildcard, and will match against none or more character(s) in a file (or directory) name. For example, in your unixstuff directory, type
% ls list*
This will list all files in the current directory starting with list....
Try typing
% ls *list
This will list all files in the current directory ending with ....list

Linux Basic Tutorials Part -4


UNIX/Linux Tutorial 

Redirection  

Most processes initiated by UNIX commands write to the standard output (that is, they write to the terminal screen), and many take their input from the standard input (that is, they read it from the keyboard). There is also the standard error, where processes write their error messages, by default, to the terminal screen.
We have already seen one use of the cat command to write the contents of a file to the screen.

Linux Basic Tutorials Part - 3


UNIX/Linux Commands

 Copying Files

cp (copy)

cp file1 file2 is the command which makes a copy of file1 in the current working directory and calls it file2 
What we are going to do now, is to take a file stored in an open access area of the file system, and use the cp command to copy it to your unixstuff directory.
First, cd to your test directory.
% cd ~/unixstuff
Then at the UNIX prompt, type,
% cp /vol/examples/tutorial/science.txt .
Note: Don't forget the dot . at the end. Remember, in UNIX, the dot means the current directory.
The above command means copy the file science.txt to the current directory, keeping the name the same.
(Note: The directory /vol/examples/tutorial/ is an area to which everyone in the school has read and copy access.

Linux Basic Tutorials Part - 2

After looking on Open Source and GNU . We look around basic command of the Linux/Unix.

1.1 Listing files and directories

ls (list)

When you first login, your current working directory is your home directory. Your home directory has the same name as your user-name, for example, john123, and it is where your personal files and subdirectories are saved.
To find out what is in your home directory, type
% ls
The ls command ( lowercase L and lowercase S ) lists the contents of your current working directory.
There may be no files visible in your home directory, in which case, the UNIX prompt will be returned. Alternatively, there may already be some files inserted by the System Administrator when your account was created.
ls does not, in fact, cause all the files in your home directory to be listed, but only those ones whose name does not begin with a dot (.) Files beginning with a dot (.) are known as hidden files and usually contain important program configuration information. They are hidden because you should not change them unless you are very familiar with UNIX!!!
To list all files in your home directory including those whose names begin with a dot, type
% ls -a
As you can see, ls -a lists files that are normally hidden.
ls is an example of a command which can take options: -a is an example of an option. The options change the behaviour of the command. There are online manual pages that tell you which options a particular command can take, and how each option modifies the behaviour of the command. (See later in this tutorial)