Sometimes, you get in a situation where you need to take a snapshot of the process and use it later in the same state. We call this operation of saving a process state to use it later in Linux Checkpointing. This operation is done by taking a running process and saving it into a file, and then later, you can quickly launch the process again without losing its state. To make it easier to understand, let’s say you have a process doing some calculations. To prevent data loss if the system crashes or when you reboot the machine, you save ... Read More
Bash script is a scripting language like other languages that have an extension and a way to interpret it. To interact with the operating system through the command line, commands are used. There are a lot of commands on Linux, and new commands are added regularly. However, all these commands have a common way of working. All commands consist of three parts: the command itself, its parameters, and arguments. Bash Script File A bash script file is a file that contains a sequence of commands put together to do a certain task. If you have a lot of commands, it ... Read More
Sometimes, we need to run an automated process, and for this, we use a script that runs continuously in the background. These types are called "daemons" in Linux. These daemons allow us to run independently from the terminal session. This means that the script will keep running even if we close the session. In this tutorial, we will go through how we can turn a bash script into a daemon. What is a Daemon? A daemon is just a program or process that runs in the background continuously without needing any interaction from the user. In your day-to-day Linux tasks, ... Read More
There is no doubt that the idea of losing an important file or deleting it unintentionally is certainly annoying and almost all of us have been in the same situation, especially if the files are very important, whether they are work files, personal photos or videos that you cannot do without and want to recover. If you are exposed to this problem, do not worry. There are many solutions and programs dedicated to recovering files, especially if you are using the famous Linux distribution. There are also many diverse and free programs dedicated to all famous distributions. Linux ... Read More
XML stands for Extensible Markup Language. It's a widely used format that is used to exchange data between systems. Many applications are based on XML as their configuration files. Even the very well-known document application, Office, is based on XML. What makes XML very popular is that it is written in plain text, which makes it easy to work with and also independent. It can be used in any programming language. Unlike HTML and other markup languages, XML doesn't come with predefined tags that you need to remember and use. With XML, you can use tags of your choice ... Read More
CSV files are a common file format that we use on the Internet a lot. They are basically a file type that consists of lines, with each line considered a row in a simple table. As the name suggests, CSV (Comma-Separated Values) means that data in each line is separated by commas. CSV files are just plain text that we can view and edit in any editor. The common fields we see using this type of file are in spreadsheets, databases, storing configuration data, and data exchange between APIs. In Linux, there are many ways to parse a file like ... Read More
A command line or terminal is an important component of the Linux operating system, as it allows for inclusive administration and management of the operating system as a whole. Even if we are talking about a Linux distribution that uses a graphical interface, you will still need a terminal to unleash all the power and potential of Linux. Linux provides a "shell" to work on the command line. The shell is a command interpreter responsible for executing commands based on what you enter on the command line. The most popular shell is bash (short for "Bourne Again Shell, " ... Read More
In SQL databases, it is often necessary to retrieve the list of table names within a database to understand the structure or to perform the certain operations. Each SQL-based database system offers specific ways to query its metadata to extract the table names. In this article, we will explore how to get the names of tables in popular relational database systems including the MySQL, SQL Server, PostgreSQL and Oracle. We will cover the built-in SQL queries and functions that are commonly used for this task. Need to Retrieve Table Names? Database Exploration: When working with ... Read More
Arrays are linear data structures used to handle data in programming. Sometimes while dealing with arrays we need to add new elements to an existing array.In this article, we will discuss several methods to add elements to the end of an array in PHP, complete with code examples, outputs, and an analysis of the time and space complexity of each approach. Following are different approaches to adding elements to an array − Using square brackets [] We add an element to the end of an array in PHP is by using square brackets []. This syntax is only suitable when ... Read More
In order to delete the middle element of a stack, then first we need to remove the elements above the middle element. After removing the middle element, we restore the elements above it to maintain the original sequence. We can achieve this using a recursive approach, as explained step-by-step below. We cannot delete the middle element of the stack directly because, according to the stack property, we can perform only push and pop operations on the top of the stack. Steps to Delete the Middle Element of a Stack Step 1: Determine the Position of the Middle Element, First ... Read More
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP