Monday, March 30, 2015

20 things to do after installing Elementary OS 0.2 Luna

Elementary OS is another Linux distribution, which is derived from Ubuntu. This is good for old Desktops. But the twenty different things have to be done after installing this.
Refer the following link:

Monday, March 23, 2015

How to install software or upgrade from an old unsupported release?

Please check the following link for installing software or upgrading from an unsupported release (Eg: Ubuntu 9.04)

Create Wifi Hotspot in Ubuntu Laptop For Android Phones

Type these following commands to make you Ubuntu 14.04 (derived) flavor for activating Wifi hot spot in your laptop or desktop (it should have wifi card in it)

#sudo add-apt-repository ppa:nilarimogard/webupd8

#sudo apt-get update

#sudo apt-get install ap-hotspot

First uninstall the buggy hostapd in Ubuntu 14.04 via:

#sudo apt-get remove hostapd

For 64-bit system:

#cd /tmp && wget && sudo dpkg -i hostapd*.deb && sudo apt-mark hold hostapd

For 32-bit system:

#cd /tmp && wget && sudo dpkg -i hostapd*.deb && sudo apt-mark hold hostapd

Once installed, execute below command to configure your wifi hotspot:

#sudo ap-hotspot configure

Finally start the wireless hotspot via:

#sudo ap-hotspot start

To stop the wireless hotspot, execute this command in Ubuntu terminal:

#sudo ap-hotspot stop


Please report issues at:

Friday, March 20, 2015

Find the inactive users for a particular period of time

#lastlog -t 10000 > temp1; lastlog -t 10 > temp2; diff temp1 temp2;
for i in `sudo lastlog | grep -v 'pts' | awk -F ' ' '{print $1}'`; do sudo more /etc/passwd |grep /bin/bash |awk -F: '{print $1}' |grep $i; done

How to unlock the password of an user

#passwd -u username
eg: #passwd -u pnaprasanna

Wednesday, March 18, 2015

Disk usage check simple command

#du –h /mnt
#du -kh /mnt

How can I find the number of files and inodes on a file system?

$ find / -type f | wc –l
$ df --inodes / /home
Filesystem            Inodes   IUsed   IFree IUse% Mounted on
/dev/sda1            3981312  641704 3339608   17% /
/dev/sda8            30588928  332207 30256721    2% /home
$ sudo find / -xdev -print | wc -l
$ sudo find /home -print | wc -l
$ sudo find /home -type f -print | wc -l

Slackware package manager - how to install applications

Slackware is the oldest Linux still being maintained, it is light, simple, and stable.
It is not too easy to maintain, specially because most Linux users now a day (me included) are accustomed to package manager tools that take care of dependency resolution. In Slackware the user is the one who should resolve this, and install any package or library needed.
Slackware is a free and open source operating system. It was one of the earliest operating systems to be built on top of the Linux kernel and is the oldest currently being maintained. Slackware was created by Patrick Volkerding of Slackware Linux, Inc. in 1993. The current stable version is 13.1, released on May 24, 2010.
Slackware’s package management system can install, upgrade, and remove packages from local sources, but makes no attempt to track or manage dependencies, relying on the user to ensure that the system has all the supporting system libraries and programs required by the new package. If any of these are missing, there may be no indication until one attempts to use the newly installed software.
The “normal” way to install and maintain software on Slackware is using:
·         installpkg: To install new software, you should previously install the dependencies.
·         upgradepkg: To upgrade an installed package to a new version
·         removepkg: To remove an installed package you do not want.
Another good practice is to download sources and configure, compile and install by yourself, you will be warned about missing dependencies, at the compiling time.
There other tools that really help the new-to-slackware user. These are the ones that are helping me.
·         slackpkg
·         slapt-get
You may have it already installed on your Slackware, but if not you can go to slackpkg project home page, to see how to install and use it.
What I really like about this tool, is its ability to find the package you need to install
For example, if you need the glibc library, you can search for the packages that contains it:
sudo slackpkg file-search glibc
You will something like this:
Looking for glibc in package list. Please wait... DONE
The list below shows the packages that contains "glibc" file.
[ installed ] - glibc-solibs-2.11.1-i486-3
[ installed ] - glibc-zoneinfo-2.11.1-noarch-3
[ installed ] - man-pages-3.24-noarch-1
[ installed ] - glibc-2.11.1-i486-3
[ installed ] - glibc-i18n-2.11.1-i486-3
[ installed ] - glibc-profile-2.11.1-i486-3
[uninstalled] - mutt-
You can search specific packages using "slackpkg search package".
This is very handy, specially if you are compiling your own software from sources.
slapt-get is a command line utility that functions in a similar way to APT. While slapt-get does provide a framework for dependency resolution, it does not provide dependency resolution for packages included within the Slackware distribution. However, several community package sources and Slackware based distributions take advantage of this functionality
This is also a very good package manager, and works more or less likeslackpkg, you may want to read slapt-get FAQ, to better understand it.
There are some other options and package managers for Slackware, none of them as “easy” as apt-get, yum, pacman or even emerge. But that is exactly what makes slackware a good Linux distribution for some applications.

I think is a great option for servers, where you want to have full control of what is running on your server, and do not delegate that task to a package manager.

Installing security updates in Red Hat / CentOS

Installing only security updates
# yum install yum-security
How Do I Display Available Security Updates?
# yum list-security
# yum --security check-update
# yum list-security bugzillas
How Do I Install All The Security Updates Only?
# yum update –security

NFS permission denied problem (run this command)

#exports -av
check this permission as well

RHEL 5 to RHEL 6 upgradation

Unfortunately, Red Hat does not support in-place upgrades from RHEL5 to RHEL6, and recommends a fresh install. Such an upgrade is possible, however, they are not recommended by Red Hat and result in such issues as unresponsive GUI login windows and other, possibly unknown defects.
#yum upgrade is possible

Ubuntu vs Redhat

1. Ubuntu is free to use while Red Hat is not.
2. Ubuntu uses the dpkg (Debian) package system while Red Hat uses RPM package manager.
3. Ubuntu primarily aims for better usability and has become exceedingly popular for desktop use. Red Hat, on the other hand, is marketed for enterprise use.
4. Red Hat is closely associated to Fedora, another popular type of Linux distribution.
5. Red Hat is made by Red Hat Inc which is founded by Young and Ewing while Ubuntu is headed by Shuttleworth, owner of Canonical Ltd.
6. Due to its differing packaging system, Ubuntu is expected to be more flexible and easier to implement.

Ext2, Ext3 and Ext4 file system features

Ext2 – file system
§  Ext2 stands for second extended file system.
§  It was introduced in 1993. Developed by Rémy Card.
§  This was developed to overcome the limitation of the original ext file system.
§  Ext2 does not have journaling feature.
§  On flash drives, usb drives, ext2 is recommended, as it doesn’t need to do the over head of journaling.
§  Maximum individual file size can be from 16 GB to 2 TB
§  Overall ext2 file system size can be from 2 TB to 32 TB
Ext3 – file system
§  Ext3 stands for third extended file system.
§  It was introduced in 2001. Developed by Stephen Tweedie.
§  Starting from Linux Kernel 2.4.15 ext3 was available.
§  The main benefit of ext3 is that it allows journaling.
§  Journaling has a dedicated area in the file system, where all the changes are tracked. When the system crashes, the possibility of file system corruption is less because of journaling.
§  Maximum individual file size can be from 16 GB to 2 TB
§  Overall ext3 file system size can be from 2 TB to 32 TB
§  There are three types of journaling available in ext3 file system.
§  Journal – Metadata and content are saved in the journal.
§  Ordered – Only metadata is saved in the journal. Metadata are journaled only after writing the content to disk. This is the default.
§  Writeback – Only metadata is saved in the journal. Metadata might be journaled either before or after the content is written to the disk.
§  You can convert a ext2 file system to ext3 file system directly (without backup/restore).
Ext4– file system
§  Ext4 stands for fourth extended file system.
§  It was introduced in 2008.
§  Starting from Linux Kernel 2.6.19 ext4 was available.
§  Supports huge individual file size and overall file system size.
§  Maximum individual file size can be from 16 GB to 16 TB
§  Overall maximum ext4 file system size is 1 EB (exabyte). 1 EB = 1024 PB (petabyte). 1 PB = 1024 TB (terabyte).
§  Directory can contain a maximum of 64,000 subdirectories (as opposed to 32,000 in ext3)
§  You can also mount an existing ext3 fs as ext4 fs (without having to upgrade it).
§  Several other new features are introduced in ext4: multiblock allocation, delayed allocation, journal checksum. fast fsck, etc. All you need to know is that these new features have improved the performance and reliability of the filesystem when compared to ext3.

§  In ext4, you also have the option of turning the journaling feature “off”.

Comparison chart between ext3 and ext4

Filesystem limit
1EB (1 EB = 1024 PB, 1 PB = 1024 TB)
File limit
Default inode size
128 bytes
256 bytes
Block Mapping
Time Stamp
Sub Directory Limit
In-core reservation
For extent file
Directory Indexing
Delayed Allocation
Multiple Block Allocation

Saturday, March 14, 2015

Avidmux installation procedure in Ubuntu 14.04 derivatives

Type the following commands to install Avidemux video editor

#sudo add-apt-repository ppa:rebuntu16/avidemux+unofficial

#sudo apt-get update

#sudo apt-get install avidemux2.6-gtk avidemux2.6-qt4

Audacity installation procedure in Ubuntu 14.04 derivations

Open terminal and type the following command for installing audio editor audacity
#sudo apt-get install audacity

Thursday, March 12, 2015

VLC installation procedure in RHEL 7

Follow these steps to install VLC player in RHEL 7
#rpm -Uvh

#yum update
#yum install vlc

Tuesday, March 10, 2015

Airtel 4G dongle installation method in Pinguy 14.04

1. Copy the Linux directory to hard disk.
2. #chmod +x *.*
because, the file is for Linux installer has not have the permission to execute.
3. #./install_linux
4. It requires a reboot to show the Airtel 4G interface.