Kategorie: Linux

PHP Installation 8 Debian 11

The following tutorial describes how to install PHP 8 In the Debian system 11

We will complete it in a few minutes with just a few commands.

We start the terminal and update the system:

apt-get update -y

We install the necessary packages with the command:

apt-get install ca-certificates apt-transport-https software-properties-common -y

The next step is to add the repository and download the GPG key

echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" | tee /etc/apt/sources.list.d/sury-php.list
wget -qO - https://packages.sury.org/php/apt.gpg | apt-key add -

We are updating packages:

apt-get update -y

We install php 8

apt-get install php8.0

Command php -v it should show us already installed php 8

PHP 8.0.10 (cli) (built: Aug 26 2021 16:06:19) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.10, Copyright (c) Zend Technologies
    with Zend OPcache v8.0.10, Copyright (c), by Zend Technologies

We install the necessary packages for php 8

apt-get install php php-common php-xml php-gd php-mbstring php-tokenizer php-json php-bcmath php-zip -y

Edit the php.ini file

nano /etc/php/8.0/apache2/php.ini

And we're making the following changes:

upload_max_filesize = 32M 
post_max_size = 48M 
memory_limit = 256M 
max_execution_time = 600 
max_input_vars = 3000 
max_input_time = 1000

If we want to upgrade php from 7.4 na 8.0 we follow these steps:

Disabling php 7.4

a2dismod php7.4

Launch php 8.0

a2enmod php8.0

We reload the apache server:

systemctl restart apache2

Linux

Udostępnij
Opublikowane przez
Linux

Recent posts

KeePass2 2.52 w Ubuntu 22.04

The guide below describes how to install KeePass on Ubuntu. Całość wykonamy za pomocą kilku poleceń

2 years temu

Installing Master PDF editor in Ubuntu 22.04

Master PDF Editor is a comprehensive PDF program, which includes many features. Oprócz tworzenia i edycji

2 years temu

iotop - memory monitoring

Iotop jest prostym narzędziem dla systemów Uniksowych umożliwiającym monitorowanie użycia dowolnego nośnika pamięci flash/hdd/ssd w

2 years temu

Run multiple commands in one cron job

You can separate two or more commands with semicolons (;), Semicolon (;): służy do oddzielania

2 years temu

Changing the exif data of a photo in the Linux terminal

Poniższy poradnik opisuje w jaki sposób za pomocą konsoli możemy dokonać edycji danych zdjęcia exif.

2 years temu

Installing Rocket.Chat Server on Rocky Linux 8

The following guide describes how to install Rocket.Chat on Rocky Linux 8 Całość bardzo prosto zainstalujemy

2 years temu