Smart questions
Smart answers
Smart people
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Member Login




Remember Me
Forgot Password?
Join Us!

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips now!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

Join Tek-Tips
*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Donate Today!

Do you enjoy these
technical forums?
Donate Today! Click Here

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.
Jobs from Indeed

Link To This Forum!

Partner Button
Add Stickiness To Your Site By Linking To This Professionally Managed Technical Forum.
Just copy and paste the
code below into your site.

lindefl (MIS)
6 Oct 00 17:00
I would like to create a dummy file on a file system to verify that the file system can handle this size of a file.  I thought I could do this with the dd command using if=/dev/null of=/targetdirectory.
But I don't know how to tell it to put 2G of lovalues in the file.   I know there is a way - but maybe it is not using the dd command.  Anyone with an idea ?  I have already tried adding the dd options of count= and iblks=
Thanks.
MikeLacey (MIS)
6 Oct 00 21:38
ok....

you could write a Perl script to create a large file, something like this would do it.

#!/usr/bin/perl -w

my $buf = ' ' x (1024 * 1024);
my $i;

open(F,'>mybigfile') || die "can't open file\n$!\n";

for($i=0;$i<2048;$i++){
  print F $buf;
}

close(F);

Mike
michael.j.lacey@ntlworld.com
Cargill's Corporate Web Site
Making mistakes, so you don't have to. <grin>

Helpful Member!(2)  ElgisRamon (MIS)
9 Oct 00 11:22
Don't need PERL to do that, simply use

dd if=/dev/zero of=/your/new/filename bs=1m count=4


First... when you read from /dev/null nothing goes out, but /dev/zero generates a continuous stream of zeroes. Give it a input and output block size of 1MB with bs=1m (you can use k to specify KiloBytes, and b to specify blocks).

I hope it works...
lindefl (MIS)
9 Oct 00 11:37
Thanks - the dd=/dev/zero .... worked fine.  
odey (TechnicalUser)
10 Oct 00 5:30
Hi guys
    there is a command in aix that creates a file with null characters its is lmktemp. the syntax is lmktemp filename size-of-file in bytes eg to create a 100 byte file called test. You type lmktemp test 100.

Let us know of the outcome.

regards

odey
lindefl (MIS)
16 Oct 00 9:49
The lmktemp worked fine - actually faster than the dd command.  Thanks.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Back To Forum

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close