The Problem The 'root' entry was removed from /etc/shadow and /etc/passwd. How to recover the deleted root user entry. Solution To be able to recover the deleted root user entry from /etc/shadow and /etc/passwd file, we need to boot the system into single user mode. Follow the post below to boot the system into single user mode. CentOS / RHEL 6 : How to Boot into single user mode Once you have booted into the single user mode follow the steps given below to recover the deleted root … [Read more...] about How to recover from deleted root entry in /etc/shadow and/or /etc/passwd files in CentOS / RHEL 6
ip command provided by the iproute package is used to adjust addresses, link state, routing tables, neighbour objects, and manage a system's network components. The ip command is a powerful tool designed to replace many of the old net-tools commands still in use like ifconfig. Below is a command line reference/cheat sheet of the 'ip' command. IP QUERIES addr: Display IP Addresses and property information (abbreviation of address) SUBCOMMANDDESCRIPTIONS AND TASKS ip addrShow information … [Read more...] about ‘ip’ Command cheat sheet (Command Line Reference)
The sosreport tool collects information about a system, such as hardware configuration, installed software packages, configuration, and operational state. This information is stored in a single compressed file in the /var/tmp directory, and the file can be sent to a support representative to assist in troubleshooting a problem. The sosreport tool replaces an earlier version of the tool called sysreport. Installing sosreport Package To run the tool, first install the sos package: # yum … [Read more...] about How to install and configure sosreport under CentOS / RHEL
Sometimes, to troubleshoot some multipath related issues, you would require to map the /dev/mapper/mpathY device to its corresponding /dev/sdX device. The /dev/mapper/mpathY is the multipath'd device where as the /dev/sdX is the actual device underlying it. Follow the steps below to find the mapping between the two and vice versa. We would also see how to find the /dev/sdX device name from the corresponding /dev/mapper/dm-* entry. How to map /dev/mapper/mpathY device from /dev/dm-Z device 1. … [Read more...] about How to map /dev/sdX and /dev/mapper/mpathY device from the /dev/dm-Z device
The Problem There is only one Network card on machine but ifconfig shows 2 interface by name virbr0 and lxcbr0. How to remove or disable them permanently if not using them. # ifconfig .... lxcbr0 Link encap:Ethernet HWaddr 82:61:68:AC:39:0F inet addr:10.116.186.1 Bcast:0.0.0.0 Mask:255.255.255.0 inet6 addr: fe80::8061:68ff:feac:390f/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:5 errors:0 … [Read more...] about How to Remove virbr0 and lxcbr0 Interfaces on CentOS/RHEL 6,7
Non-Uniform Memory Access or Non-Uniform Memory Architecture (NUMA) is a physical memory design used in SMP (multiprocessors) architecture, where the memory access time depends on the memory location relative to a processor. Under NUMA, a processor can access its own local memory faster than non-local memory, that is, memory local to another processor or memory shared between processors. In a NUMA system, processors, memory, and I/O are grouped together into cells. The latency and bandwidth … [Read more...] about How to Disable NUMA in CentOS / RHEL 6,7
Non-Uniform Memory Access or Non-Uniform Memory Architecture (NUMA) is a physical memory design used in SMP (multiprocessors) architecture, where the memory access time depends on the memory location relative to a processor. Under NUMA, a processor can access its own local memory faster than non-local memory, that is, memory local to another processor or memory shared between processors. In a NUMA system, processors, memory, and I/O are grouped together into cells. The latency and bandwidth … [Read more...] about How to find if NUMA configuration is enabled or disabled?
The Problem pvcreate command fails while using multipath device with below error even when the device is present. # fdisk -l /dev/mapper/mpatha Disk /dev/mapper/mpatha: 51.6 GB, 51624542208 bytes, 100829184 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk label type: dos Disk identifier: 0x5d7fc634 Device Boot Start End Blocks Id System /dev/mapper/mpatha1 32 100829183 … [Read more...] about pvcreate Fails With Error: “Device /dev/mapper/mpatha Not Found (or Ignored By Filtering).”
Under some rare conditions, you may get a GRUB loader corruption. This post illustrates how to re-install the GRUB loader on CentOS/RHEL 5 or 6. How do you know GRUB has corrupted Below are some of the symptoms you would see when there is a GRUB loader corruption. 1. The GRUB menu is not shown when booting the server 2. Boot the server into rescue mode using installation DVD, and check the header of the booting diskIf the GRUB loader is corrupted: # file -s /dev/sda /dev/sda: x86 boot … [Read more...] about CentOS / RHEL 5,6 : How to reinstall GRUB loader from rescue mode
So, here is the situation - pvcreate and vgcreate command throws errors shown below. # pvcreate /dev/sdd1 Can't open /dev/sdd1 exclusively. Mounted filesystem? # vgcreate vg1 /dev/sdd1 Can't open /dev/sdd1 exclusively. Mounted filesystem? Unable to add physical volume '/dev/sdd1' to volume group 'vg1'. Probable Cause of the error LVM will only create a pv label on a device if it is not currently in use. There are some of the other various causes for this issue, which include's: The … [Read more...] about pvcreate error : Can’t open /dev/sdx exclusively. Mounted filesystem?