For small files:
dd if=/dev/zero of=upload_test bs=file_size count=1
Where file_size
is the size of your test file in bytes.
For big files:
dd if=/dev/zero of=upload_test bs=1M count=size_in_megabytes
More Related Contents:
- How to change the output color of echo in Linux
- How do I send a file as an email attachment using Linux command line?
- How can I search for a multiline pattern in a file?
- What’s the magic of “-” (a dash) in command-line parameters?
- What does the number in parentheses shown after Unix command names in manpages mean?
- Peak memory usage of a linux/unix process [closed]
- Find and replace with sed in directory and sub directories
- Automatically capture output of last command into a variable using Bash?
- How to find out line-endings in a text file?
- How do I use the lines of a file as arguments of a command?
- Get most recent file in a directory on Linux
- Using curl to send email
- Linux command to print directory structure in the form of a tree
- How can I generate a list of files with their absolute path in Linux?
- How to count lines in a document? [closed]
- Perl command line multi-line replace
- GROUP BY/SUM from shell
- Linux command to list all available commands and aliases
- How to recursively download a folder via FTP on Linux [closed]
- How to reset Jenkins security settings from the command line?
- extracting unique values between 2 sets/files
- Is there a way to get gcc to output raw binary?
- Execute command after every command in bash
- How can I remove the BOM from a UTF-8 file? [duplicate]
- How do you filter out all unique lines in a file?
- Execute combine multiple Linux commands in one line
- View tabular file such as CSV from command line [closed]
- How can I get the resolution (width and height) for a video file from a linux command line?
- Why no output is shown when using grep twice?
- Search and replace with sed when dots and underscores are present