Found 41 Articles for Unix

Difference between Linux and Unix

Mahesh Parahar
Updated on 31-Oct-2023 03:53:47

17K+ Views

LinuxLinux is an open source multi-tasking, multi-user operating system. It was initially developed by Linus Torvalds in 1991. Linux OS is widely used in desktops, mobiles, mainframes etc.UnixUnix is multi-tasking, multi-user operating system but is not free to use and is not open source. It was developed in 1969 by Ken Thompson team at AT&T Bell Labs. It is widely used on servers, workstations etc. Following are the important differences between Linux and Unix.Following are the important difference between Linux and Unix.Sr. No.KeyLinuxUnix1DevelopmentLinux is open source and is developed by Linux community of developers.Unix was developed by AT&T Bell labs ... Read More

How to use ansible for setting up production elasticsearch servers with cluster

Samual Sam
Updated on 18-Oct-2019 06:40:48

214 Views

In this article, we will learn how to use Anisble to configure and install production Elastic Search cluster on CentOS7 which ensures that the Elasticsearch nodes will be secure from outside network .we will use VPN services to connect to the clusters.Elasticsearch is a very popular open source search, server which can be used for real-time distributed search and analysis of the data for better performance, stability and for scalability we need the Elasticsearch to be deployed across multiple servers as a cluster.PrerequisitesWe need a minimum of three CentOS 7 server environments with private networking since the Elasticsearch cluster needed ... Read More

Init process on UNIX and Linux systems

Arnab Chakraborty
Updated on 11-Oct-2019 13:28:00

6K+ Views

Init is the parent of all processes, executed by the kernel during the booting of a system. Its principle role is to create processes from a script stored in the file /etc/inittab. It usually has entries which cause init to spawn gettys on each line that users can log in. It controls autonomous processes required by any particular system.After reading this file, how the system should be set up in each runlevel is determined by init and also set default runlevel. Init starts all background process after setting default runlevel for the system.RunlevelsRunlevel, a software configuration of the system which allows ... Read More

What are Named Pipes or FIFO in Linux/Unix systems?

Arnab Chakraborty
Updated on 11-Oct-2019 13:23:28

2K+ Views

Pipes were meant for communication between related processes. We Cannot use pipes for unrelated process communication. Then to achieve unrelated processes communication, the simple answer is Named Pipes. Even though this works for related processes, it gives no meaning to use the named pipes for related process communication.Unlike pipe, we can use single named pipe that can be used for two-way communication (communication between the server and the client, plus the client and the server at the same time) as Named Pipe supports bi-directional communication.Another name for named pipe is FIFO (First-In-First-Out). Let us see the system call (mknod()) to ... Read More

Windows Anonymous Pipe

Arnab Chakraborty
Updated on 11-Oct-2019 12:18:27

769 Views

Windows anonymous pipes are actually Ordinary pipes, and they behave similarly to their UNIX counterparts: they are unidirectional and employ parent-child relationships between the communicating processes. In addition, reading and writing to the pipe can be accomplished with the ordinary ReadFile() and WriteFile() functions. The Windows API use CreatePipe() function for creating pipes, which is passed four parameters. The parameters provide separate handles forreading andwriting to the pipeAn instance of the STARTUPINFO structure, used to specify that the child process is to inherit the handles of the pipe.the size (in Bytes) of the pipe may be specified.Windows requires the programmer ... Read More

Is there any whoami function or command in MySQL like UNIX?

George John
Updated on 25-Jun-2020 13:16:47

540 Views

There is no whoami function in MySQL. The whoami can be used to know the current user in UNIX. Use user() or current_user() function from MySQL for the same purpose.The following is the output.+-----------+ | version() | +-----------+ | 8.0.12    | +-----------+ 1 row in set (0.00 sec)Case 1  −Using CURRENT_USER() function.The query to know the current user is as follows.mysql> select current_user();The following is the output.+----------------+ | current_user() | +----------------+ | root@%         | +----------------+ 1 row in set (0.00 sec)Case 2 − Using USER() function.The query is as follows −mysql> select user();The following is ... Read More

Process Synchronization in Linux

Kristi Castro
Updated on 24-Jun-2020 12:19:48

3K+ Views

Process synchronization in Linux involves providing a time slice for each process so that they get the required time for execution.The process can be created using the fork() command in Linux. The creating process is called the parent process and the created process is the child process. A child process can have only one parent but a parent process may have many children. Both the parent and child processes have the same memory image, open files and environment strings. However, they have distinct address spaces.A diagram that demonstrates the fork() command is given as follows −Orphan ProcessesThere are some processes ... Read More

What are Shell Commands?

Kristi Castro
Updated on 22-Jun-2020 15:49:49

8K+ Views

The shell is the command interpreter on the Linux systems. It the program that interacts with the users in the terminal emulation window. Shell commands are instructions that instruct the system to do some action.Some of the commonly used shell commands are −basenameThis command strips the directory and suffix from filenames. It prints the name of the file with all the leading directory components removed. It also removes a trailing suffix if it is specified.Example of basename is as follows −$ basename country/city.txtThis gets the name of the file i.e. city which is present in folder country.city.txtcatThis command concatenates and ... Read More

Different types of system calls

David Meador
Updated on 02-Sep-2023 11:38:28

66K+ Views

The interface between a process and an operating system is provided by system calls. In general, system calls are available as assembly language instructions. They are also included in the manuals used by the assembly level programmers.System calls are usually made when a process in user mode requires access to a resource. Then it requests the kernel to provide the resource via a system call.Types of System CallsThere are mainly five types of system calls. These are explained in detail as follows −Here are the types of system calls −Process ControlThese system calls deal with processes such as process creation, ... Read More

Advantages of using Loadable Kernel Modules

Kristi Castro
Updated on 22-Jun-2020 15:06:46

1K+ Views

Loadable kernel modules in an operating system is an object file that contains code to extend the running kernel, which is also known as the base kernel. The loadable kernel modules are used to add support for file systems, hardware, system calls etc.A figure that shows the loadable modules of the operating system is as follows −Advantage of Loadable Kernel ModulesAn operating system would have to include all the systems that provided all anticipated functionalities in the base kernel if there were no loadable modules. This would lead to wastage of memory as most of those systems would not be ... Read More

Advertisements