12 December 2009

10 reasons why Linux will triumph over Windows

Windows 7 may be generating some positive buzz, but Jack Wallen remains sceptical. In fact, he says it's only a matter of time before Linux takes its rightful spot at the top of the OS heap.

I have an announcement: the error of Microsoft's ways is finally catching up and will cause the once-invincible juggernaut to kneel before that which is Linux. How is this? Microsoft started a tiny snowball when it released Windows Me. That snowball did nothing but gain momentum. There have been ups and downs along the way (XP being an up, for sure). But for the most part, the court of public opinion has steadily lost faith in what once was considered the heart of personal computing.

If you don't believe me, read on.

1: Inconsistent Windows releases

One of the things you can always count on from Microsoft is that you can't count on its new operating systems to be reliable. Let's take a look at the individual releases:

|> Windows 95: revolutionised personal computing.
|> Windows 98: attempted to improve on Windows 95; failed miserably.
|> Windows Me: a joke, plain and simple.
|> Windows NT: attempted to bring enterprise-level seriousness to the operating system; would have succeeded had it not taken Steven Hawking-like intelligence to get it working.
|> Windows XP: brought life back to the failing Windows operating system. It hadn't been since Windows 95 that the operating system was this simple.
|> Windows Vista: see Windows Me.

With this in mind, what do we expect from Windows 7? Myself, not much.

2: Consistent Linux releases

Converse to number 1, you have the far more consistent releases of the various Linux distributions. Yes, there have been a few dips along the way (Fedora 9 being one of them). But for the most part, the climb for Linux has been steadily upward. Nearly every Linux distribution has improved with age. And this improvement isn't limited to the kernel. Look at how desktops, end-user software, servers, security, admin tools, etc, have all improved over time. One could easily argue that KDE 4 is an example of a sharp decrease in improvement. However, if you look at how quickly KDE 4 has improved from 4.0 to 4.3 you can see nothing but gains. This holds true with applications and systems across the board with Linux.

3. Continuing Windows price hikes

Recently, I have had a number of long-time Microsoft administrators asking my advice on solid replacements for Exchange. The reason? Microsoft changed its licensing for Exchange to a per-user seat. Now anyone who logs on to an Exchange server must have a licence. You have 100 employees (including administrators) who need to log on to Exchange? Pony up! This gets serious when your company starts having to cough up the money for 500+ Exchange licences. The very idea that Microsoft would make such a bold change to licences is made even more ridiculous considering the current state of the economy. Companies worldwide are having to scale back. And like Exxon Mobile celebrating record profits amid the catastrophe known as Hurricane Katrina, Microsoft creating such a cost barrier while the globe is facing serious recession is irresponsible and reprehensible.

4. Stable Linux "prices"

Converse to number 3, the prices of open-source software licences have remained the same -- $0.00. When those administrators come to me asking for open source replacements for Exchange I point them to eGroupware and Open-X-Change. Both are outstanding groupware tools that offer an even larger feature set than their Microsoft equivalent. Both are reliable, scalable, secure and free. The only cost you will have with either is the hardware they are installed upon. And with both packages, there is no limit to the amount of users that can be set up. One user, 1,000 users -- it's all good with open source software.

5: Windows hardware incompatibility

Microsoft Vista was a nightmare when it came to hardware compatibility. Not only was Vista incompatible with numerous peripherals, it took supercomputer-level iron to run the operating system! Sure this was a boon to Intel, which stood to make a pretty shiny penny. Intel knew a good amount of the public would be shelling out for new hardware, and the new hardware would cost more because it had to be faster to run Vista in all its Aero glory. But even hardware that would run nearly any other OS with lightening-fast speed was brought to a slow, grinding halt with Vista.

6: Linux hardware compatibility

Converse to number 5, Linux continues to advance in the category of hardware compatibility. Take Xorg, for example. Recent developments with the star of Linux' graphical desktops have the X Windows server running sans xorg.conf. This was done primarily because the system had grown so good at detecting hardware. And so long as there wasn't a cheap KVM between your monitor and your PC, Xorg would easily find the mode for your display and run X properly. With new distributions (such as Fedora 10), X configuration is becoming a thing of the past. Most other pieces of hardware are finding the same level of recognition.

7: Windows promises

I wanted to save this for last, but seeing as how it is number 7... We've all heard the pundits proclaiming Windows 7 will be the resurrection of the Microsoft operating system. But I recall this same proclamation with nearly every release from Redmond. Windows Vista was going to revolutionise the way the user interfaced with the computer. Vista was going to be the operating system you would never notice. Instead, Vista refused to NOT let you notice. And Windows Me was going to take Windows 98 and make it far more simple for the average user. What did it really do? Remove nearly every actual functioning system in the operating system, leaving little more than a browser and an email client.

Everyone is always fond of saying the next Windows release will redefine the personal computer. But the public has finally reached such a point of apathy for Microsoft's up and coming, the majority doesn't even realise something new is coming out. The media can continue to push Windows 7, but the public will continue using XP until Microsoft pries it from its cold, dead fingers. And, of course, no one really knows when Windows 7 will land. How many dates Microsoft announces vs. how many dates change will probably be a 1:1 ratio.

8: Linux transparency

Converse to 7... The next release of any Linux distribution is never shrouded in mystery. Because of the nature of open source, the release candidates are always available to the public (and not on a limited basis), and the timeline is always made available. Any user can know exactly when a feature-freeze happens for a release of any distribution. And all Linux distributions work under the "full disclosure" model. Because of this, there is little false advertising going on with Linux. And unlike with Microsoft, you will never hear of a distribution claiming that its next release will revolutionise computing. If you go to the Fedora Project Wiki, you can view all the proposed and accepted features that will be included in the next release. You can also view the completed release schedule, where you will see that Fedora 11 has set an alpha release of 3 February 2009, a beta release of 24 March 2009, and a final release of 26 May 2009. These dates are fairly firm and almost always on target.

9: Feature comparison

Let's compare the feature lists of Windows 7 and Fedora 11.

|> Windows 7: OS X-like Doc, multi-touch screen, mapping application similar to Google Earth, Hyper-Visor virtualisation, location-aware apps, User Access Control improvements, Sidebar removal.
|> Fedora 11: 20-second boot time, btrfs file system, Better C++ support, Cups PolicyKit integration, DNS Security (DNS SECurity), ext4 default file system, fingerprint reader integration, IBUS input method replaces SCIM (to overcome limitations), GNOME 2.26, KDE 4.2, Windows cross-compiler inclusion.

If you look at those features in and of themselves, you could easily argue that either one could be the more impressive list (depends upon your bias). But understand that the Fedora 11 features are added on an already outstanding operating system, whereas the Windows 7 features are being added to a lesser operating system. And what Microsoft is proclaiming to be the biggest improvement (multi-touch) doesn't actually improve the operating system and also requires, surprise, new hardware! To get the most out of Fedora 11, you'll be good to go with what you already have.

10: Hardware requirements

Vista-lite? Out of the mouths of Microsoft comes the proclamation that Windows 7 will run on any hardware that would run Vista and even slightly less powerful hardware. Slightly less powerful? What exactly does that mean? Well for one, Windows 7 will have no luck in the netbook market. And since XP is dying, the netbook market will be owned by Linux. Netbooks are not gaining enough power to run anything from Windows but the watered-down version of XP. Netbooks are not going anywhere, and consumers (both home and corporate) have their limits on how many hardware upgrades they will make to fulfil an operating systems' needs. As of Fedora 10, the minimum system requirements look like something out of the mid '90s.

05 November 2009

How to make Linux Debian based as Web Server

If you want to make your linux debian based as Web server, bellow is the way

Installing Apache 

apt-get install apache2

After that , do test HTTP Server:
Open a web browser and enter http://localhost or its IP Address http://ip-address.

Installing PHP

apt-get install php4
/etc/init.d/apache2 restart
vi /var/www/testphp.php

To test it, Insert this following line into testphp.php file.

<?php phpinfo(); ?>
Save this new file.
Open a web browser and enter http://IP-Address/testphp.php .

Install PostgreSQL

apt-get install libapache2-mod-auth-pgsql
apt-get install php4-pgsql
/etc/init.d/apache2 restart

Mapping URLs to folders outside /var/www/

vi /etc/apache2/conf.d/alias

Insert this following line into the new file.

 
Alias /URL-path /location_of_folder/

<directory /location_of_folder/>
   Options Indexes FollowSymLinks
   AllowOverride All
   Order allow,deny
   Allow from all
</Directory>

Save a new file.

Restart Apache
/etc/init.d/apache2 restart

finished :)

28 October 2009

How to Flush DNS in Linux

In Linux, the nscd daemon manages the DNS cache. So if we want to flush the DNS cache, we do it via that nscd daemon.

To flush the DNS cache, restart the nscd daemon.

To restart the nscd daemon, use the command 
/etc/init.d/nscd restart

To restart the nscd daemon, we can also use the command

service nscd restart

20 September 2009

Music Player in Linux

Alternatif Music Player for Linux

Linux have various music player for your enjoyment. You can choose music player you like which  ofcourse free or opensource. Here are some of them :

Rhythmbox
Rhythmbox is default music player for Gnome, at least until now. Rhythmbox have appearance like iTune and have capability to indexes your music and gives you fast access to it.  You can easily plays and organize digital music via Rhythmbox. Rythmbox comes with two built-in music stores and uses the Linux Hardware Abstraction Layer(HAL) to detect Player Devices.

Audacious
Audacious is a audio player which have skinnable GUI just like Winamp with compact, collapsible, movable playlist editor which make you easy to view, sort, shuffle, load and save your music playlists. Moreover, Audacious also have built-in equalizer which also collapsible and movable. The Equalizer presets can be saved and loaded, and configured to load presets automatically depending on the file being played. Audacious supports most popular audio formats like MP3, AAC, WMA v1-2, Monkey’s Audio, WavPack, various module formats, console/chip formats, CD Audio, FLAC, Ogg Vorbis, and other.

Banshee
Banshee is another music player which moch more like Rythmbox.With Banshee you can easily import, manage, and play selections from your music collection. Banshee uses Gstreamer to play, encode, and decode Ogg Vorbis, MP3s, and other music formats, with only AAC files requiring the use of RealNetwork’s Helix media framework for decoding. With this music player, you can easily transfer videos or music to your iPod

Amarok
Amarok is an audio player based on QT4 for KDE. Amarok can be used to organize a library of music into folders according to genre, artist, and album, can edit tags attached to most music formats, associate album art, attach lyrics, and automatically “score” music as it is played. Amarok does not support any media types directly, but instead uses a backend independent approach. There are plugins available for the iRiver media devices, Apple iPod, Creative Nomad and Zen.

15 August 2009

How to Install Virtual Box on Linux (Fedora)

This is how to get VirtualBox up and running on Linux Fedora 10.  Also, this tutorial is for the 32-Bit version of VirtualBox, so you’ll have to customize a little more to get the 64-bit version running. Everything in the “code” sections should be copy/pasted/typed into the terminal.
Right, let’s get to it:

PreStep.) Open the terminal and get into super user mode:

    su -

1.) Get the latest VirtualBox package (as of now, 2.0.6) from the VirtualBox website for Fedora 9 and install it (generally, after a few months, the Fedora 10 link will be available).

    wget http://download.virtualbox.org/virtualbox/2.0.6/VirtualBox-2.0.6_39765_fedora9-1.i386.rpm && rpm -ivh VirtualBox-2.0.6_39765_fedora9-1.i386.rpm

2.) Get the kernel-devel package:

    yum install make automake autoconf gcc kernel-devel dkms

3.) Run the setup file for VirtualBox:

    /etc/init.d/vboxdrv setup

4.) Add yourself to the “vboxusers” group and fix the SELinux Permissions:

    usermod -G vboxusers -a username
    chcon -t textrel_shlib_t /usr/lib/virtualbox/VirtualBox.so

5.) Run, and enjoy!

    VirtualBox

6.) To Get USB Support:

    1 – create a new group called “usb”;
    2 – locate file usbfs: in my case is /sys/bus/usb/drivers (I suggest to find the file with a usb device inserted;
    3 – modify file /etc/fstab inserting a line containing the right path and the number corresponding the “usb” group :
    none /sys/bus/usb/drivers usbfs devgid=503,devmode=664 0 0
    4 – command mount -a;
    5 – start VB and try…;

Source: Fedora Forums
7.) To Properly Backup the VirtualBox Machine (.vdi):
Please refer to my other page here:
How To: Properly Backup a VirtualBox Machine (.VDI)
8.) To Get Sound Working:
Highlight your virtual machine and click on the “Settings” button. Click on the “Sound” category, and then check the “Enable Sound” option. In the drop-down box, select “PulseAudio”. You should now have sound.
That’s it!

12 July 2009

File System in Linux

I see not so much people really know the difference about Linux files system. In fact there is a whole lot to it more than just generalizing the usage of each file system, they have different usage purposes and different futures that you might or might not want. The information bellow are freely available on the world wide web, and they are not special information whatsoever , meaning that anyone could find such information, but I thought a good short article about the subject will do no harm. This article will cover EXT2, EXT3, XFS and ReiserFS so no talking about UNIX file systems like UFS or any other "different" OS specific file system, so please don't bring other OS's file system discussions over here.
There will be no historical information here whatsoever, this article main purpose is to provide technical yet simple information about these various file systems to help you in the decision making process of choosing one over the other or better is mixing between them to maximize efficiency.


EXT2:
File allocation: bitmap (free space), table (meta data)
Bad blocks: table
Max file size: 2-64 TiB
Max number of files: 10^8
Max filename length: 255 bytes
Max volume size: 16-32 TiB
Allowed characters in filenames: Any byte except 'NUL' and 0x2F
Dates recorded: modification (mtime), attribute modification (ctime), access (atime)
Date range: December 14, 1901 - January 18, 2038
Date resolution: 1s
File system permission: POSIX
Transparent compression: NO (available through patches)
Transparent encryption: NO
Supported OS's: Linux, BSD, Windows (through an IFS), Mac OS X

EXT3:
Directory contents: table, H tree with dir_index* enabled
File allocation: bitmap (free space), table (meta data)
Bad block: table
Max file size: 16 GiB - 2 TiB
Max number of files: Variable*
Max filename length: 255 bytes
Max volume size: 2-32 TiB
Allowed characters in filenames: Any byte except 'NUL' and 0x2F
Dates recorded: modification (mtime), attribute modification (ctime), access (atime)
Date range: December 14, 1901 - January 18, 2038
Date resolution: 1s, Nanosecond (using undocumented big i-node)
Attributes: No-atime, append-only, synchronous-write, no-dump, h-tree (directory), immutable, journal, secure-delete, top (directory), allow-undelete
File system permission: Unix permissions, ACLs and arbitrary security attributes (Linux 2.6 and later)
Transparent compression: NO
Transparent encryption: NO (provided at the block device level)
Supported OS's: Linux, BSD, Windows (through an IFS)

ReiserFS:
Directory contents: B tree
File allocation: bitmap
Max file size: 8 TiB
Max number of files: 2^32
Max filename length: 4032 bytes, limited to 255 by Linux VFS (Virtual File System)
Max volume size: 16 TiB
Allowed characters in filenames: Any byte except 'NUL' and 0x2F
Dates recorded: modification (mtime), attribute modification (ctime), access (atime)
Date range: December 14, 1901 - January 18, 2038
Date resolution: 1s
Forks: Extended attributes
File system permission: Unix permissions, ACLs and arbitrary security attributes
Transparent compression: NO
Transparent encryption: NO
Supported OS's: Linux

XFS:
Directory contents: B tree
File allocation: B tree
Max file size: 8 EiB minus one byte (on x64 bit system) 16 TiB (on x32 bit system)
Max filename length: 255 bytes
Max volume size: 16 EiB
Allowed characters in filenames: Any byte except 'NULL'
Dates recorded: modification (mtime), attribute modification (ctime), access (atime)
Date resolution: 1ns
Attributes: YES
File system permission: YES
Transparent compression: NO
Transparent encryption: NO (provided at the block device level)
Supported OS's: IRIX, Linux, FreeBSD (experimental)

As we see here there are different structures, and they differ between the B trees and H trees, the B tree data structure keeps data sorted and allows searches, insertions, and deletions in logarithmic amortized time, it is commonly used in databases and file systems. In the other hand we have the H trees structure which is commonly used in VLSI as a clock distribution network (Basically it's a revised version of a B tree data structure for larger directories).

* dir_index is an option that allows indexing which is turned on by typing the command tune2fs -O dir_index /dev/hdXXX.
* If V is the volume size in bytes, then the default number of inodes is given by V/(2^13) or the number of blocks, whichever is less. And the minimum is V/(2^23). The max number of subdirectories in one directory is fixed to 32000.

I think the information above are self explanatory, so I don't have comments on this part of information except to get your attention on the difference between 'NUL' and 'NULL', they are in fact different and mean totally different things, the 'NUL' is a string termination character while 'NULL' means NO thing.

10 June 2009

Some Type of Linux User

In Linux world, there are many type of Linux User based on how they used Linux and contribute to linux community. Some of them categorized into bellow classification :

The Computer User:
This is a person that feels no emotional ties to FOSS/Linux. The computer is only tool to get the job done and they use Linux because they need the tool which can be found in linux for the job they are trying to accomplish. This type of user may have no idea of what FOSS or Linux is. They glad to just know that their computer works when they need it.

The Dual Booter:
This is the person who typically has some computer savvy about them. Some of them are person who decided to give Linux a try because of an interesting article about a new Linux distro or because they know a Linux geek who recommended it. They might make a forum post or two to try and solve an issue they are having, but odds are if the distro doesn't "just work" they will start going on about how Linux "isn't ready for the average user" or "will never make it as a desktop operating system".

Linux Advocate:
This type of person is someone who uses Linux because they feel it is a superior, secure, or more stable operating environment. Typically this is someone who knows about the computer a bit and isn't afraid to post on a forum asking a question or get their system up and running. They are typically willing to use restricted codecs and closed source video drivers to get the performance and functionality they need out of their system. While it is not uncommon for them to recommend Linux to their family and friends, most times they will even help them get it setup, they realize that some people are happy with Windows and they acknowledge this.

FOSS Extremist:
This type is someone who they use Linux not only because it is fast, secure, and stable, but because it is FOSS. Usually they know the ins and outs of their system. If their hardware does not work right "out of the box" on their favorite distro they are willing to spend hours pouring over manuals and help pages to get it working. They almost constantly preach about the evils of Windows and Apple and take every chance they get to convert those they know to Linux or and FOSS operating system.

24 May 2009

Commonly used Linux/Unix commands

Bellow are some of commonly used Linux shell command which usually used every day



Starting and Ending

login: `Logging in'
ssh: Connect to another machine
logout: `Logging out'

File Management


emacs: `Using the emacs text editor'
mkdir: `Creating a directory'
cd: `Changing your current working directory'
ls: `Finding out what files you have'
cp: `Making a copy of a file'
mv: `Changing the name of a file'
rm: `Getting rid of unwanted files'
chmod: `Controlling access to your files'
cmp: Comparing two files
wc: Word, line, and character count
compress: Compress a file

Communication


e-mail: `Sending and receiving electronic mail'
talk: Talk to another user
write: Write messages to another user
sftp: Secure file transfer protocol

Information


man: Manual pages
quota -v: Finding out your available disk space quota
ical: `Using the Ical personal organizer'
finger: Getting information about a user
passwd: Changing your password
who: Finding out who's logged on

Printing


lpr: `Printing'
lprm: Removing a print job
lpq: Checking the print queues

Job control


ps: `Finding your processes'
kill: `Killing a process'
nohup: Continuing a job after logout
nice: Changing the priority of a job
&: `What is a background process?'
Cntrl-z: Suspending a process
fg: `Resuming a suspended process

24 April 2009

How to Add DNS in Linux using shell script

If you want to add DNS server in linux. The fastest way is using shell script.
Here is fastest way to add DNS server in Linux

edit /etc/resolve.conf with your favorite editor (gedit,nano,vim, vi...etc)

for each name server add
nameserver <ip>

06 March 2009

How to make partition in Linux using Gparted

If you want to make partition in Linux, you can use Gparted for that.
Here is how to make partition using gparted

  1. Downloaded Gparted Live 0.3.1-1 Burned as ISO using K3B.
  2. Booted into XP and verified that I had all my music, videos, and documents backed up to the fat32 partition. Deleted all copies on ntfs partition. Opened add remove programs and uninstalled all the Windows versions of programs that I also have on Ubuntu and all programs that I rarely used. Retained all programs that I might use if I ever boot into XP again. Opened and ran disk cleanup wizard. Ran disk defragmenter about five times.
  3. Rebooted with Gparted Live disk. Wow! Amazing program. Only 85MB on the disk and loads linux to ram in less than two minutes! Resized ntfs from 97GB to 40GB.
  4. Decided to use some of that 50GB of free space to try Edgy Eft Knot3. Downloaded, burned as ISO (K3B again), and rebooted. Booted live Edgy disk, clicked the install icon, and ran into a little problem. My disk already had four primary partitions and the newly freed space was not in the extended partition. Was unable to proceed using installation partitioner.
  5. Rebooted with Gparted Live disk. First, I moved my second primary partition (/home) as far left as I could enlarging it by about 10GB as I did. This placed the free space next to my extended partition. Second, I enlarged the extended partition to encompass the free space.

05 February 2009

How to check IP In Linux

In Linux, you can use Shell Command to find or get IP address
It displays Ethernet IP address, Mac address, subnet mask and other information.
Type /sbin/ipconfig command to display IP address:

Code:

$ /sbin/ifconfig

Code:

$ /sbin/ifconfig | less


Under Solaris and other Unixish oses you may need to type ifconfig command with -a option as follows:

Code:

$ /sbin/ifconfig -a
Output sample

Code:

eth0     Link encap:Ethernet  HWaddr 00:0F:EA:91:04:07
  inet addr:192.168.1.2  Bcast:192.168.1.255  Mask:255.255.255.0
  inet6 addr: fe80::20f:eaff:fe91:407/64 Scope:Link
  UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  RX packets:31167 errors:0 dropped:0 overruns:0 frame:0
  TX packets:26404 errors:0 dropped:0 overruns:0 carrier:0
  collisions:0 txqueuelen:1000
  RX bytes:38338591 (36.5 MiB)  TX bytes:3538152 (3.3 MiB)
  Interrupt:18 Base address:0xc000

03 January 2009

Package Management in Linux

Here are some package managemen in Linux

Synaptic
Synaptic is a graphical user interface (GUI) for managing software packages on Debian-based distributions. If you are using Debian or Ubuntu you will easily find Synaptic in the System Tools menu or in the Administration menu. Synaptic uses the GTK graphic libraries . So, if you are using GNOME on your debian-based distro you will probably have Synaptic installed as well. Synaptic is a graphical package management program for apt. It provides the same features as the apt-get command line utility with a GUI front-end based on Gtk+. http://www.debianadmin.com/

Yum
Yum is the easiest way to keep all programs up to date. It downloads and installs the latest version of a program. A single command can update all software installed, including third-party software, security updates and operating system. It can do the updating automatically in the night. In this howto, we install yum and make it do all the above.
Yum is similar to, but better than apt, apt4rpm, windows update, up2date, yast and many other package managers I have seen. Yum works in a safe, standardized way. It uses rpm (Red Hat package manager) for installing programs. Authenticity of packages is checked with strong gpg encryption. Package repositories are just folders on a web server.