# Buffer memory, I can not see?



## superstack (May 29, 2011)

Hello,

Why is my system running *top* not showing buffer memory?

Thanks 

FreeBSD 8.2-RELEASE FreeBSD 8.2-RELEASE #0, zfs v1.5


```
last pid:  7209;  load averages:  0.01,  0.02,  0.00     up 0+02:31:23  03:52:23
546 processes: 1 running, 545 sleeping
CPU:  0.4% user,  0.0% nice,  1.1% system,  0.2% interrupt, 98.3% idle
Mem: 273M Active, 13M Inact, 146M Wired, 1668K Cache, 550M Free
Swap: 256M Total, 256M Free
```

# loader.conf

```
zfs_load="YES"
vfs.root.mountfrom="zfs:ipcs"
vfs.zfs.prefetch_disable=0
vfs.zfs.txg.timeout="5"
vm.kmem_size="512M"
vm.kmem_size_max="512M"
vfs.zfs.arc_max="64M"
vfs.zfs.vdev.cache.size="16M"

autoboot_delay="-1"
beastie_disable="YES"

hint.est.0.disabled="1"
hint.est.1.disabled="1"
hint.p4tcc.0.disabled="1"
hint.p4tcc.1.disabled="1"
hint.acpi_throttle.0.disabled="1"
hint.acpi_throttle.1.disabled="1"
```

# kernel

```
options         SCHED_ULE                       # ULE scheduler
options         PREEMPTION                      # Enable kernel thread preemption
options         INET                            # InterNETworking
options         INET6                           # IPv6 communications protocols
options         SCTP                            # Stream Control Transmission Protocol
options         FFS                             # Berkeley Fast Filesystem
options         SOFTUPDATES                     # Enable FFS soft updates support
options         UFS_ACL                         # Support for access control lists
options         UFS_DIRHASH                     # Improve performance on big directories
options         UFS_GJOURNAL                    # Enable gjournal-based UFS journaling
options         MD_ROOT                         # MD is a potential root device
options         PROCFS                          # Process filesystem (requires PSEUDOFS)
options         PSEUDOFS                        # Pseudo-filesystem framework
options         GEOM_PART_GPT                   # GUID Partition Tables.
options         GEOM_LABEL                      # Provides labelization
options         COMPAT_43TTY                    # BSD 4.3 TTY compat (sgtty)
options         COMPAT_FREEBSD4                 # Compatible with FreeBSD4
options         COMPAT_FREEBSD5                 # Compatible with FreeBSD5
options         COMPAT_FREEBSD6                 # Compatible with FreeBSD6
options         COMPAT_FREEBSD7                 # Compatible with FreeBSD7
options         SCSI_DELAY=5000                 # Delay (in ms) before probing SCSI
options         KTRACE                          # ktrace(1) support
options         STACK                           # stack(9) support
options         SYSVSHM                         # SYSV-style shared memory
options         SYSVMSG                         # SYSV-style message queues
options         SYSVSEM                         # SYSV-style semaphores
options         P1003_1B_SEMAPHORES             # POSIX-style semaphores
options         _KPOSIX_PRIORITY_SCHEDULING     # POSIX P1003_1B real-time extensions
options         PRINTF_BUFR_SIZE=128            # Prevent printf output being interspersed
options         HWPMC_HOOKS                     # Necessary kernel hooks for hwpmc(4)
options         AUDIT                           # Security event auditing
options         MAC                             # TrustedBSD MAC Framework
options         FLOWTABLE                       # per-cpu routing cache
options         INCLUDE_CONFIG_FILE             # Include this file in kernel
options         SHMMAXPGS=65536
options         SEMMNI=40
options         SEMMNS=240
options         SEMUME=40
options         SEMMNU=120
options         ALTQ
options         ALTQ_CBQ
options         ALTQ_RED
options         ALTQ_RIO
options         ALTQ_HFSC
options         ALTQ_PRIQ
options         ALTQ_NOPCC
options         DEVICE_POLLING
options         HZ=1000
options         VESA
options         SC_PIXEL_MODE
options         SMP                             # Symmetric MultiProcessor Kernel
options         ATA_STATIC_ID                   # Static device numbering
options         KVA_PAGES=512
```

# sysctl

```
vfs.notbufdflashes: 0
vfs.flushbufqtarget: 100
vfs.getnewbufrestarts: 0
vfs.getnewbufcalls: 0
vfs.hifreebuffers: 796
vfs.lofreebuffers: 398
vfs.numfreebuffers: 7079
vfs.dirtybufthresh: 1610
vfs.hidirtybuffers: 1789
vfs.lodirtybuffers: 894
vfs.numdirtybuffers: 0
vfs.altbufferflushes: 0
vfs.dirtybufferflushes: 0
vfs.bufdefragcnt: 0
vfs.buffreekvacnt: 0
vfs.bufreusecnt: 0
vfs.hibufspace: 115326976
vfs.lobufspace: 115261440
vfs.maxmallocbufspace: 5766348
vfs.bufmallocspace: 0
vfs.maxbufspace: 115982336
vfs.bufspace: 0
vfs.runningbufspace: 0
vfs.reassignbufcalls: 0
```


----------



## wblock@ (May 29, 2011)

Because when top(1) shows Buf, it means UFS buffers and has no way to get that information from ZFS?  (Guessing, but I think it's a good guess.)


----------



## AndyUKG (May 30, 2011)

To get info on ZFS buffering etc you can install sysutils/zfs-stats.


----------



## superstack (May 31, 2011)

Thank you. I will try...


----------



## superstack (May 31, 2011)

So, is it normal? To not see the buffer in top(1)?


----------



## AndyUKG (May 31, 2011)

I think it's because you are using ZFS for all disks, so there is no UFS buffering. I think if the value of Buf is zero it will simply not show any data in top.


----------

