Restore ZFS Pool and storage data

If the disks are recognized from your OS the command:

zpool import

should be enough to get the pool imported and visible in your current OS. You can check the status with command

zpool status

You can try to import it explicitly by name

zpool import ZStore

P.S. Do not forget to set the pool online:

zpool online

You can check zpool-features features and if they are enabled or not in your case. Seems like zfs build in your case is new than the version which create it. The problem is if you update you will be able to mount only with same or upper version of zfs

What I can recommend you is to try (if available) with live version (but this with which you create the pool)

Src:
https://unix.stackexchange.com/questions/483465/restore-zfs-pool-and-storage-data-after-a-system-re-install

Share

Create a RAID array using with mdadm

mdadm (multiple devices admin) is an extremely useful tool for running RAID systems. It’s is a tool for creating, managing, and monitoring RAID devices using the md driver. It can be used as a replacement for the raidtools, or as a supplement. You can use whole disks (/dev/sdb, /dev/sdc) or individual partitions (/dev/sdb1, /dev/sdc1) as a component of an array.

The benefits of using mdadm are:

  1. mdadm can diagnose, monitor and gather detailed information about your arrays.
  2. mdadm is a single centralized program and not a collection of disperse programs, so there’s a common syntax for every RAID management command.
  3. mdadm can perform almost all of its functions without having a configuration file and does not use one by default.

mdadm software tools work for all Linux distributions, with the same syntax.

Read more

Share

Install Discourse on Ubuntu 22.04

Prerequisites

  • A server with Ubuntu 22.04 as OS
  • Valid domain pointed to the servers IP address
  • User privileges: root or non-root user with sudo privileges

Step 1. Update the System

Update the packages to their latest versions available after a fresh install of Ubuntu 22.04

sudo apt-get update -y && sudo apt-get upgrade -y

Step 2. Install Docker

First, we will add the GPG keys and Docker repository since it is not added by default in the Ubuntu 22.04 official repository.

curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu focal stable"

Once the keys and repo are added, install Docker with the following command:

sudo apt install docker-ce docker-ce-cli containerd.io -y

After successful installation, start and enable the Docker service.

Read more

Share

The lousy Brainer Drainer

Hi, I am Hasan T. Emdad Rumi, an IT Project Manager & Consultant, Virtualization & Cloud Savvyfrom Dhaka, Bangladesh. I have prior experience in managing numerous local and international projects in the area of Telco VAS & NMC, National Data Center & PKI Naitonal Root and CA Infrastructure. Also engaged with several Offshore Software Development Team.

Worked with Orascom Telecom-BanglalinkNetwork Elites as VAS partner, BTRCBTT (Turkey) , Mango Teleservices Limited and Access to Informaiton (A2I-UNDP)

Currently working at Oracle Corporation as Principal Technology Solution and Cloud Architect.You can reach me [h.t.emdad at gmail.com] and I will be delighted to exchange my views.

Share

Troubleshoot email on a new Discourse install

If you’ve just installed discourse, but email doesn’t seem to work. Unfortunately this means you can’t log in as an admin to finalize the install. 

Try the doctor

cd /var/discourse
./discourse-doctor

It will check several ways that your mail configuration might be broken, and offer advice. Try that first.

Did you enter email settings correctly?

The simplest way is to run ./discourse-setup again. Did you enter everything correctly?

Read more

Share

Install Nginx Proxy Manager on CentOS 7

Nginx Proxy Manager is built on docker container. So, we need to deploy Docker first.

Update Docker Package Database. In a terminal window, type:

sudo yum check-update

Allow the operation to complete.

Remove if any docker is preinstalled with your OS-

sudo yum remove docker docker-client docker-client-latest docker-common docker-latest docker-latest-logrotate docker-logrotate docker-selinux docker-engine-selinux docker-engine

Install the Dependencies

Type in the following command:

sudo yum install -y yum-utils device-mapper-persistent-data lvm2

The –y switch indicates to the yum installer to answer “yes” to any prompts that may come up. The yum-utils switch adds the yum-config-manager. Docker uses a device mapper storage driver, and the device-mapper-persistent-data and lvm2 packages are required for it to run correctly.

Read more

Share

SSH to use two-factor authentication using Google Authenticator on Debian or Ubuntu Server

  • A computer running Ubuntu 16.04 LTS or above
  • A phone running Android or iOS
  • A configured SSH connection
  • You should understand the danger of stolen passwords.
  • You don’t need to know what two-factor authentication is and how it works. 🙂

Installing and configuring required packages

Start a terminal session and type:

sudo apt install libpam-google-authenticator

Configuring SSH

To make SSH use the Google Authenticator PAM module, add the following line to the /etc/pam.d/sshd file:

Read more

Share

Deploy a Laravel app on Oracle Cloud with database

Assumptions:

  • Ubuntu 22
  • PHP 7.3
  • Laravel 5.5
  • Apache 2
  • PHP-Redis
  • Download the public and private keys on your local machine.
  • You have created your VM instance!
  • Create an always free Autonomous Database [if your application uses a database]
  • Select your desired database
  • After creating your database, go to “DB Connection” tab
  • Download the Oracle Wallet on your local machine to connect to your database

Read more

Share

Connecting to Autonomous DB Without a Wallet (Using TLS)

Enable TLS

Log in to the Oracle Cloud console and select your ADB instance to view the instance details. In the details, find the section titled ‘Network’ and click on ‘Edit’ next to ‘Access Control List’.

In the ‘Edit Access Control List’ dialog, choose the type of entry that you’d like to make and enter the appropriate value. You can add entries by IP Address (I added my local IP), CIDR Block (maybe your office has a range of IPs assigned to developers), and VCN (by name or OCID). Add as many as necessary.

Read more

Share