This write up will detail the proper way to boot your system into rescue mode on RHEL 7 and CentOS 7. Step 1 – At the Grub2 boot menu type e to edit the grub config. Note: Depending on you environment you may have to type p first and enter a grub password before having…
Adventures with TAR Command
This is just an random list of useful tar commands that I use on occasion. List Files within an TAR File
1 2 |
tar -ztvf etc.tgz |
Output
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
drwxr-xr-x root/root 0 2016-05-26 13:23 etc/ssh/ -rw------- root/root 963 2015-05-27 09:12 etc/ssh/ssh_host_key -rw-r--r-- root/root 2047 2016-05-12 00:52 etc/ssh/ssh_config -rw-r--r-- root/root 590 2015-05-27 09:12 etc/ssh/ssh_host_dsa_key.pub -rw------- root/root 125811 2016-05-12 00:52 etc/ssh/moduli -rw-r--r-- root/root 627 2015-05-27 09:12 etc/ssh/ssh_host_key.pub -rw-r--r-- root/root 382 2015-05-27 09:12 etc/ssh/ssh_host_rsa_key.pub -rw------- root/root 3879 2016-05-12 00:52 etc/ssh/sshd_config -rw------- root/root 668 2015-05-27 09:12 etc/ssh/ssh_host_dsa_key -rw------- root/root 1675 2015-05-27 09:12 etc/ssh/ssh_host_rsa_key -rw------- root/root 8598 2016-06-14 23:12 etc/selinux/targeted/modules/active/modules/rssh.pp -rw-r----- root/root 438 2016-05-12 00:52 etc/sysconfig/sshd -rw-r--r-- root/root 341 2016-05-12 00:52 etc/pam.d/ssh-keycat -rw-r--r-- root/root 616 2016-05-12 00:52 etc/pam.d/sshd |
List Specific File within an TAR File
1 2 |
tar -ztvf etc.tgz /etc/ssh/sshd_config |
Output
1 2 |
-rw------- root/root 3879 2016-05-12 00:52 etc/ssh/sshd_config |
Configure ABRT Utility on RHEL/CentOS 6
This document details the process of configuring core dumps using abrt and third party non RPM application core dumps on RHEL/CentOS 6 Configure abrt for Collecting Core Dumps This section details the process for installing and configuring abrt on RHEL/CentOS 6 Step 1: Install the abrt, abrt-cli and abrt-addon-ccpp packages using yum.
1 2 |
yum install abrt abrt-cli abrt-addon-ccpp -y |
Step 2:…
Use lsof to Find Files Open After Being Deleted
This document guides you through the steps used to determine where filesystem space has gone if df shows a full filesystem but du shows something different. Running df shows that /var is 100% full.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
[root@server1 ~]# df -h Filesystem Size Used Avail Use% Mounted on /dev/mapper/sysvg-root 20G 5.3G 14G 29% / tmpfs 16G 0 16G 0% /dev/shm /dev/sda1 976M 112M 814M 13% /boot /dev/mapper/sysvg-home 16G 45M 15G 1% /home /dev/mapper/sysvg-opt 158G 3.2G 147G 3% /opt /dev/mapper/sysvg-tmp 63G 221M 60G 1% /tmp /dev/mapper/sysvg-var 32G 32G 0 100% /var /dev/mapper/sysvg-varlogaudit 48G 317M 45G 1% /var/log/audit |
Running du does not show where the space has gone.
1 2 |
du -sh /var/* |
Results:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
4.0K account 28K adm 519M cache 48K cpq 4.0K crash 4.0K cvs 4.0K db 8.0K empty 4.0K games 4.0K gdm 8.0K hpov 234M lib 4.0K local 16K lock 3.0G log 16K lost+found 0 mail 4.0K nis 178M opt 4.0K preserve 264K run 608K spool 9.1M tmp 4.0K VRTSat_lhc 1.2M www 12K yp |
The most likely issue is that someone…
-
Recent Posts
Categories
- Audit
- Backups
- Clustering
- Development
- FreeBSD
- FreeIPA
- GlusterFS
- Guru Labs
- IPV6
- Katello
- Linux
- Linux
- Linux
- Logical Volume Manager
- mysql
- Networking
- Pacemaker
- Performance Monitoring
- Red Hat Enterprise Linux
- Red Hat Enterprise Linux 7
- Red Hat Enterprise Linux 8
- Red Hat Satellite Server 6
- Red Hat Summit
- Security
- Shell Scripting
- Solaris
- Storage Management
- Training
- Troubleshooting
- Uncategorized
- VAS/QAS Administration
- VERITAS Cluster Server
- VERITAS InfoScale
- VERITAS NetBackup
Tags
agent backup centos 6 cluster clusvcadm cman df fence fencing filesystem find fstype gl236 glusterfs guru labs hammer-cli hardening HP ILO infoscale oracle ownership pacemaker pcp pcs permissions pmcd QAS red hat 6 resource resources rgmanager rhel rhel 6 rhel 7 scripting security ssh storage sync-plan tarsnap training VAS vcs veritas