You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by bluestn <gi...@git.apache.org> on 2017/03/23 08:31:02 UTC

[GitHub] trafficserver issue #1603: if we had a server with big diskspace, function b...

GitHub user bluestn opened an issue:

    https://github.com/apache/trafficserver/issues/1603

    if we had a server with big diskspace, function build_vol_hash_table cost to much to build the vol_hash_table for CacheVol

      **if the Volume  space is 50TB, the rtable_size will be 50* 1000 * 1000 / 8=6250000,it cost too much memory and cpu usage( see the code in build_vol_hash_table listed below), maybe we need to optimize this build_vol_hash_table function.** 
    
      rtable_pair *rtable = (rtable_pair *)ats_malloc(sizeof(rtable_pair) * rtable_size);
      int rindex = 0;
      for (int i = 0; i < num_vols; i++)
        for (int j = 0; j < (int)rtable_entries[i]; j++) {
          rtable[rindex].rval = next_rand(&rnd[i]);
          rtable[rindex].idx = i;
          rindex++;
        }


----

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---