Compress or decompress files in Linux environments

Introduction In some circunstances it’s not easy to know the commands which exist to compress or decompress files in Linux (and Unix) environments. In this posts, I have wrote all the commands I have used for this. File Types TAR files Pack: tar -cvf file.tar file1 file2 file3 Unpack: tar -xvf file.tar See content: tar -tf file.tar GZ files Compress: gzip -9 file Decompress: gzip -d file BZ2 files Compress: bzip2 file Decompress: bzip -d file.bz2 TGZ (or TAR.GZ) files (TAR+GZIP) Compress+Pack: tar -czf file.tgz file1 file2 file3 Decompress+Unpack: tar -xvzf file.tgz See content: tar -tzf file.tgz TAR.BZ2 files (TAR+BZIP) Compress+Pack: tar -c files | bzip2 > fileo.tar.bz2 Decompress+Unpack: bzip2 -cd file.tar.bz2 | tar -xv See content: bzip2 -cd file.tar.bz2 | tar -t ZIP files Compress+Pack: zip file.zip file1 file2 file3 Decompress+Unpack: unzip file.zip RAR files Compress+Pack: rar -a file.rar file1 file2 file3 Decompress+Unpack: rar -x file.rar See content: rar -l file.rar

November 15, 2022 · 1 min · Yvoictra
Monitor Ubuntu Server with Grafana and Prometheus

How to Monitor an Ubuntu Server with Grafana and Prometheus

Grafana is an open source metric analytics & visualization tool which can help us to monitor the system with a nice Dashboard. Installing Grafana Grafana is available in the APT packages repository, however it could not be the latest version, so we’ll use the official Grafana repository. First, it is needed to install the software needed before install Grafana. sudo apt install -y apt-transport-https sudo apt install -y software-properties-common wget ...

November 13, 2022 · 3 min · Yvoictra
Sendinblue SMTP relay host

Configure Postfix to send e-mail using Sendinblue as SMTP server

Introduction Some time ago I tried to configure a SMTP server in a host in the cloud, but because of some restrictions, the emails from that server were bounced. The problem was that the hosting provider didn’t configure the PTR DNS entries (more about DNS PTR entries) for some kind of hostings. When this happens the best solution is to use a SMTP relay server, by this way that server is in charge of the final delivery of the emails. There are some services such us Sendinblue which offers 300 mails per day in the free plan. I believe it’s enough for a normal use of a mail server. ...

November 11, 2022 · 3 min · Yvoictra
How to set up Wi-Fi on Debian

How to set up Wi-Fi on Debian running on the Raspberry Pi 4

First off, as a prerequisite it is needed to have a CLI access to the Debian OS. It can be done using a keyboard and a screen connected to the Raspberry Pi, or using a SSH connection. If you have followed the post of how to install Debian On a Raspberry Pi 4, you should be able to access with SSH using the Ethernet (RJ45) port. Also, you should have the SSID and the password of your Wi-Fi connection, and it should be enabled the DHCP protocol in your router. ...

November 2, 2022 · 3 min · Yvoictra
Install Debian on a Raspberry Pi

How to install Debian on a Raspberry Pi

I have several Raspberry Pi and in all of them I have used the Ubuntu distro. However I also wanted to use Debian as it is one of the most used Linux distros. Besides Ubuntu is based on Debian, so I guess I will feel confortable with it. Debian vs Ubuntu Debian is more stable than Ubuntu, indeed, it is one of the most stable Linux. The releases in Debian are not as frequent as in Ubuntu, and the software updates in Debian usually don’t have the latest versions. Besides, Debian is lighter because the software it has is the basic one. ...

October 29, 2022 · 4 min · Yvoictra
Mail Server

How to Install a Mail Server in Ubuntu with Postfix

Introduction Nowadays, the knowledge to install a mail server is an important task for any System Administrator. In our case, we are going to see how to deploy a mail server with Postfix on Ubuntu. About Postfix Postfix is a free and open-source MTA (Mail Transfer Agent) which routes and delivers electronic mail (e-mails). As an SMTP server, Postfix implements a first layer of defense against spambots and malware. Can be used to send and receive e-mail. This is the default MTA software on all Linux distributions. ...

July 27, 2022 · 15 min · Yvoictra
Test bandwidth with iPerf

How to test bandwidth with iPerf

iPerf is a tool designed to test the bandwidth between two hosts using the network. It is a really simple, powerful CLI which allows generating traffic / load TCP or UDP between 2 hosts. You could use to measure the maximum bandwidth of the network between a client and a server. It can be used to do stress tests of the Ethernet, Wi-Fi or of your ISP. iPerf2 vs iPerf3, what is the difference? There has been different versions of this tool in the last years. It started ttcp from the National Laboratory for Applied Network Research (NLANR), and then it was developed iPerf (iPerf 2). iPerf3 is a new implementation from scratch, with the goal of a smaller, simpler code base, and a library version of the functionality that can be used in other programs. The functionality between iPerf2 and iPerf3 are mostly compatible, however you should know they use different ports by default. In iPerf2, the default port is 5001, and in iPerf3, 5201. ...

July 18, 2022 · 7 min · Yvoictra
Wake On LAN

How to Wake up a Synology NAS from an Ubuntu server

I have several NAS servers at home (one for Media, other for Backups…) so in order to extend shelf life, not all of them are on all the day. However, there are some situations in which I need to have access to a server, but it could be off and maybe i’m not at home. In that case, I have a way to turn on the Synology NAS remotely from another server. ...

August 25, 2021 · 2 min · Yvoictra