<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: testing largefiles in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468346#M16167</link>
    <description>you can use the prealloc command that preallocates at laeast size bites of disk space for a file.&lt;BR /&gt;&lt;BR /&gt;If the option largefiles is set your system will be able to use files greater than 2GBs and so you should test this fact typing:&lt;BR /&gt;&lt;BR /&gt;prealloc file-test 2100000000&lt;BR /&gt;&lt;BR /&gt;Federico</description>
    <pubDate>Wed, 29 Nov 2000 09:00:31 GMT</pubDate>
    <dc:creator>federico_3</dc:creator>
    <dc:date>2000-11-29T09:00:31Z</dc:date>
    <item>
      <title>testing largefiles</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468343#M16164</link>
      <description>Hi, &lt;BR /&gt;&lt;BR /&gt;is there a way to easily create a massive file so I can test out that largefiles is working on my new lvols ?</description>
      <pubDate>Wed, 29 Nov 2000 08:48:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468343#M16164</guid>
      <dc:creator>Jim Smith</dc:creator>
      <dc:date>2000-11-29T08:48:53Z</dc:date>
    </item>
    <item>
      <title>Re: testing largefiles</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468344#M16165</link>
      <description>&lt;BR /&gt;Use the prealloc command. eg. to create a 2.5Gb file to test out if largefiles is on;  prealloc testfile 2500000000&lt;BR /&gt;&lt;BR /&gt;If prealloc returns the error; file too large  you know you havent got largefiles on.</description>
      <pubDate>Wed, 29 Nov 2000 08:55:43 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468344#M16165</guid>
      <dc:creator>Carol Garrett</dc:creator>
      <dc:date>2000-11-29T08:55:43Z</dc:date>
    </item>
    <item>
      <title>Re: testing largefiles</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468345#M16166</link>
      <description>&lt;BR /&gt;Prealloc is the command to use. See man page on it. If will take some time to create such a large file though so be patient.</description>
      <pubDate>Wed, 29 Nov 2000 09:00:10 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468345#M16166</guid>
      <dc:creator>Stefan Farrelly</dc:creator>
      <dc:date>2000-11-29T09:00:10Z</dc:date>
    </item>
    <item>
      <title>Re: testing largefiles</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468346#M16167</link>
      <description>you can use the prealloc command that preallocates at laeast size bites of disk space for a file.&lt;BR /&gt;&lt;BR /&gt;If the option largefiles is set your system will be able to use files greater than 2GBs and so you should test this fact typing:&lt;BR /&gt;&lt;BR /&gt;prealloc file-test 2100000000&lt;BR /&gt;&lt;BR /&gt;Federico</description>
      <pubDate>Wed, 29 Nov 2000 09:00:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468346#M16167</guid>
      <dc:creator>federico_3</dc:creator>
      <dc:date>2000-11-29T09:00:31Z</dc:date>
    </item>
    <item>
      <title>Re: testing largefiles</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468347#M16168</link>
      <description>&lt;BR /&gt;Thanks for the fast replies everyone!</description>
      <pubDate>Wed, 29 Nov 2000 09:06:53 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468347#M16168</guid>
      <dc:creator>Jim Smith</dc:creator>
      <dc:date>2000-11-29T09:06:53Z</dc:date>
    </item>
    <item>
      <title>Re: testing largefiles</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468348#M16169</link>
      <description>Hello all,&lt;BR /&gt;&lt;BR /&gt;My problem with prealloc is that it only writes nulls.&lt;BR /&gt;Not very good if you're testing compression, encryption, or file transfer stuff.&lt;BR /&gt;&lt;BR /&gt;Here's a program I wrote that generates big files with lots of random characters.&lt;BR /&gt;NOTE: It writes to stdout.  Be sure to redirect&lt;BR /&gt;stdout into a file, otherwise it could screw up&lt;BR /&gt;your terminal window.  (Lots of random garbage&lt;BR /&gt;has a habbit of doing that.)&lt;BR /&gt;&lt;BR /&gt;To compile:&lt;BR /&gt;  /opt/ansic/bin/cc bigfile.c -o bigfile&lt;BR /&gt;or&lt;BR /&gt;  gcc bigfile.c -o bigfile&lt;BR /&gt;&lt;BR /&gt;To run:&lt;BR /&gt;  ./bigfile 21 M R &amp;gt; /tmp/21meg_file_of_random&lt;BR /&gt;  ./bigfile 21 M &amp;gt; /tmp/21meg_file_of_sequential&lt;BR /&gt;&lt;BR /&gt;===== cut here =====&lt;BR /&gt;#include &lt;STDLIB.H&gt;&lt;BR /&gt;#include &lt;STDIO.H&gt;&lt;BR /&gt;#define MAXBUF 400000&lt;BR /&gt;&lt;BR /&gt;Usage(Filename)&lt;BR /&gt;  char *Filename;&lt;BR /&gt;{&lt;BR /&gt;  fprintf(stderr,"Script to write a file of random characters.\n");&lt;BR /&gt;  fprintf(stderr,"Usage:  %s filesize [B|K|M|G] [R]\n",Filename);&lt;BR /&gt;  fprintf(stderr,"Specify R on the end for random, rather than sequential.\n");&lt;BR /&gt;  fprintf(stderr,"Example: %s 15 K\n",Filename);&lt;BR /&gt;  exit(-1);&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;int main(argc,argv)&lt;BR /&gt;  int argc; char *argv[];&lt;BR /&gt;{&lt;BR /&gt;  long FileSize;&lt;BR /&gt;  char Scale;&lt;BR /&gt;  long ScaleNum;&lt;BR /&gt;  char Buf[MAXBUF];&lt;BR /&gt;  int BufLen;&lt;BR /&gt;  int RandomFlag=0;&lt;BR /&gt;&lt;BR /&gt;  if (argc &amp;lt; 2) Usage(argv[0]);&lt;BR /&gt;  if (argc &amp;gt; 4) Usage(argv[0]);&lt;BR /&gt;  if (argc == 2)  Scale='K';&lt;BR /&gt;  else&lt;BR /&gt;        {&lt;BR /&gt;        Scale=argv[2][0];&lt;BR /&gt;        if (islower(Scale)) Scale=toupper(Scale);&lt;BR /&gt;        }&lt;BR /&gt;  FileSize = atol(argv[1]);&lt;BR /&gt;  if (argv[argc-1][0]=='R') RandomFlag=1;&lt;BR /&gt;&lt;BR /&gt;  switch(Scale)&lt;BR /&gt;    {&lt;BR /&gt;    case 'K':   ScaleNum=1024; break;&lt;BR /&gt;    case 'M':   ScaleNum=1024*1024; break;&lt;BR /&gt;    case 'G':   ScaleNum=1024*1024*1024; break;&lt;BR /&gt;    default:&lt;BR /&gt;        Scale='B';&lt;BR /&gt;    case 'B':   ScaleNum=1; break;&lt;BR /&gt;    }&lt;BR /&gt;&lt;BR /&gt;  fprintf(stderr,"Generating file size %ld%c ",FileSize,Scale);&lt;BR /&gt;  FileSize *= ScaleNum;&lt;BR /&gt;  fprintf(stderr,"(%ld bytes)\n",FileSize);&lt;BR /&gt;&lt;BR /&gt;  /* dump the data */&lt;BR /&gt;  srand(time(NULL));&lt;BR /&gt;  BufLen=0;&lt;BR /&gt;  while(FileSize)&lt;BR /&gt;    {&lt;BR /&gt;    if (RandomFlag)&lt;BR /&gt;      {&lt;BR /&gt;      fputc(rand()%256,stdout);&lt;BR /&gt;      Buf[BufLen] = (rand()%256);&lt;BR /&gt;      }&lt;BR /&gt;    else&lt;BR /&gt;      {&lt;BR /&gt;      Buf[BufLen] = (BufLen%256);&lt;BR /&gt;      BufLen++;&lt;BR /&gt;      if (BufLen &amp;gt;= MAXBUF)&lt;BR /&gt;        {&lt;BR /&gt;        write(1,Buf,BufLen);&lt;BR /&gt;        BufLen=0;&lt;BR /&gt;        }&lt;BR /&gt;      }&lt;BR /&gt;    FileSize--;&lt;BR /&gt;    }&lt;BR /&gt;&lt;BR /&gt;  if (BufLen &amp;gt; 0)       write(1,Buf,BufLen);&lt;BR /&gt;  return(0);&lt;BR /&gt;}&lt;BR /&gt;&lt;/STDIO.H&gt;&lt;/STDLIB.H&gt;</description>
      <pubDate>Thu, 30 Nov 2000 20:01:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/testing-largefiles/m-p/2468348#M16169</guid>
      <dc:creator>Neal Krawetz</dc:creator>
      <dc:date>2000-11-30T20:01:26Z</dc:date>
    </item>
  </channel>
</rss>

