12-14-2006
Creat a File with a Specific Size
Hi everybody,
Is there a command that can create a new file with a specific size?
Thanks in advance.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hello,
In my shell program, I need to test for a specific size of a text file before it can be imported into an oracle table.
If the size is less than that number, my program should stop processing. What is the correct command to do this test?
Thanks! (1 Reply)
Discussion started by: GEBRAUN
1 Replies
2. Shell Programming and Scripting
I've been working on getting a script to take size, dir name and file name variables from an input file and creating the same dir structure along with the file of specific size.
An example of the input file:
size/dirname/filename
2100/JAN_06/12345ABC.TCC
2354/FEB_06/24564XYZ.NOS... (2 Replies)
Discussion started by: nxd25
2 Replies
3. Shell Programming and Scripting
As I'm a newbie to UNIX, very newbie in fact, could anyone humour me and tell me how I'd find just the file size in bytes for a specific file?
Or at least just the specific line from the ls -a for the file - call it file1
I know this sounds bad but I don't seem to be getting very far at this... (3 Replies)
Discussion started by: nortypig
3 Replies
4. Solaris
hi all,
in my server there are some specific application files which are spread through out the server... these are spread in folders..sub-folders..chid folders...
please help me, how can i find the total size of these specific files in the server... (3 Replies)
Discussion started by: abhinov
3 Replies
5. Shell Programming and Scripting
Hi all,
I am very new in programming.
Can anyone please help me in the matter below?
I have one raw file like:
gi|77|ref|NC_002971.3| Coxiella burnetii RSA 493, complete genome 6371 ATCGTGGTTGTGGTTCAT 5032 P 2 12
gi|71|ref|NC_005773.3| Pseudomonas syringae pv.... (4 Replies)
Discussion started by: iammitra
4 Replies
6. UNIX for Dummies Questions & Answers
Hello dear unix command line friends !
I'm looking for a simple combinaison of ls & awk (maybe grep) to print:
list of folders of a directory
|_ ordered by size
like what I have with
$ du -sk ./* | sort -rn
printing that result:
8651520 ./New Virtual Machine_1
8389120 ./Redhat
... (1 Reply)
Discussion started by: holister
1 Replies
7. UNIX for Dummies Questions & Answers
Hello world,
I just learnt we can create a directory with custom size in a Linux server (say Redhat). Is it true? I'm asking because the only data (I can think of) a directory's inode holds is the files and 'sub-dir's. How can a new empty directory be of some required size? :wall:
PS : In... (2 Replies)
Discussion started by: satish51392111
2 Replies
8. UNIX for Dummies Questions & Answers
Hi ,
i have some files of specific pattern ...i need to look for files which are having size greater than zero and move those files to another directory..
Ex...
abc_0702,
abc_0709,
abc_782
abc_1234 ...etc
need to find out which is having the size >0 and move those to target directory..... (7 Replies)
Discussion started by: dssyadav
7 Replies
9. HP-UX
Dear,
Can anyone inform me the command to view specific file size in megabyte in hp-ux? (2 Replies)
Discussion started by: makauser
2 Replies
10. UNIX for Beginners Questions & Answers
There is away to make a window pane a specific size. I just forgot how to do it.
Something like this:
Ctrl-A : split-window -l xx -h xx
Anyone know the right way to do this?
Thanks. (1 Reply)
Discussion started by: ignatius
1 Replies
LEARN ABOUT POSIX
mkfs_udfs
mkfs_udfs(1M) System Administration Commands mkfs_udfs(1M)
NAME
mkfs_udfs - construct a udfs file system
SYNOPSIS
mkfs -F udfs [generic_options] [-o specific_options] raw_device_file [size]
DESCRIPTION
This is the universal disk format file system (udfs) -specific module of the mkfs command. mkfs constructs a udfs file system with a root
directory.
OPTIONS
See mkfs(1M) for the list of supported generic_options.
The following options are supported:
-o specific_options Specify a udfs-specific option. Specify udfs file system specific options in a comma-separated list with no inter-
vening spaces. If invalid options are specified, a warning message is printed and the invalid options are ignored.
The following specific_options are available:
N
Print the file system parameters without actually creating the file system.
label=string
Specify the label to be written into the volume header structures. Specify string as the name of the label. If
string is not specified, a default string is generated in the form of *NoLabel*.
OPERANDS
The following operands are supported:
raw_device_file Specify the disk partition on which to write.
size Specify the number of 512-byte blocks in the file system.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWudf |
+-----------------------------+-----------------------------+
SEE ALSO
fsck(1M),mkfs(1M), attributes(5)
DIAGNOSTICS
not currently a valid file system
The specified device does not contain a valid udfs file system.
Invalid size: larger than the partition size
Number of blocks given as parameter to create the file system is larger than the size of the device specified.
is mounted can't mkfs
Device is in use, cannot create file system when the device is in use.
preposterous size
Negative size parameter provided is invalid.
sector size must be between 512, 8192 bytes
Sector size given is not in the valid range.
Volume integrity sequence descriptors too long
File set descriptor too long.
Not enough space to create volume integrity sequence or file set descriptor.
mkfs: argument out of range
One of the arguments is out of range.
mkfs: bad numeric arg
One of the arguments is potentially a bad numeric.
NOTES
You can use lofiadm to create a file that appears to a mkfs command (for example, mkfs_pcfs or mkfs_ufs) as a raw device. You can then use
a mkfs command to create a file system on that device. See lofiadm(1M) for examples of creating a UFS and a PC (FAT) file system on a
device created by lofiadm.
SunOS 5.10 17 Nov 2000 mkfs_udfs(1M)