How to Install Ansible on Centos 8

On most Linux distribution, Ansible can be installed either using python3-pip or ansible package. I’m going to show how to get Ansible installed using the second method on CentOS 8. First add the EPEL repository to the CentOS 8 server. # yum localinstall https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm Next, install ansible package: # yum install ansible Last metadata expiration check: 0:00:49 ago on Sun 10 Nov 2019 09:33:22 PM AEDT. Dependencies resolved. ======================================================================================================================= Package Arch Version Repository Size ======================================================================================================================= Installing: ansible noarch 2.8.5-2.el8 epel 15 M Installing dependencies: python3-babel noarch 2.5.1-3.el8 AppStream 4.8 M python3-jinja2 noarch 2.10.1-2.el8_0 AppStream 538 k python3-jmespath noarch 0.9.0-11.el8 AppStream 45 k python3-markupsafe x86_64 0.23-19.el8 AppStream 39 k python3-pyasn1 noarch 0.3.7-6.el8 AppStream 126 k libsodium x86_64 1.0.18-2.el8 epel 162 k python3-bcrypt x86_64 3.1.6-2.el8.1 epel 44 k python3-pynacl x86_64 1.3.0-5.el8 epel 100 k sshpass x86_64 1.06-9.el8 epel 27 k Installing weak dependencies: python3-paramiko noarch 2.4.3-1.el8 epel 289 k Transaction Summary ======================================================================================================================= Install 11 Packages Total download size: 21 M Installed size: 104 M Is this ok [y/N]: Let’s confirm that the installation went ok by checking the version of ansible: ...

November 9, 2019 · 2 min · 233 words · kenno

How to Label an XFS Filesystem

When I plugged in an external drive to my laptop, the drive was displayed as a string consits random letters and numbers. Here is an example: ❯❯❯ df -Th | grep sdb /dev/sdb1 xfs 481M 26M 456M 6% /run/media/kenno/5428b182-c92e-466b-89d2-b5b31b80ba48 Though the drive worked perfectly fine, I think it’s ugly, and I wanted to properly give it a good name. Let’s call it externo. But how to do this? You may not believe it, I forgot how to do this. In fact, I couldn’t rememer when the last time I had to (re)label a file system. Fear not,Google can come to the rescue! ...

October 27, 2019 · 2 min · 304 words · kenno

Create a User Account with PowerShell

Today I learned how to create a user account on Windows 10 using PowerShell. Let’s create a small exercise to demonstrate how can this be easily done. Task: “Create a local user account named ’localaccount’ with the password BlueHat. This new user should have admin privilege.” First, launch the PowerShell (terminal?), by running as Administrator. The password will be stored in a variable called $Password: $Password = Read-Host -AsSecureString ******* Now we’re ready to create a new local account: ...

October 24, 2019 · 1 min · 161 words · kenno

CTDB Not Starting Up on CentOS 7

While preparing for my Red Hat Gluster Storage Administration exam (EX236), I got stuck at a section of configuring IP failover with CTDB Clustered Trivial Database) for Samba. The problem is that I coudldn’t get the ctdb service running on my home lab running CentOS 7 and a newer version of ctdb. This problem occurs on the following platform and package version: CentOS Linux release 7.7.1908 (Core) ctdb 4.9.1-6.el7 # systemctl status ctdb ● ctdb.service - CTDB Loaded: loaded (/usr/lib/systemd/system/ctdb.service; enabled; vendor preset: disabled) Active: failed (Result: exit-code) since Sun 2019-10-13 23:17:46 AEDT; 3min 7s ago Docs: man:ctdbd(1) man:ctdb(7) Process: 1335 ExecStart=/usr/sbin/ctdbd_wrapper start (code=exited, status=1/FAILURE) Oct 13 23:17:35 serverb.rh236.local systemd[1]: Starting CTDB... Oct 13 23:17:35 serverb.rh236.local ctdbd[1348]: CTDB logging to location file:/var/log/log.ctdb Oct 13 23:17:46 serverb.rh236.local ctdbd_wrapper[1335]: Timed out waiting for initialisation - check logs Oct 13 23:17:46 serverb.rh236.local systemd[1]: ctdb.service: control process exited, code=exited status=1 Oct 13 23:17:46 serverb.rh236.local systemd[1]: Failed to start CTDB. Oct 13 23:17:46 serverb.rh236.local systemd[1]: Unit ctdb.service entered failed state. Oct 13 23:17:46 serverb.rh236.local systemd[1]: ctdb.service failed. Here is the congent from /var/log/log.ctdb log: ...

October 13, 2019 · 3 min · 513 words · kenno

New BIOS Firmware for ThinkPad P1 1.24

I’ve been relying on Gnome Software Center to let me know when new ThinkPad P1 firmware is available. Up until today, there is no new firmware available since the last update back in August 2019. However, I stumbled on a post on reddit r/thinkpad, someone mentioned the BIOS 1.26 had been released for X1 Extreme/P1 Gen 2. This made me wonder if there was also new version of BIOS for the P1 Gen 1 that I have. Of course, there is a new BIOS firmware available: 1.24. ...

October 7, 2019 · 3 min · 593 words · kenno