PHP Classes

Find Large Files: I need to find large files on a server

Recommend this page to a friend!
  All requests RSS feed  >  Find Large Files  >  Request new recommendation  >  A request is featured when there is no good recommended package on the site when it is posted. Featured requests  >  No recommendations No recommendations  

Find Large Files

Edit

Picture of Gerry Danen by Gerry Danen - 9 years ago (2015-10-07)

I need to find large files on a server

This request is clear and relevant.
This request is not clear or is not relevant.

+5

Is there a class that will traverse an entire server and list all files over a certain (5MB, for example) size?

Ask clarification

3 Recommendations

PHP Filesystem Helper Library: Manipulate and search files and directories

This class can manipulate and search files and directories.

It can create directories, read and write, as well and delete files and folders recursively using PHP iterator classes.

The class can also search for files inside given directories recursively using regular expressions to filter the file names.
This recommendation solves the problem.
This recommendation does not solve the problem.

+3

Picture of Joshua McKenzie by Joshua McKenzie package author package author Reputation 75 - 9 years ago (2015-12-07) Comment

To give another variety, PHP5 Iterators, Regex supported, Composer ready To find files above a certain size, when looping the search results, simply use the $file->getSize() method provided with the DirectoryIterator class.


PHP SPL File Find: SPL iterator to find files with different criteria

This package implements SPL iterators to find files with different criteria.

It can take a path a directory to traverse to start finding files.

There are additional iterator classes to sort files by name, sort by type, sort by last access time, sort by last change time, to filter files with a given file name extension, filter only files or only directories, and to limit the number of found files, or limit by directory depth or file size.
This recommendation solves the problem.
This recommendation does not solve the problem.

+3

Picture of Ravi Kumar by Ravi Kumar package author package author Reputation 100 - 9 years ago (2015-10-18) Comment

The in() method lists all the files in a given directory, and returns an array of the names. You can filter out which files you want with a size() method. see example

$find = new Find; Filter files by size $files = $find->size('>50m')->in( $path );


File Display: Displays listings of files and directories

This class is meant to output listings of files and sub-directories of a given directory using HTML tables.

It can be configured to display or not display several types of information such as: file size, file/folder permissions, last modified date, etc..

It may restrict the listing of files based on the file name extension. Currently, the default is to allow showing only image files: GIF, JPEG and PNG.

It may also show different icons with files depending on their file name extension.
This recommendation solves the problem.
This recommendation does not solve the problem.

+6

Picture of Dave Smith by Dave Smith Reputation 7620 - 9 years ago (2015-10-09) Comment

Looks like this one will do it with a little modification. It currently has a method that filters out any file that is not an image which can be changed and it does list file size which should be able to be used as the filter instead.

  • 1 Comment
  • 1. Picture of Gerry Danen by Gerry Danen - 9 years ago (2015-10-09) Reply

    Thanks, Dave. I believe that will indeed do the trick.


Recommend package
: 
: