Tag: Linux

Remove Old Kernels on CentOS Linux and other distros

After a few years and many yum updates later, the hard drive begins to fill up. There may be many versions of the Linux kernel. Many of which may be removed and to do this the yum-utils package is needed. Pre-CentOS 8 Install the yum-utils package. yum install -y yum-utils Check your running version. [root@server01 opt]# uname -a Linux server01…

Read More »
MySQL

A Working MySQL Database Automatic CRON Backup Script

After creating a usable MySQL database backup script and having tested it throughly, I put it in the /etc/cron.daily directory where I had expected it to run automatically.  I had even tested it from that directory manually with success.  After some time had past, I realized that the script was running as it read in the logs; however had only…

Read More »
No Spam

Automatically Delete Emails Marked SPAM by Spamassassin

Great, so you have another service running on your Linux box. It’s main purpose is to intercept an email, run rules against it, and either mark it as spam or not. Either way, it sends the email through and you still have to deal with the message on the email client. From the email client, you could make the necessary…

Read More »
SpamAssassin Logo

Install SpamAssassin on CentOS 6

SpamAssassin is an e-mail spam filter which uses content-matching rules. For this install, CentOS 6.6 (64-bit) and Sendmail are used. Enable EPEL repository. One way is to download and install the EPEL repository. Another is to edit the /etc/yum.repos.d/epel.repo file and change enabled=0 to enabled=1 under the [epel] section. Yet another way to enable EPEL repository. Install Sendmail and spamassassin….

Read More »
OpenVZ Logo

Install OpenVZ and a CentOS Container

OpenVZ (Open Virtuozzo) is an operating system-level virtualization technology based on the Linux kernel and operating system. OpenVZ allows a physical server to run multiple isolated operating system instances, called containers, virtual private servers (VPSs), or virtual environments (VEs). OpenVZ is similar to FreeBSD jails and Solaris Containers. Download the OpenVZ repo. wget -P /etc/yum.repos.d/ http://ftp.openvz.org/openvz.repo Import OpenVZ GPG key….

Read More »
Rainloop

Install Rainloop Webmail on CentOS 6

Rainloop is an attractive webmail with a nice clean modern feel to it. After following several different installation procedures, I finally got a working copy. Assumptions: Apache has already been installed. Sendmail or Postfix is already installed correctly. Install Rainloop Create a configuration file for Apache. Restart or Reload Apache Logon to the admin control panel with default credentials. URL:…

Read More »
Speedtest

Command Line Testing Internet Bandwidth Using Python

Speedtest.net is a go to site for testing Internet speeds, which is usually accomplished through a web browser. There is a command line utility that offers the functionality without the need of a GUI or the web browser. To run the utility, type speedtest_cli.py. Here is an example of what one may expect to see. [root@localhost speedtest-cli-master]# speedtest_cli.py Retrieving speedtest.net…

Read More »
Speedtest

Network Speed Test for Linux

Have you ever wondered at what speed your network is really operating? There are several programs and utilities that are readily available. I have tested a couple, however, this one seems to be the easiest and very efficient. This was tested on a CentOS 7 server. From the server, which in this case is 10.10.10.10. From the client. A result…

Read More »
Linux Logo

One Way to “sysprep” a Linux Template to Clone

An anoyance with cloning a Linux virtual machine is that the /etc/sysconfig/network-scripts/ifcfg-eth0 file may contain a UUID and HWADDR which can be removed and the /etc/udev/rules.d/70-persistent-net.rules can be deleted or zero’ed out. So, here are the steps I use to create a “template”. After cloning the system, the first screen should be the option to set a root password. Since,…

Read More »
Linux Logo

Configure a Public Share with Samba on Centos 7 Linux

A CentOS7 Linux server was used to create Samba shares so that Windows clients of a home network may back up their stuff, resulting in one share with read write access. The ultimate goal was to create a Samba share that would act as if it were one of those off-the-shelf “solutions” like a Buffalo Linkstation, where no user password…

Read More »
Linux Logo

Use grep or awk to eliminate blank lines and comments

A configuration file, specifically, the /etc/samba/smb.conf file contains many lines of comments using both the simi-colon (“;“) and the hash (“#“) as well as many empty lines that are either blank or contain whitespace. Using grep to view the file without these lines is one way to do so. To write the correct command can be a bit more challenging….

Read More »
Linux Logo

Linux Centos 6 PYCURL ERROR 6 error RESOLVED!

A particular virtual machine running Linux CentOS 6.5 had been problematic when it came to yum updates. The result always ended with a PYCURL ERROR 6 – Couldn’t resolve host. After spending way too much time towards resolution, a solution finally came to light. The configuration of the system is a Linux CentOS 6.5 build with two network cards. One…

Read More »

Break the 2TB limit in Linux with gdisk

Without going into too much detail, for over 30 years the MBR has been the hard drive partition standard, which has a 2TB limit. GPT replaces MBR with one of it’s key benefits, exceeding the 2TB limit. While the fdisk tool is dated, there are several other tools that handle 2TB drives and beyond. gdisk One such tool, is gdisk,…

Read More »

Use blkid or lsblk to display UUID

Knowing the UUID (“Universally Unique Identifier”) of a device is important in the event of creating a permanent mount point using /etc/fstab. Of course, the name of the device may be used, however, using the UUID is the current trend. There are benefits to this trend. The identifier will likely not be used by anything else so that there will…

Read More »

Match empty lines and commented lines using grep

An example of a configuration file with many commented lines is /etc/sysctl.conf. If you wanted to display the contents of the file without the commented lines, the following command may be issued. However the resulting contents will be displayed with the remaining blank lines. To get around this one of a couple of commands may be issued. Source(s) http://stackoverflow.com/questions/18566169/match-empty-lines-in-a-file-grep http://stackoverflow.com/questions/3432555/remove-blank-lines-with-grep

Read More »
Virtualbox Logo

Use Your VPN Connection in a Linux CentOS VirtualBox Instance

Running Oracle’s VirtualBox on a Microsoft Windows 7 desktop to test applications and operating systems has proven to be very productive. As a result of a VPN connection using Citrix, a VirtualBox VM of CentOS 6.5 Linux could not connect to the remote network. After combing through the Internet, a solution is born. I know that there are many variables…

Read More »

Install Adobe Reader on CentOS 6.5

While perusing through the Internet, I found this site called iF !1 0 “If Not True then False“. I found this write-up on how to install Adobe Reader on one of many different flavors on Linux. I couldn’t pass up on this, since I was in the hunt for Adobe Reader. The process worked great, so here is my slight…

Read More »