Category: Linux

Add comments to ZIP files with zipnote

Never having given it much thought before, I wanted to know of a way to add a comment to my zip files in Linux.  I used to do this sort of thing many years back with pkzip in the DOS days.  There turns out to be nice little utility, called zipnote. To check for comments in a zipfile.  The command…

Read More »

Apply an SSL to MySQL

There is a MySQL 5.6.x install that works wonderfully.  However, a cert was purchased and applied to everything else, so why not apply to the MySQL install too. I ran into a pitfall or two while attempting this, so I am going to write this up in the effort to avoid those pitfalls. The Key file Determine the version of…

Read More »

Upgrade PCRE from 7.8 to 8.x on CentOS 6

A WordPress plugin required PCRE 8.x for it to work. The following instructions were taken from the source cited below and worked flawlessly. The step below determined the version of PCRE and whether there was PHP support for it. To install the newer version of PCRE create a link to the repository. Yum update Check the version Restart Apache Downgrade…

Read More »

Resize an Encrypted LUKs filesystem with LVM on Linux

There is a CentOS 6 server that needed additional diskspace. I had no idea, that this server had an encrypted filesystem for one of it’s mount points. I thought the worst for procedures, but I found this one article that worked and worked well. The situation was a VM on an ESXi server contained a LVM mount called for example,…

Read More »

VMware vSphere Client incorrectly displays Guest OS version for CentOS 7.4

The vSphere Client (desktop) Version 5.5.0 correctly displayed the CentOS 7.x point releases until version CentOS 7.4. Where it once displayed, Guest OS: CentOS 4/5/6/7 (64-bit) under the Summary tab of the virtual machine, the display is Guest OS: Linux 3.10.0-693.17.1.x86-x64 CentOS Linux release 7.4.1708 (Core). As I once thought that this was problematic, I found a discussion in Gitlab…

Read More »

Certbot Requires Python 2.7

This article describes how to use certbot with Python 2.7.  The assumption is that you have already installed certbot. At the bottom of this article, is a related post on how to install Python 2.7.  After installing Python, install/run certbot. A shortcut, run a command within a temporary environment, like this functional example below. To run certbot, enable python 2.7…

Read More »

Install Python 2.7 on CentOS 6.x

CentOS 6.x uses python 2.6 for various things.  It is the default install and Python 2.7 is not available as a typical install but I  had a need for it and found a solution that worked for me. The test. If you type exit, and type python -V, this will revert to the existing python version.  The scl enable is…

Read More »

Elasticsearch bootstrap checks failed [RESOLVED]

Elasticsearch is a distributed, open source search and analytics engine for all types of data, including textual, numerical, geospatial, structured, and unstructured.  After installing Elasticsearch the application failed to start with a bootstrap error. Problem ERROR: bootstrap checks failed max file descriptors [4096] for elasticsearch process is too low, increase to at least [65536] max number of threads [1024] for…

Read More »

smbclient error in Mounting CIFS and NFS

There is a known working samba share.  There are servers that connect to it.  All of them happen to be Windows boxes.  However, wanted to connect a Linux (CentOS 7) to it.  When testing for a connection, it failed with an error message. The command and the error. The resolution turned out to be a simple one.  Update the client…

Read More »

CentOS Linux and passwords

User creation and password changes can be handled as one-liners for as long as you use the correct commands.  Today I learned of another password utility other than passwd.  It is chpasswd, a powerful tool to change passwords without the prompt and the password can be encrypted. User Creation To create a user may be a two step process. First…

Read More »

Rename all files to lowercase names

There seems to be several solutions offered for renaming all files in a directory from mixed or upper case to all lowercase names. Of the solutions, one of the worked without issue. ls | while read upName; do loName=`echo “${upName}” | tr ‘[:upper:]’ ‘[:lower:]’`; mv “$upName” “$loName”; done Although this was found in an Ubuntu forum, it works flawlessly in…

Read More »

Remove non-ASCII characters from file

There was a text file that contained non-ASCII characters that acted like spaces within the file, so I used the tried and true dos2unix command to attempt to clean the file; however, the characters remained.  With hundreds of lines to correct, manually deleting the offending areas of the file was not an option.  A real solution is needed. Once again,…

Read More »

The truncate command

If you ever get in a bind and a log file has gone out of control and your disk space is full, you may be tempted to delete the log file.  There may be a couple of problems with that.  One, the application is still using the file so that delete may not actually take place until the application is…

Read More »

Best Practice for chown

Over the years, I have seen a couple of variations with the use of the chown command. The “:” (colon) vs “.” (dot).  While studying for the RHEL6 exam sometime ago, the books that I had used each had one or the other in their documentation.  I have read that the posix standard is using chown with the “:” (colon)….

Read More »

How to Update a Lenovo BIOS with USB

Lenovo provides an ISO for CD/DVD burning and an EXE for running the executable from within Windows.  There is NO support for an ISO booting from a USB.  Many modern laptops are ordered without a CD ROM and maybe an extra hard drive in it’s place.  Most people use USB sticks for the majority of their effort when the need…

Read More »

How to repair a damage fstab located on an LVM

i made a change to the /etc/fstab that looked perfectly fine until I rebooted the system (CentOS 6) running as a virtual machine.  The system did not start, there was a Kernel panic, and using the single boot mode did not provide any access to the system.  I changed the “/” partition to a UUID number after changing the volume…

Read More »

Create a Port Listener to verify connectivity

How to test an open port without having the application installed. Suppose you have a situation where you just created a new Linux server (CentOS 6) and you will eventually have an application run on Tomcat port 8080/tcp. You will want this application to use some sort of a Reverse Proxy and this all goes through a firewall that sits…

Read More »