Archive for August, 2012

Using mod_spdy With Apache2 On Fedora 17

SPDY (pronounced “SPeeDY”) is a new networking protocol whose goal is to speed up the web. It is Google’s alternative to the HTTP protocol and a candidate for HTTP/2.0. SPDY augments HTTP with several speed-related features such as stream multiplexing and header compression. To use SPDY, you need a web server and a browser (like Google Chrome and upcoming versions of Firefox) that both support SPDY. mod_spdy is an open-source Apache module that adds support for the SPDY protocol to the Apache HTTPD server. This tutorial explains how to use mod_spdy with Apache2 on Fedora 17

1 Preliminary Note

SPDY runs over HTTPS, so we need an HTTPS-enabled web site to test SPDY. Please note that SPDY will fall back to HTTPS if the user’s browser does not support SPDY or if things go wrong, so installing mod_spdy doesn’t hurt your existing setup.

default SSL web site’s URL (e.g. https://www.example.com) and test if it works

2 Installing mod_spdy

at is installed

Continue reading “Using mod_spdy With Apache2 On Fedora 17” »

Be the first to comment - What do you think?  Posted by Aniruddh - August 9, 2012 at 12:18 am

Categories: Apache, Fedora   Tags:

Enabling/Disabling TLS Based On User Or Group

This article explains how to enable or disable TLS in ProFTPd based on the FTP user or group. FTP is a very insecure protocol because all passwords and all data are transferred in clear text. By using TLS, the whole communication can be encrypted, thus making FTP much more secure. While this is a good thing, not all FTP clients support TLS.

1 Preliminary Note

TLS set up already, for example as described in this tutorial: Setting Up ProFTPd + TLS On Debian Squeeze

you can use TLSRequired off in your ProFTPd configuration as this allows for TLS and non-TLS logins, but if you want to make your FTP setup as secure as possible, you should enforce the use of TLS and make exceptions only for the users or groups that use an FTP client that doesn’t support TLS

2 TLS Configuration Based On User/Group

Continue reading “Enabling/Disabling TLS Based On User Or Group” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 12:15 am

Categories: Web Server   Tags:

Ubuntu 12.04 Samba Standalone Server With tdbsam Backend

The installation of a Samba fileserver on Ubuntu 12.04 and how to configure it to share files over the SMB protocol as well as how to add users. Samba is configured as a standalone server, not as a domain controller. not issue any guarantee that this will work for you.

1 Preliminary Note

an Ubuntu 12.04 system here with the hostname server1.example.com and the IP address 192.168.0.100

running all the steps in this tutorial with root privileges, so make sure you’re logged in as root

sudo su

2 Installing Samba

Connect the server on the shell and install the Samba packages

apt-get install libcups2 samba samba-common

Edit the smb.conf file

vi /etc/samba/smb.conf

remove the “#” at the beginning of the line security = user in the below

[...]
# "security = user" is always a good idea. This will require a Unix account
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba3-HOWTO/ServerType.html
# in the samba-doc package for details.

 Continue reading “Ubuntu 12.04 Samba Standalone Server With tdbsam Backend” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 12:01 am

Categories: File Server, Ubuntu   Tags:

Using mod_spdy With Apache2 On Ubuntu 12.04

SPDY means is a new networking protocol whose goal is to speed up the web. It is Google’s alternative to the HTTP protocol and a candidate for HTTP/2.0. SPDY augments HTTP with several speed-related features such as stream multiplexing and header compression.This tutorial explains how to use mod_spdy with Apache2 on Ubuntu 12.04.

1 Preliminary Note

SPDY runs over HTTPS, so we need an HTTPS-enabled web site to test SPDY. Please note that SPDY will fall back to HTTPS if the user’s browser does not support SPDY or if things go wrong, so installing mod_spdy doesn’t hurt your existing setup.

assuming that you have a working LAMP setup, as described on Installing Apache2 With PHP5 And MySQL Support On Ubuntu 12.04 LTS (LAMP)

testing purposes I wil lsimply enable the default SSL web site that comes with Ubuntu’s Apache package

Continue reading “Using mod_spdy With Apache2 On Ubuntu 12.04” »

Be the first to comment - What do you think?  Posted by Aniruddh - August 8, 2012 at 11:36 pm

Categories: Ubuntu, Web Server   Tags:

Fedora 17 Samba Standalone Server With tdbsam Backend

This guide  explains the installation of a Samba fileserver on Fedora 17 and  to configure it to share files over the SMB protocol as well as how to add users. Samba is configured as a standalone server, not as a domain controller. In the resulting setup, every user has his own home directory accessible via the SMB protocol and all users have a shared directory with read-/write access.

1 Preliminary Note

a Fedora 17 system here with the hostname server1.example.com and the IP address 192.168.0.100

SELinux should be  disabled

Edit /etc/selinux/config and set SELINUX=disabled
vi /etc/selinux/config
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected.
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted
must reboot the system
reboot

2 Installing Samba

Connect server on the shell and install the Samba packages

yum install cups-libs samba samba-common

Edit the smb.conf file

vi /etc/samba/smb.conf

see the following lines in the [global] section

[...]
# ----------------------- Standalone Server Options ------------------------
#
# security = the mode Samba runs in. This can be set to user, share
# (deprecated), or server (deprecated).
#
# passdb backend = the backend used to store user information in. New
# installations should use either tdbsam or ldapsam. No additional configuration
# is required for tdbsam. The "smbpasswd" utility is available for backwards
# compatibility.
#

        security = user
        passdb backend = tdbsam


 Continue reading “Fedora 17 Samba Standalone Server With tdbsam Backend” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 11:31 pm

Categories: Fedora, File Server   Tags:

To Use Nagios Plugins In Verax NMS

This lesson shows how to use Nagios plugins to monitor devices in Verax NMS Express. Verax NMS is a cross-platform network and application monitoring software.

Tools used

Nagios plugin for CPU check in a Shell Script format (.sh file) http://exchange.nagios.org/directory/Plugins/System-Metrics/CPU-Usage-and-Load/Check-CPU-LOAD-using-SNMP/details

Verax NMS Express ver. 1.9.5: http://www.veraxsystems.com/en/products/nms

Adding Nagios Plugin To The Device

download a plugin use plugin for checking CPU usage over the SNMP. Insert  plugin in a folder on the same server where Verax NMS Express is installed.

/root/nagios/check_snmp_cpu.sh

let’s add shell script sensor to the device

  1. Log into the Verax NMS, select Home from the main menu and select the right device from the aspects tree.
  2. In Monitors tab select Add option and click Go. The system will display a pop-up dialog with sensors available for your device.
  3. Select Shell Script Sensor from the sensors tree and click Next.
  4. Now you have to specify your sensor parameter

Continue reading “To Use Nagios Plugins In Verax NMS” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 11:25 pm

Categories: Monitoring   Tags:

Mounting Host Devices/Partitions/Directories In A Container With Bind Mounts

where you need to mount a hard drive, partiiton or directory from the OpenVZ host inside an OpenVZ container explains how you can mount host devices/partitions/directories in an OpenVZ container with bind mounts

1 Preliminary Note

an OpenVZ container with the container ID 101 which is running MySQL. I add a second hard drive to the host and want to put the container’s MySQL directory /var/lib/mysql on the second hard drive

2 Preparing The Host

a new hard drive to the host

fdisk -l

the hard drive is /dev/sdb:

root@server1:~# fdisk -l

Disk /dev/sda: 32.2 GB, 32212254720 bytes
255 heads, 63 sectors/track, 3916 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00029d5c

Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        3793    30461952   83  Linux
/dev/sda2            3793        3917      992257    5  Extended
/dev/sda5            3793        3917      992256   82  Linux swap / Solaris

Disk /dev/sdb: 32.2 GB, 32212254720 bytes
255 heads, 63 sectors/track, 3916 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0×00000000

Continue reading “Mounting Host Devices/Partitions/Directories In A Container With Bind Mounts” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 6:27 pm

Categories: Linux   Tags:

Benchmark Your System CPU, File IO, MySQL

Benchmark suite which allows you to quickly get an impression about system performance which is important if you plan to run a database under intensive load.

not issue any guarantee that this will work for you

1 Installing sysbench

Debian/Ubuntu, sysbench can be installed

apt-get install sysbench

a look

man sysbench

2 CPU Benchmark

benchmark your CPU performance

sysbench –test=cpu –cpu-max-prime=20000 run

root@server1:~# sysbench –test=cpu –cpu-max-prime=20000 run
sysbench 0.4.12:  multi-threaded system evaluation benchmark

Running the test with following options:
Number of threads: 1

Doing CPU performance benchmark

Threads started!
Done.

Continue reading “Benchmark Your System CPU, File IO, MySQL” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 6:22 pm

Categories: Linux, MySQL   Tags:

Configuring An Email Gateway With Scrollout F1 Anti-Spam & DLP

Email gateway installed between Internet and the email server.to protect the email server by filtering incoming messages, via SMTP protocol, from Internet an email gateway may be used as an outgoing gateway in case you want to add some new email features as Secondary a quality improvement for message delivery

Basic Configuration

CONNECT

Set the network connection: IP address, subnet mask, gateway and DNS.

TRAFFIC

mention your domains and the responsible email server for each domain. The servers can have same value in case you are using one email server for multiple domains.

for receiving emails gateway system will become responsible Optionally the gateway for sending outgoing messages DKIM signature and the values that are necessary to be used in your DNS server for each domain. In case that your email servers are using IP addresses different than standard intranet CIDR (10.0.0.0/8, 192.168.0.0/24, 172.16.0.0/12) you must mention the range or IP in CIDR format by clicking “DKIM”

SECURITY

set the aggressiveness by clicking on a number between 1 and 10

COUNTRIES

Set the geographical area in which you have business

COLLECT

two roles of SPAM & LEGIT

Continue reading “Configuring An Email Gateway With Scrollout F1 Anti-Spam & DLP” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 6:17 pm

Categories: Linux, Mail Server   Tags:

Creating Backups & Clones Of Running Virtual Machines (No Downtime) With LVM Snapshots

use LVM volumes for your VirtualBox VMs This lesson shows using LVM snapshots to create backups and clones of running VirtualBox VMs without downtime

1 Preliminary Note

Installed VirtualBox on a headless server use phpvirtualbox as the VirtualBox GUI here. use the original VirtualBox GUI then only it will be perfect.

Running virtual machine named vm10 located on the LVM volume /dev/vg0/vm10.

logged in as root

sudo su

Should run as root user

2 Create A Backup Of A Running VM With LVM Snapshots

create a backup of the running virtual machine vm10 Snapshots can be smaller than the original volume – 512MB

lvcreate -L5G -s -n vm10_snap /dev/vg0/vm10

use dd to read the contents from the snapshot and pipe it to gzip to create a gzipped backup image in the directory

dd if=/dev/vg0/vm10_snap bs=64k | gzip -c > /backup/vm10.img.gz

your backup of vm10 is now located in /backup/vm10.img.gz.

remove the LVM snapshot

Continue reading “Creating Backups & Clones Of Running Virtual Machines (No Downtime) With LVM Snapshots” »

Be the first to comment - What do you think?  Posted by Aniruddh - at 6:09 pm

Categories: Backup, Linux, Storage   Tags:

Next Page »