From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4.3) Gecko/20050104 Red Hat/1.4.3-3.0.7 Description of problem: On my RHEL 4 boxes that run LVM, The "Disk Space" output from logwatch contains no information about the filesystem. This is because the "df" command linewraps when the device name is too long. Here's an example, only the entry for /boot has the proper info. ------------------ Disk Space -------------------- /dev/mapper/homer_vg-rootLV /dev/sda2 145M 22M 116M 16% /boot /dev/mapper/homer_vg-exportLV /dev/mapper/homer_vg-homeLV /dev/mapper/homer_vg-sambaLV /dev/mapper/homer_vg-swLV /dev/mapper/homer_vg-tmpLV /dev/mapper/homer_vg-usrlocalLV /dev/mapper/homer_vg-varLV http://www2.list.logwatch.org:81/pipermail/logwatch/2004-November/000592.html has a discussion of it, the fix (use "df -hP" instead of "df -h") is apparently upstream. /August. Version-Release number of selected component (if applicable): logwatch-5.2.2-1 How reproducible: Always Steps to Reproduce: 1. Make some LVM filesystems 2. run logwatch 3. Actual Results: "/dev/mapper/homer_vg-swLV" Expected Results: "/dev/mapper/homer_vg-swLV 4.9G 42M 4.6G 1% /sw" Additional info:
All that needs to be done here is changing 'df -h' to 'df -hP' in scripts/services/zz-disk_space.
*** Bug 144012 has been marked as a duplicate of this bug. ***
Note that the upstream LogWatch change was rolled back since Solaris df does not support -P.
*** Bug 160949 has been marked as a duplicate of this bug. ***
This bug was originally reported in January and it's a one-line fix. The upstream 5.2.2 includes a block which specifically identifies Linux, which would be a great place to fix this bug. If "uname -a" on Solaris reports "Linux", then I can understand why upstream wouldn't fix this. However, since default installs of RHEL use long LVM names, even if upstream wouldn't want to take the change, doesn't it make sense for Red Hat to create a one-liner local patch to make this script useful? Why not fix this bug?
due to this bug i'm unable to monitor disk space usage from logwatch reports. i'm having problems understanding why it takes more than 4 months to apply a one line fix in RHEL 4.
There is a fix in RHEL4 U2 beta--even pretty-printed! In case you can't wait grab the rpm from RHN, or just do this: --- old 2005-09-02 10:41:44.829652856 -0700 +++ /etc/log.d/scripts/services/zz-disk_space 2005-05-12 06:12:59.000000000 -0700 @@ -17,7 +17,8 @@ if [ "$PRINTING" = "y" ] && [ "`uname - echo echo "------------------ Disk Space --------------------" echo - df -h | grep '^/dev/' + df -hP | grep '^/dev/' | \ + sed 's/\([^[:space:]]\{20,\}\)\(.*\)/\1\n \2/' echo elif [ "$PRINTING" = "y" ] ; then echo
*** Bug 169918 has been marked as a duplicate of this bug. ***
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on the solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2005-382.html
*** Bug 170100 has been marked as a duplicate of this bug. ***