Found 1437 Articles for Linux

The Best Linux based OS Distributions in 2016

karthikeya Boyini
Updated on 17-Jan-2020 10:04:55

254 Views

This article helps you to know some key features of Linux Operating systems so that you are able to choose Linux for your environment. The year 2015 and the current 2016 will be a crucial year for Linux especially in the enterprise-level segment and consumer/home users. As a Linux user since 1996, I can see that the operating systems have come a long way since 20 years. We can definitely expect more exciting times with new flavors this year.Free/Open Source Server Based OS ‘Debian/CentOS’If you are looking at running a server, but needed a free or open source server version ... Read More

Text and File processing using sed Linux Commands

karthikeya Boyini
Updated on 17-Jan-2020 09:50:36

416 Views

Sed is a stream editor. A stream editor is used to participate in normal textual content transformations on an enter a file. At the same time in some approaches much like an editor which allows scripted edits (comparable to ed). sed works by means of making only one cross over on the input(s) and is more efficient. Now, let us explore more about – “Text and File processing using sed Linux Commands”.Firstly, to verify the sed version, use the following command –$ sed --vThe sample output should be like this –sed (GNU sed) 4.2.2 Copyright (C) 2012 Free Software Foundation, ... Read More

Linux Package Management with Aptitude

Sharon Christine
Updated on 17-Jan-2020 09:43:08

250 Views

Aptitude is founded by Ncurses for APT front End and debian Bundle Manager, considering the fact that it is text-based and it runs from a terminal or a CLI – command line interface. This article explains about-“Linux Package Management with Aptitude”What is APTapt is a command line package manager and provides commands for searching and managing as well as querying information about packages. It provides the same functionality as the specialized APT tools, like apt-get and apt-cache, but enables options more suitable for interactive use by default.]To get more information about APT, use the following command –$ aptThe sample output ... Read More

Linux and Unix Test Disk I/O Performance with DD Command

Sharon Christine
Updated on 17-Jan-2020 09:39:43

8K+ Views

Do you know how to check the performance of a hard drive like checking the read and write speed on your Linux operating systems? then, this article is for you!! which is basically created to provide you an overview of DD command, which is geared towards better guidance to new users and as an exploration tour for getting started to the Linux world.What is DD Command?DD is a command-line utility for Unix and Unix-like operating systems where the primary purpose is to copy a file and converting the format of the data during the process.How to Test Hard Disk using ... Read More

Difference between grep and fgrep command

Mahesh Parahar
Updated on 25-Feb-2020 06:05:24

585 Views

In any language or framework one of the most important and main feature is of searching the data. It not only denotes the performance of language but also represents in what manner the data is being stored. So specifically if we take an example of LINUX operating system there comes two of the important commands namely grep and fgrep.Both of these commands are used to search any string or regular expression in file, directory or even in multiple folders. Both these commands executes in such a way that processor starts analysing the target folder or destination and search for the ... Read More

Why should eval be avoided in Bash, and what should I use instead?

Pradeep Elance
Updated on 03-Jan-2020 07:23:05

1K+ Views

eval is a builtin command of the Bash shell which concatenates its arguments into a single string. Then it joins the arguments with spaces, then executes that string as a bash command. Below is an example of how it works.eval exampleIn the below example we take a string which has some Unix commands built into it and then apply eval to it.$ var="echo n" $ echo $var $ eval $varRunning the above code gives us the following result −echo n nAs you can see, when eval is applied the variable expands it gets executed as a command and no longer ... Read More

What are the calling conventions for UNIX & Linux system calls on i386 and x86-64

Pradeep Elance
Updated on 31-Jan-2020 12:20:25

658 Views

A system call is the fundamental interface between an application and the Linux kernel. When a Unix/Linux program does a file I/O, network data transfer or invokes some process which directly or indirectly interact with the low level instructions, then system call is involved. Making these calls usually involves using a library called glibc which contains the functions.ExamplesBelow is a list of some frequently used system calls and their purpose.Sr.NoSystem CallPurpose1chmodchange permissions of a file2chdirchange working directory3forkcreate a child process4unlinkdelete a name and possibly the file it refers toA systems programmer writes program that will not directly make the systems ... Read More

Looping through the content of a file in Bash

Pradeep Elance
Updated on 03-Jan-2020 07:15:52

6K+ Views

Often it is a requirement to read each of the line from a file using a bash script. There are various approaches to read the lines form a file. In the below example we have first described how to create a sample file and then run a script reading that sample file.Create a file to Read# Open vi Editor vi a_file.txt # Input the below lines Monday Tuesday Wednesday Thursday Friday Saturday Sunday # cat the file cat a_file.txtRunning the above code gives us the following result −Monday Tuesday Wednesday Thursday Friday Saturday SundayUsing Do-WhileIn this approach we use a ... Read More

How to convert DOS/Windows newline (CRLF) to Unix newline (LF) in a Bash script?

Pradeep Elance
Updated on 03-Jan-2020 07:12:22

1K+ Views

When we transfer files between Windows and Unix systems, often we come across with issue relating to the end of line character. This is because the EOL character in windows is not recognized as a EOL character in Unix. SO to fix this issue when a file is transferred from Windows to Unix we need to follow one of the below methods.Using dos2unixThe dos2unix command is used to convert the EOL character of windows platform to Unix platform. Most of the Unix system comes with this command pre-installed. Below we see how we can convert the file itself or save ... Read More

Linux WC Command Examples to Count Number of Lines, Words, Characters

Pradeep Elance
Updated on 31-Jan-2020 12:19:34

321 Views

The wc command also known as word count command is a fundamental command any Linux user should be aware of. It is mostly used with the l switch to do a line count, but it can actually give count of multiple things with various arguments supplied to it. Below is a list of what are those possible arguments. The we will see examples on each of them.Sr.NoCommandUsage1wc -cDisplay number of bytes2wc -mDisplay number of characters3wc -wDisplay number of words4wc -lDisplay number of lines5wc -LDisplay length of longest lineLets consider the below file for our examples.ubuntu@ubuntu:~$ cat inspire.txt Mastering anything needs ... Read More

Advertisements