Install and Setup TIG Stack on Ubuntu 20.04 Rumi, July 26, 2024July 27, 2024 In this tutorial, we are going to learn how to install and setup TIG Stack on Ubuntu 20.04. TIG stack is a group of powerful open-source monitoring tools, Telegraf, InfluxDB and Grafana where; Telegraf is an open-source server agent for collecting and sending metrics and events from databases, systems, and… Continue Reading
CentOS 7 updated repo after its EOL Rumi, July 26, 2024 mirrorlist.centos.org doesn’t exists anymore. So, your default repor wwith yum doesn’t work. Try using the following processes, it worked for me, hope this works for others as well. sed -i s/mirror.centos.org/vault.centos.org/g /etc/yum.repos.d/*.repo sed -i s/^#.*baseurl=http/baseurl=http/g /etc/yum.repos.d/*.repo sed -i s/^mirrorlist=http/#mirrorlist=http/g /etc/yum.repos.d/*.repo Ref: https://serverfault.com/questions/1161816/mirrorlist-centos-org-no-longer-resolve Continue Reading
WordPress WP Backup Sample Script Rumi, July 26, 2024 #!/bin/bash # your backups will use these filenames. db_backup_name=”tweenpath-db-backup-“`date “+%Y-%m-%d”`”.sql.gz” wpfiles_backup_name=”tweenpath-files-backup-“`date “+%Y-%m-%d”`”.tar.gz” ## 1: database connection info. You can get these details from your wp-config file. db_name=”user_name” db_username=”database” db_password=”password” ## 2: Path to your WordPress Upload and Theme directories. Replace /home/username/ with path to your home directory. wp_upload_folder=”/home/tweenpath/public_html” ## 3:… Continue Reading
XCP-NG few basic command lines- CLI Rumi, July 3, 2024July 3, 2024 Run the following command to list VMs and their UUIDs: xe vm-list resident-on=<uuid_of_host> Try the shutdown command with force: xe vm-shutdown uuid=<uuid_of_vm> force=true Restart the toolstack on the host by using the following command: xe-toolstack-restart Restart the host. shutdown -r now If the VM is still not shutdown, you might… Continue Reading
MOTD with NeoFetch Rumi, July 1, 2024July 3, 2024 Install NetoFetch First: sudo apt install neofetch sudo cp motd.sh /etc/profile.d/motd.sh sudo chmod +x /etc/profile.d/motd.sh Open the motd.sh filw using text editor and paste below: #!/bin/bash printf “\n” neofetch Exit from shell and re-login- Voila! Continue Reading
Install LetsEncrypt on Debian with Nginx Server Rumi, June 30, 2024 Install Certbot and its Nginx plugin with apt: sudo apt install certbot python3-certbot-nginx Certbot provides a variety of ways to obtain SSL certificates through plugins. The Nginx plugin will take care of reconfiguring Nginx and reloading the config whenever necessary. To use this plugin, type the following: sudo certbot –nginx -d… Continue Reading
Reset XCP-ng root password Rumi, June 28, 2024 The full prodecure can also be found on xcp-ng site. Reboot your XCP-ng into Grub boot menu. Select XCP-ng boot menu entry and press e key to edit boot options. Locate the read-only parameter ro and replace it with rw init=/sysroot/bin/sh. Press Ctrl + X to boot into single-mode. From… Continue Reading
Creating 1:1 NAT using iptables Rumi, June 8, 2024 Its a POC where I needed a 1:1 NAT using Linux iptables. I used 2 Debian 11 OS for this and here’s the machine IP plans- VM-1: IPTables/NAT Router- 123.45.67.5/24, 123.45.67.6/24 and 192.168.10.5/24 VM-2: Backend Server- 192.168.10.6/24 (this VM’s gateway will be 192.168.10.5 On VM-1 Uninstall nftables and its Dependencies… Continue Reading
MinIO object storage upload using curl Rumi, June 7, 2024 #!/bin/bash # Usage: ./minio-upload my-bucket my-file.zip bucket=$1 file=$2 host=minio.example.com s3_key=svc_example_user s3_secret=svc_example_user_password resource=”/${bucket}/${file}” content_type=”application/octet-stream” date=`date -R` _signature=”PUT\n\n${content_type}\n${date}\n${resource}” signature=`echo -en ${_signature} | openssl sha1 -hmac ${s3_secret} -binary | base64` curl -X PUT -T “${file}” \ -H “Host: ${host}” \ -H “Date: ${date}” \ -H “Content-Type: ${content_type}” \ -H “Authorization: AWS ${s3_key}:${signature}” \… Continue Reading