Sponsored Content
Full Discussion: Synchronising cache and file
Top Forums Programming Synchronising cache and file Post 302997178 by sundaresh on Tuesday 9th of May 2017 05:36:38 AM
Old 05-09-2017
Synchronising cache and file

I am reading and caching some of the blocks of a large data file into program
virtual memory, for processing. My question is how do I synchronise this
cache with the file, for instance, if a block in the cache is updated or written to,
that block has to be updated in the underlying file. If this process is delayed
or only partly completed, will not the file be inconsistent. This can happen
if there is a power failure. How is this problem handled by DBMS programs ?
I am programming in C. Any answers and references to good books or readily available reading material on this subject will be gratefully appreciated.
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

UBC cache vs. Metadata cache

hi, What is the difference between UBC cache and Metadata cache ? where can i find UBC cache Hits and Metadata cache Hits in hp-ux? Advanced thanx for the help. (2 Replies)
Discussion started by: sushaga
2 Replies

2. Linux

Nagios objects.cache file

Another nagios problem: I have this file: -rw-r----- 1 nagios nagios 21220 jun 9 17:29 objects.cache As you can see with rights at 640, nagios cannot read the file for configuration. I have to manually change the rights to 644 almost everyday. How can i get the rights to stay at 644? ... (1 Reply)
Discussion started by: penguin-friend
1 Replies

3. AIX

Why is my file system cache so large

Hi I have a filesystem cache which is around 20G in size and I'm a bit perplexed as to what is in it. I'm running Sybase on the machine with the db on raw volumes and a tempdb on a ramdisk. My understanding is that raw volumes are not cached and I assumed that the ramdisk is not either. Am... (1 Reply)
Discussion started by: mgibbons
1 Replies

4. Solaris

Solaris File Cache

I started a previous thread : https://www.unix.com/sun-solaris/76721-coredumps-swap-part-solaris-mem-consumption.html But my fault as there is no xml feed for this forum i lost track and thread got closed. So in the mean time i went through some docs and here are my queries : 1. mdb -k... (2 Replies)
Discussion started by: rajwinder
2 Replies

5. Solaris

File cache portion of memory on Solaris

I'm looking to get the file cache portion of physical (real) memory on a Solaris workstation (Similar to the Cache: line in /proc/meminfo on some Linux systems): # swap -s; swap -l; vmstat 2 2; echo "::memstat" | mdb -k total: 309376k bytes allocated + 41428k reserved = 350804k used,... (5 Replies)
Discussion started by: Devyn
5 Replies

6. Linux

getting info on Cache Size, Data Cache etc..

Hi all I saw in Microsoft web site www.SysInternals.com a tool called CoreInfo from able to print out on screen the size of the Data and Instruction caches of your processor, the Locigal to Physical Processor mapping, the number of the CPU sockets. etc.. Do you know if in Linux is available a... (2 Replies)
Discussion started by: manustone
2 Replies

7. Solaris

Zfs::zpool.cache file

Hi All, I am trying to read zpool.cache file to find out pool information like pool name, devices it uses and all properties. File seems to be in packed format.I am not sure how to unpack it. But from opensolaris code base we can see that they have used libz for uncompromising this file, but... (0 Replies)
Discussion started by: shailesh_111
0 Replies

8. Linux

File cache /Page cache Linux

Hi All, could any one point out any open source test-suites for "File cache" testing and as well as performance test suites for the same. Currently my system is up with Linux/ext4. Regards Manish (0 Replies)
Discussion started by: hmanish
0 Replies

9. Red Hat

Path of the DNS Cache file

We have a DNS server that is only using as a cache DNS of parent server. I wonder where it the cache file that it created from parent DNS? Please tell me where will be the cache file? (0 Replies)
Discussion started by: abhilashkrishn
0 Replies

10. UNIX for Advanced & Expert Users

Rsync - delete extra files in Destination without synchronising directories

I have a script that synchronises a directory to a DR server, but to improve the time, I actually use rsync to transfer files * in one batch and also * in another batch - both batches run from the same script and run in the background. My problem is that there isn't much space on the... (1 Reply)
Discussion started by: Catullus
1 Replies
WINCACHE_UCACHE_MEMINFO(3)						 1						WINCACHE_UCACHE_MEMINFO(3)

wincache_ucache_meminfo - Retrieves information about user cache memory usage

SYNOPSIS
array wincache_ucache_meminfo (void ) DESCRIPTION
Retrieves information about memory usage by user cache. RETURN VALUES
Array of meta data about user cache memory usage or FALSE on failure The array returned by this function contains the following elements: o memory_total - amount of memory in bytes allocated for the user cache o memory_free - amount of free memory in bytes available for the user cache o num_used_blks - number of memory blocks used by the user cache o num_free_blks - number of free memory blocks available for the user cache o memory_overhead - amount of memory in bytes used for the user cache internal structures EXAMPLES
Example #1 A wincache_ucache_meminfo(3) example <pre> <?php print_r(wincache_ucache_meminfo()); ?> </pre> The above example will output: Array ( [memory_total] => 5242880 [memory_free] => 5215056 [num_used_blks] => 6 [num_free_blks] => 3 [memory_overhead] => 176 ) SEE ALSO
wincache_fcache_fileinfo(3), wincache_fcache_meminfo(3), wincache_ocache_fileinfo(3), wincache_rplist_fileinfo(3), wincache_rplist_mem- info(3), wincache_refresh_if_changed(3), wincache_ucache_info(3), wincache_scache_info(3), wincache_scache_meminfo(3). PHP Documentation Group WINCACHE_UCACHE_MEMINFO(3)
All times are GMT -4. The time now is 07:35 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy