<?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: Creating a large file. in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978198#M419262</link>
    <description>Thanks</description>
    <pubDate>Wed, 10 May 2006 04:35:41 GMT</pubDate>
    <dc:creator>Prasad Joshi</dc:creator>
    <dc:date>2006-05-10T04:35:41Z</dc:date>
    <item>
      <title>Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978190#M419254</link>
      <description>Hi All,&lt;BR /&gt;&lt;BR /&gt;How can I create a file of size 3GB+?&lt;BR /&gt;&lt;BR /&gt;Thanks &amp;amp; regards,&lt;BR /&gt;Prasad.</description>
      <pubDate>Wed, 10 May 2006 03:05:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978190#M419254</guid>
      <dc:creator>Prasad Joshi</dc:creator>
      <dc:date>2006-05-10T03:05:15Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978191#M419255</link>
      <description>Hi Prasan,&lt;BR /&gt;&lt;BR /&gt;you can do while creating &lt;BR /&gt;&lt;BR /&gt;mkfs -F vxfs -o largefiles /dev/&lt;VGNAME&gt;/rlv&lt;BR /&gt;&lt;BR /&gt;or&lt;BR /&gt;&lt;BR /&gt;fsadm -F vxfs -o largefiles ...&lt;BR /&gt;&lt;BR /&gt;Chan&lt;/VGNAME&gt;</description>
      <pubDate>Wed, 10 May 2006 03:11:24 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978191#M419255</guid>
      <dc:creator>Chan 007</dc:creator>
      <dc:date>2006-05-10T03:11:24Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978192#M419256</link>
      <description>dd if=/dev/zero of=/var/tmp/three_gig+ bs=1024 count=$((3*1024*1024+1))</description>
      <pubDate>Wed, 10 May 2006 03:13:44 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978192#M419256</guid>
      <dc:creator>DRAXLER, Markus</dc:creator>
      <dc:date>2006-05-10T03:13:44Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978193#M419257</link>
      <description>Prasad,&lt;BR /&gt;see&lt;BR /&gt;man prealloc&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;prealloc testfile 3221225473</description>
      <pubDate>Wed, 10 May 2006 03:13:45 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978193#M419257</guid>
      <dc:creator>Peter Godron</dc:creator>
      <dc:date>2006-05-10T03:13:45Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978194#M419258</link>
      <description>Mark "0" for this&lt;BR /&gt;&lt;BR /&gt;man newfs, mkfs, fsadm&lt;BR /&gt;&lt;BR /&gt;My prev reply should be read as newfs not mkfs.&lt;BR /&gt;&lt;BR /&gt;Chan</description>
      <pubDate>Wed, 10 May 2006 03:15:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978194#M419258</guid>
      <dc:creator>Chan 007</dc:creator>
      <dc:date>2006-05-10T03:15:26Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978195#M419259</link>
      <description>Hi Prasad, &lt;BR /&gt;&lt;BR /&gt;Do you want to create file larger than 3 GB ? If yes, you can try this program, &lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;/*&lt;BR /&gt;* Assuming this is named largetest.c, build with:&lt;BR /&gt;* cc -o largetest largetest.c&lt;BR /&gt;*/&lt;BR /&gt;#include &lt;STDIO.H&gt;&lt;BR /&gt;#include &lt;SYS&gt;&lt;BR /&gt;#include &lt;SYS&gt;&lt;BR /&gt;#include &lt;FCNTL.H&gt;&lt;BR /&gt;#include &lt;UNISTD.H&gt;&lt;BR /&gt;#include &lt;ERRNO.H&gt;&lt;BR /&gt;#include &lt;STRING.H&gt;&lt;BR /&gt;#include &lt;SYS&gt;&lt;BR /&gt;&lt;BR /&gt;#define ERROR(x,y) { if ( (x) == -1) { perror(y); exit(errno); } }&lt;BR /&gt;&lt;BR /&gt;int main(int argn, char **argv)&lt;BR /&gt;{&lt;BR /&gt;const char *file;&lt;BR /&gt;int fd, len;&lt;BR /&gt;long long count;&lt;BR /&gt;ssize_t result;&lt;BR /&gt;long long offset;&lt;BR /&gt;struct timeval start, end, dif;&lt;BR /&gt;&lt;BR /&gt;if (argn &amp;lt; 2)&lt;BR /&gt;file = "largefile.junk";&lt;BR /&gt;else&lt;BR /&gt;file = argv[1];&lt;BR /&gt;&lt;BR /&gt;gettimeofday(&amp;amp;start, NULL);&lt;BR /&gt;&lt;BR /&gt;fd = open(file, O_CREAT | O_TRUNC | O_RDWR , 00644);&lt;BR /&gt;ERROR(fd, "Failed to open file");&lt;BR /&gt;&lt;BR /&gt;printf("Creating 3GB test file...\n");&lt;BR /&gt;count = (3*1024*1024*1024) - 1;&lt;BR /&gt;offset = lseek(fd, count, SEEK_CUR);&lt;BR /&gt;ERROR(offset, "Failed to set current offset");&lt;BR /&gt;&lt;BR /&gt;printf("Writting at 3GB...\n");&lt;BR /&gt;result = write(fd, "b", 1); /* Write data at 3GB point */&lt;BR /&gt;ERROR(result, "Failed to write at 3 GB mark");&lt;BR /&gt;&lt;BR /&gt;printf("Closing file...\n");&lt;BR /&gt;result = close(fd);&lt;BR /&gt;ERROR(result, "Failed to close file");&lt;BR /&gt;&lt;BR /&gt;gettimeofday(&amp;amp;end, NULL);&lt;BR /&gt;&lt;BR /&gt;timersub(&amp;amp;end, &amp;amp;start, &amp;amp;dif);&lt;BR /&gt;printf("Task took %ld.%ld sec to run.\n", dif.tv_sec, dif.tv_usec);&lt;BR /&gt;&lt;BR /&gt;printf("Done. Large file created.\n");&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;-Arun&lt;/SYS&gt;&lt;/STRING.H&gt;&lt;/ERRNO.H&gt;&lt;/UNISTD.H&gt;&lt;/FCNTL.H&gt;&lt;/SYS&gt;&lt;/SYS&gt;&lt;/STDIO.H&gt;</description>
      <pubDate>Wed, 10 May 2006 03:15:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978195#M419259</guid>
      <dc:creator>Arunvijai_4</dc:creator>
      <dc:date>2006-05-10T03:15:40Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978196#M419260</link>
      <description>Prasad,&lt;BR /&gt;&lt;BR /&gt;If you want to create a file greater than 2Gb then you need the largefiles option on your filesystem when it was created and then while mounting it. Chan has already given you the commands.&lt;BR /&gt;I think thats the info you are looking for. But when you say you want to create a file of size 3GB+, if you mean how you can reserve some space for a file - then you can do a prealloc filename size(in bytes)&lt;BR /&gt;to reserver that much space for a file. This essentially creates a file with nulls making it the size you specified - But I am not sure if this is waht you want.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Ninad</description>
      <pubDate>Wed, 10 May 2006 03:18:34 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978196#M419260</guid>
      <dc:creator>Ninad_1</dc:creator>
      <dc:date>2006-05-10T03:18:34Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978197#M419261</link>
      <description>Hi All,&lt;BR /&gt;&lt;BR /&gt;I have created file system with largefile support and also mounted with large file support.&lt;BR /&gt;&lt;BR /&gt;I wanted to create some largefiles on them for testing purpose.&lt;BR /&gt;&lt;BR /&gt;Thanks for your help.&lt;BR /&gt;&lt;BR /&gt;Thanks &amp;amp; regards,&lt;BR /&gt;Prasad.</description>
      <pubDate>Wed, 10 May 2006 03:56:56 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978197#M419261</guid>
      <dc:creator>Prasad Joshi</dc:creator>
      <dc:date>2006-05-10T03:56:56Z</dc:date>
    </item>
    <item>
      <title>Re: Creating a large file.</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978198#M419262</link>
      <description>Thanks</description>
      <pubDate>Wed, 10 May 2006 04:35:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/creating-a-large-file/m-p/4978198#M419262</guid>
      <dc:creator>Prasad Joshi</dc:creator>
      <dc:date>2006-05-10T04:35:41Z</dc:date>
    </item>
  </channel>
</rss>

