Skip to main content
Maher Sakka's Blog
Main navigation
  • Home
  • Contact me
Language switcher
  • English
  • عربي
Breadcrumb
  1. Home
  2. Blog
  3. Linux

Linux

How to know which ini configuration files are loaded with PHP

How to know which ini configuration files are loaded with PHP

Tags
  • Servers
  • Linux

To list all the ini configuration files loaded with PHP in command line, you have to type the command:

php --ini

All the configuration files will be listed. ex :

  • Read more about How to know which ini configuration files are loaded with PHP
How to prevent search engines from indexing your staging server websites

How to prevent search engines from indexing your staging server websites

Tags
  • Servers
  • SEO
  • Linux

Here are the configurations to prevent search engines (Google, Bing, etc.) from indexing all websites on your server using global configuration for both web servers Apache and Nginx:

Prevent search engines indexing in Apache

Add the following line in httpd.conf or apache2.conf:

  • Read more about How to prevent search engines from indexing your staging server websites
How to find recently modified files in Linux

How to find recently modified files in Linux

Tags
  • Linux

As a Linux user or administrator, you often need to track file changes—whether to debug an application, monitor system activity, or investigate a security breach. The find command is a powerful tool for this, and one of its useful options is -ctime n, which helps locate files modified within a specific timeframe.

  • Read more about How to find recently modified files in Linux
How to determine which Linux distribution and kernel version you are running

How to determine which Linux distribution and kernel version you are running

Tags
  • Linux

When connecting to a Linux server, we need to know the name of the running Linux distribution, its version number, and the kernel version number.

This is often done to determine:

  • Read more about How to determine which Linux distribution and kernel version you are running
How to compress and decompress files in Linux with ZIP

How to compress and decompress files in Linux with ZIP

Tags
  • Linux

To compress a directory in Linux you can use the zip command:

zip -r output_file.zip folder

You can compress multiple directories too by adding the folders' names :

zip -r output_file.zip folder1 folder2 folder3

To decompress the zipped file, use the command unzip:

  • Read more about How to compress and decompress files in Linux with ZIP
How to compress and extract TAR files in Linux

How to compress and extract TAR files in Linux

Tags
  • Linux

To compress a directory in Linux, you can use the tar command:

tar -zcvf file.tar.gz folder

To exclude a specific folder or files, use the –exclude= option with the folder name:

tar -zcvf file.tar.gz –exclude='temp' –exclude='node_modules' folder

To decompress a file, use the -x option:

  • Read more about How to compress and extract TAR files in Linux
How to get the size of directories in Linux

How to get the size of directories in Linux

Tags
  • Linux

To get information about the total and available space on the Linux file system, you can use the df command.

df

The df command displays information about all mounted filesystems, including total size, space used, percentage usage, and mount point:

  • Read more about How to get the size of directories in Linux
How to find files that contain specific text in Linux

How to find files that contain specific text in Linux

Tags
  • Linux

To search for a specific text on a Linux system, the grep command can be used according to the following syntax:

grep -iRl "text_to_search" ./

The basic parameters are:

  • i: ignore text case (uppercase or lowercase)
  • R: search recursively in subfolders files
  • l: show file names instead of parts of the file contents

The folder path to be searched is specified last.

  • Read more about How to find files that contain specific text in Linux
Linux
Tags
  • Laravel
  • Linux
  • Drupal
  • Database
  • Tips & Tricks
  • Mobile
  • Servers
  • SEO
Recent posts
  • How to bypass the "PHP Fatal error: Allowed memory size of X bytes exhausted" error in Drush
  • How to detect tables wihtout primary key in a database
  • How to know which ini configuration files are loaded with PHP
Monthly archive
  • May 2017 (2)
  • August 2018 (1)
  • October 2020 (1)
  • August 2023 (1)
  • July 2024 (2)
  • November 2024 (1)
  • July 2025 (10)
  • October 2025 (6)
  • December 2025 (1)
Projects
  • elmanager.tn
  • 365mathex.com
  • vpop.tn
  • toufoula.tn
  • writethemoney.com
  • dinartunisien.com
RSS feed

mahersakka.com © 2024 
Build Your IT Skills, Grow Your Wealth with Maher Sakka