How to find out why Linux is freezing

  • 01.13.2025
  • Posted in: Linux
  • 375 views

If it freezes, after rebooting, use journalctl to view logs from the previous boot before shutdown: journalctl -p 0..3 -b 1 -p 0..3 is a filter based on the priority of log entries, -b is a range of downloads, -b 0 will show only logs for the current download -b 1 for the previous one -b 0..9 for the last ten

read more

How do I make Sublime Text 4 the default text editor

  • 01.12.2025
  • Posted in: Linux
  • 441 views

After installing Sublime Text 4 , write in the terminal whereis subl My result /usr/bin/subl Next export EDITOR=/usr/bin/subl update-alternatives --install /usr/bin/editor editor /usr/bin/subl 5 Next select-editor Select the desired number and press enter. Start Sublime Text4 from the launcher as root Enter as a normal user in the terminal sudo subl Enter your password If you see an error Username is not in the sudoers...

read more

Install Sublime 4 in Debian 12

  • 01.12.2025
  • Posted in: Linux
  • 375 views

Install the GPG key: wget -qO - https://download.sublimetext.com/sublimehq-pub.gpg | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/sublimehq-archive.gpg > /dev/null Select stable version echo "deb https://download.sublimetext.com/ apt/stable/" | sudo tee /etc/apt/sources.list.d/sublime-text.list And install apt-get update apt-get install sublime-text

read more

Linux WordPress permissions after install

  • 01.11.2025
  • Posted in: Linux
  • 348 views

After the WordPress installation was not 403 Forbidden error, you need to go to the folder with the installed WordPress and change the owner of the folders and files. Now run the following commands by root user: chown www-data:www-data -R * Notice: Where www-data it's your username and group directory, like this chown username:group -R * For all folders inside the WordPress directory, set permissions to 755 find . -type...

read more

Install Opencart 3 on NGINX

In order to install Opencart 3 you must have php 7.3+ installed Also in the php.ini file you need to uncomment the following modules extension=curl.so; extension=gd.so; extension=zip.so; Note: If you don't have them on your system, install them. Replace the numbers 8.3 with your php version apt-get install -y php8.3-curl php8.3-gd php8.3-zip Restart PHP-FPM systemctl restart php8.3-fpm I want my site opencart3.com to...

read more

Set up a NGINX server for Debian 12

  • 01.10.2025
  • Posted in: Linux
  • 352 views

After installing the NGINX server, NGINX is directed to the folder /usr/share/nginx/html Let's change this path. I want my site example.com to be in a folder var/www/ Сreate a example.com folder mkdir /var/www/example.com Set folder permissions 755 chmod 755 /var/www/example.com 755 ( drwxr-xr-x ) everyone can read this directory, but only the owner can change its contents Create a new file index.php in the folder example.com touch...

read more

Install NGINX on Debian 12

  • 01.10.2025
  • Posted in: Linux
  • 415 views

Install the packages required to connect the apt repository sudo apt install curl gnupg2 ca-certificates lsb-release debian-archive-keyring Now you need to import the official key that apt uses to authenticate packages. Download the key curl https://nginx.org/keys/nginx_signing.key | gpg --dearmor \ | sudo tee /usr/share/keyrings/nginx-archive-keyring.gpg >/dev/null Check if the correct key was loaded: gpg --dry-run...

read more

Install PHP 8.3 and PHP-FPM on Debian 12

  • 01.10.2025
  • Posted in: PHP
  • 510 views

Install PHP 8.3 on Debian 12 apt update && apt install -y wget gnupg2 lsb-release wget https://packages.sury.org/php/apt.gpg && apt-key add apt.gpg echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" | tee /etc/apt/sources.list.d/php.list apt install -y php8.3 After installation check php version php -v Install PHP-FPM and Extensions If you also want to install additional modules, then first...

read more

Shutdown IBus in Debian/Ubuntu

  • 01.10.2025
  • Posted in: Linux
  • 918 views

To disable IBus you need to write in the terminal sudo dpkg-divert --package im-config --rename /usr/bin/ibus-daemon After this you need to reboot your computer To turn it back on IBus you need to write in the terminal sudo dpkg-divert --package im-config --rename --remove /usr/bin/ibus-daemon

read more

Simple script for testing the sending of mail on a local Linux server

  • 01.07.2025
  • Posted in: Linux
  • 870 views

First, create a shell script fakesendmail.sh in the folder /usr/bin/ touch /usr/bin/fakesendmail.sh Add the following script to this file: #!/bin/sh prefix="/var/www/mail" numPath="/var/www/mail" if [ ! -f $numPath/num ]; then echo "0" > $numPath/num fi num=`cat $numPath/num` num=$(($num + 1)) echo $num > $numPath/num name="$prefix/letter_$num.txt" while read line do echo $line >> $name done /bin/true Set...

read more