Sponsored Content
Full Discussion: Bdf output
Top Forums Shell Programming and Scripting Bdf output Post 302463332 by indrajit_renu on Sunday 17th of October 2010 02:04:01 AM
Old 10-17-2010
Hi Praving..Still the output comes same

Code:
mlbept0340-root> bdf | tail +2 |awk '{if(/^[0-9]/){print $1,$4,$5} else {print $1, $5, $6}}'
/dev/vg00/lvol3 10% /
/dev/vg00/lvol1 18% /stand
/dev/vg00/lvol7 75% /var
/dev/vg00/lvol8 6% /var/adm/crash
/dev/vg00/lvol6 58% /usr
/dev/vg00/lvol5 1% /tmp
/dev/vg00/lvol4 59% /opt
/dev/vg00/lv_app 1% /app
/dev/vg00/lv_common
31457280 /app/common

I am expecting the output as below
Code:
/dev/vg00/lvol3 10% /
/dev/vg00/lvol1 18% /stand
/dev/vg00/lvol7 75% /var
/dev/vg00/lvol8 6% /var/adm/crash
/dev/vg00/lvol6 58% /usr
/dev/vg00/lvol5 1% /tmp
/dev/vg00/lvol4 59% /opt
/dev/vg00/lv_app 1% /app
/dev/vg00/lv_common 72% /app/common

Original bdf
Code:
Filesystem          kbytes    used   avail %used Mounted on
/dev/vg00/lvol3    2097152  217056 1865480   10% /
/dev/vg00/lvol1    1835008  329040 1494288   18% /stand
/dev/vg00/lvol7    10485760 7864144 2601176   75% /var
/dev/vg00/lvol8    8454144  486597 7469647    6% /var/adm/crash
/dev/vg00/lvol6    5242880 3036056 2189632   58% /usr
/dev/vg00/lvol5    2097152   21952 2059232    1% /tmp
/dev/vg00/lvol4    12582912 7433992 5109456   59% /opt
/dev/vg00/lv_app    131072    1141  121818    1% /app
/dev/vg00/lv_common
                   31457280 22302666 8582476   72% /app/common


Last edited by Scott; 10-17-2010 at 07:40 AM.. Reason: Code tags
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

BDF test for > 90%

I am trying to write a script that will allow me to do a bdf then do a test for a percentage that is 90% or greater. If the test is true then i want to send a message to myself and one other person. Any suggestions ? ? ? Thanks. ....svp (6 Replies)
Discussion started by: svp4444
6 Replies

2. HP-UX

df and bdf discrepencies

I've recently had some space problems on one of our old HP9000 machines. I archived/moved/compressed/trashed some stuff to free up some space on one rather large (and important) logical volume. As one would expect, when `df -b` is executed some space is shown as free: /opt ... (2 Replies)
Discussion started by: sam_pointer
2 Replies

3. Shell Programming and Scripting

bdf script not working !!

Hi, I have written a funtion which taken bdf output and put's in a file. The idea is to grep a areas which greater then 80% and echo the same on the system. However the script I have written fails with the error :- + awk $0 !~ /^F/ + awk {print $5"\t" $6} + sed s/%// + 1> /tmp/bdflist}... (3 Replies)
Discussion started by: kpatel786
3 Replies

4. Shell Programming and Scripting

Formatting bdf output

Hi All. Using /usr/bin/ksh on a HP-UX B.11.23 ia64 system. Executing the following ... ` bdf -t vfxs | grep "/" ` The output comes out like (in part) ... /dev/vg00/lvol3 516096 229448 284480 45% / /dev/vg00/lvol1 516096 211200 302560 41% /stand /dev/vg00/lvol8 ... (5 Replies)
Discussion started by: Cameron
5 Replies

5. UNIX for Advanced & Expert Users

bdf question

Hi all i am working on script which uses "bdf" output to create excel sheet now when i check "Total" "Used" & "Available" i found that except root everywhere used + available != total here is example : part from bdf output : filesystem-total-used-available-%used-Mounted on ... (4 Replies)
Discussion started by: zedex
4 Replies

6. Shell Programming and Scripting

bdf error

I have this line in a sh script: bdf | grep /var/opt/vgdb | tr -s " " | cut -f4,6 -d" " | awk '{print $2" "$1}' > vgdb_free_space.txt if I run that line in the shell it works fine but when I ran the script got this error: add_database_files.sh: line 83: bdf: command not found also I tried... (4 Replies)
Discussion started by: C|KiLLeR|S
4 Replies

7. Shell Programming and Scripting

Formatting BDF output

Hello people. First of all I googled my problem and even found answers in this forum. Unfortunatelly my problem is not solved. When the lenght of the filesystem is too big the output of bdf wraps into another line. e.g.: Filesystem kbytes used avail %used Mounted on... (5 Replies)
Discussion started by: drbiloukos
5 Replies

8. HP-UX

bdf hangs

hi, bdf command hangs but before it, it lists all the fstab content, so i cannot find the reason... could anybody give me any clue?? thanks a lot for your attention. regards Pablo i attach syslog Jan 14 16:30:00 sv23 vmunix: hp_dlpi_wput:Received an unrecognized primitive: 101d... (7 Replies)
Discussion started by: pabloli150
7 Replies

9. Shell Programming and Scripting

Using the output of bdf in script

Hello all, First I have an old HP-UX box(11.21) for which I need to implement file-system utilization monitoring. I choosed to use bdf and a simple for loop. However sometimes the output of bdf is as this one(this is actually form linux but the idea is the same) Filesystem ... (4 Replies)
Discussion started by: click
4 Replies

10. HP-UX

Bdf in HP-UX

Hi guys, I have to make an output of several databases we've got running on our system with the command bdf. This has to be done every 3 months. I want to put it in an scriptfile and trigger it in crontab. In the output it must display the differences in diskspace between these three monts. Any... (3 Replies)
Discussion started by: djmental
3 Replies
df(1B)						     SunOS/BSD Compatibility Package Commands						    df(1B)

NAME
df - display status of disk space on file systems SYNOPSIS
/usr/ucb/df [-a] [-i] [-t type] [filesystem...] [filename...] DESCRIPTION
The df utility displays the amount of disk space occupied by currently mounted file systems, the amount of used and available space, and how much of the file system's total capacity has been used. If arguments to df are path names, df produces a report on the file system containing the named file. Thus `df .' shows the amount of space on the file system containing the current directory. OPTIONS
The following options are supported: -a Report on all filesystems including the uninteresting ones which have zero total blocks (that is, auto-mounter). -i Report the number of used and free inodes. Print ` * ' if no information is available. -t type Report on filesystems of a given type (for example, nfs or ufs). EXAMPLES
Example 1 Using df A sample of output for df looks like: example% df Filesystem kbytes used avail capacity Mounted on sparky:/ 7445 4714 1986 70% / sparky:/usr 42277 35291 2758 93% /usr Note that used+avail is less than the amount of space in the file system (kbytes); this is because the system reserves a fraction of the space in the file system to allow its file system allocation routines to work well. The amount reserved is typically about 10%; this can be adjusted using tunefs (see tunefs(1M)). When all the space on a file system except for this reserve is in use, only the super-user can allocate new files and data blocks to existing files. When a file system is overallocated in this way, df can report that the file system is more than 100% utilized. FILES
/etc/mnttab List of file systems currently mounted /etc/vfstab List of default parameters for each file system ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWscpu | +-----------------------------+-----------------------------+ SEE ALSO
du(1), quot(1M), tunefs(1M), mnttab(4), attributes(5) SunOS 5.11 14 Sep 1992 df(1B)
All times are GMT -4. The time now is 07:03 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy