RHEL 7 – RHCSA Notes (Cheat Sheets) RHEL 7 has 3 command-line utilities to configure the system date and time: 1. date 2. hwclock 3. timedatectl date command Use the date command to display or set the system date and time. Run the date command with no arguments to display the current date and time: […]
Archives for September 2016
Complete Hardware Reference : SPARC T7-1 / T7-2 / T7-4
CentOS / RHEL : How To Shrink LVM Root File System
During system installation, one may allocate an over-generous amount of disk space to the root partition and may later wish to reclaim any unused space. The post describes how to reduce the space allocated to an root file system on a Linux Volume Manager (LVM) logical volume. Note : this procedure applies only if the […]
CentOS / RHEL 7 : Oracleasm Create Disk Failed “Instantiating disk: failed”
Error: Oracleasm create disk failure on RHEL 7 with following error. # oracleasm createdisk DATA1 /dev/sde1 Writing disk header: done Instantiating disk: failed Clearing disk header: done Solution When disk is created with verbose option (-v) you would see : # oracleasm createdisk -v DATA1 /dev/sde1 Disk “DATA1” does not exist or is not instantiated […]
CentOS / RHEL : How to migrate storage (LVM) with pvmove Command
Solution: Existing Configuration : Existing Physical Volume: 1.5 TB, /dev/mapper/mpathX Existing Volume Group: data_vg Existing Logical Volume: lv_data01 (/dev/mapper/data_vg-lv_data01) We need to move to the following configuration : Physical Volume: 1.5TB, /dev/mapper/mpathY Volume Group: data_vg Logical Volume: data (/dev/mapper/data_vg-lv_data01) Note: Please take complete backup before performing the storage migration Steps 1. Begin by pvcreate’ing the […]
RHEL 7 – RHCSA Notes : Schedule tasks using at and cron
RHEL 7 – RHCSA Notes (Cheat Sheets) – Linux can run tasks automatically, and comes with automated tasks utilities: cron, anacron, at, batch. – cron jobs can run as often as every minute. – A scheduled cron job is skipped if the system is down. – anacron can run a job only once a day. […]
How To Delete Files on a ZFS Filesystem that is 100% Full
When a ZFS file system has no space left then the deletion of files can fail with “disk quota exceeded“. The post provides different ways to create free space to overcome the situation. 1. Truncating files If the files can not be removed directly, we can first truncate them and then delete them. # cat […]
CentOS / RHEL 7 : Beginners guide to systemd service units
Previous versions of Oracle Linux use init scripts located in the /etc/rc.d/init directory to start and stop services. In RHEL 7, these init scripts have been replaced with systemd service units. Service units have a .service extension. Use the systemctl command to list all loaded service units: # systemctl list-units –type service –all UNIT LOAD […]
RHEL 7 – RHCSA Notes : Start, stop, and check the status of network services.
RHEL 7 – RHCSA Notes (Cheat Sheets) systemd service units – Previous versions of Oracle Linux use scripts in the /etc/rc.d/init.d directory to control services. – In Oracle Linux 7, these scripts have been replaced by systemd service units. – Use the systemctl command to list information about service units. To list all loaded service […]
RHEL / CentOS : How to shrink LVM volume
Unlike increasing the LVM volume size, to shrink the volume we need to umount the filesystem. Shrinking LVM volume can not be done online. Before shrinking the volume make sure you have taken the backup of the mount point. Shrinking volume has a chance of data corruption. Example given in this post applies to both […]