# Patent

## Title
Notification for a distributed file system

## Abstract

A method for notifying an application coupled to a distributed file system is described. A command for a file for a distributed file system is received. The distributed file system stores portions of files across a plurality of distinct physical storage locations. The command for the file is compared with a notification table of the distributed file system of the distributed file system. At least one application communicates with the distributed file system. The notification system notifies the corresponding application associated with the command with the notification system.

## Background
TECHNICAL FIELD
An embodiment of the invention is generally directed to electronic data storage systems, and more particularly to scalable data storage systems.
BACKGROUND
In today's information intensive environment, there are many businesses and other institutions that need to store huge amounts of digital data. These include entities such as large corporations that store internal company information to be shared by thousands of networked employees; online merchants that store information on millions of products; and libraries and educational institutions with extensive literature collections. A more recent need for the use of large-scale data storage systems is in the broadcast television programming market. Such businesses are undergoing a transition, from the older analog techniques for creating, editing and transmitting television programs, to an all-digital approach. Not only is the content (such as a commercial) itself stored in the form of a digital video file, but editing and sequencing of programs and commercials, in preparation for transmission, are also digitally processed using powerful computer systems. Other types of digital content that can be stored in a data storage system include seismic data for earthquake prediction, and satellite imaging data for mapping.
To help reduce the overall cost of the storage system, a distributed architecture is used. Hundreds of smaller, relatively low cost, high volume manufactured disk drives (currently each disk drive unit has a capacity of one hundred or more Gbytes) may be networked together, to reach the much larger total storage capacity. However, this distribution of storage capacity also increases the chances of a failure occurring in the system that will prevent a successful access. Such failures can happen in a variety of different places, including not just in the system hardware (e.g., a cable, a connector, a fan, a power supply, or a disk drive unit), but also in software such as a bug in a particular client application program. Storage systems have implemented redundancy in the form of a redundant array of inexpensive disks (RAID), so as to service a given access (e.g., make the requested data available), despite a disk failure that would have otherwise thwarted that access. The systems also allow for rebuilding the content of a failed disk drive, into a replacement drive.
Applications operating on a typical storage system may consume networking and processing bandwidth. For example, to detect new material appearing on a typical storage system, a scanning tool needs to continuously scan the storage system for the new material. This scanning process consumes network and processing bandwidth. It further introduces latency from the time the new material is stored on the storage system to the time the scanning tool detects the new material through its scanning process.



BRIEF DESCRIPTION OF THE DRAWINGS
The present invention is illustrated by way of example, and not by way of limitation, in the figures of the accompanying drawings.
FIG. 1 shows a data storage system, in accordance with an embodiment of the invention, in use as part of a video processing environment.
FIG. 2 shows a system architecture for the data storage system, in accordance with one embodiment.
FIGS. 3A and 3B show a network topology for an embodiment of the data storage system.
FIG. 4 shows a software architecture for the data storage system, in accordance with one embodiment.
FIG. 5A is a block diagram illustrating a notification system of a distributed file system in accordance with one embodiment.
FIG. 5B is a block diagram illustrating a table of the notification system of a distributed file system in accordance with one embodiment.
FIG. 6 is a flow diagram illustrating a method for notifying an application coupled to a distributed file system in accordance with one embodiment.



DETAILED DESCRIPTION
The following description sets forth numerous specific details such as examples of specific systems, components, methods, and so forth, in order to provide a good understanding of several embodiments of the present invention. It will be apparent to one skilled in the art, however, that at least some embodiments of the present invention may be practiced without these specific details. In other instances, well-known components or methods are not described in detail or are presented in simple block diagram format in order to avoid unnecessarily obscuring the present invention. Thus, the specific details set forth are merely exemplary. Particular implementations may vary from these exemplary details and still be contemplated to be within the spirit and scope of the present invention.
Embodiments of the present invention include various operations, which will be described below. These operations may be performed by hardware components, software, firmware, or a combination thereof. As used herein, the term “coupled to” may mean coupled directly or indirectly through one or more intervening components. Any of the signals provided over various buses described herein may be time multiplexed with other signals and provided over one or more common buses. Additionally, the interconnection between circuit components or blocks may be shown as buses or as single signal lines. Each of the buses may alternatively be one or more single signal lines and each of the single signal lines may alternatively be buses.
Certain embodiments may be implemented as a computer program product that may include instructions stored on a machine-readable medium. These instructions may be used to program a general-purpose or special-purpose processor to perform the described operations. A machine-readable medium includes any mechanism for storing or transmitting information in a form (e.g., software, processing application) readable by a machine (e.g., a computer). The machine-readable medium may include, but is not limited to, magnetic storage medium (e.g., floppy diskette); optical storage medium (e.g., CD-ROM); magneto-optical storage medium; read-only memory (ROM); random-access memory (RAM); erasable programmable memory (e.g., EPROM and EEPROM); flash memory; electrical, optical, acoustical, or other form of propagated signal (e.g., carrier waves, infrared signals, digital signals, etc.); or another type of medium suitable for storing electronic instructions.
Additionally, some embodiments may be practiced in distributed computing environments where the machine-readable medium is stored on and/or executed by more than one computer system. In addition, the information transferred between computer systems may either be pulled or pushed across the communication medium connecting the computer systems.
Embodiments of a method and apparatus are described to notify one or more applications coupled to a data storage system of a change to a file or an addition of a new file. In one embodiment, the notification system of the distributed file system communicates with one or more applications.
FIG. 1 illustrates one embodiment of a data storage system 100 in use as part of a video processing environment. It should be noted, however, that the data storage system 100 as well as its components or features described below can alternatively be used in other types of applications (e.g., a literature library; seismic data processing center; merchant's product catalog; central corporate information storage; etc.) The data storage system 100 provides data protection, as well as hardware and software fault tolerance and recovery.
The data storage system 100 includes media servers 102 and a content library 104. Media servers 102, 106, 108 may be composed of a number of software components that are running on a network of server machines. The server machines communicate with the content library 104 including mass storage devices such as rotating magnetic disk drives that store the data. The server machines accept requests to create, write or read a file, and manages the process of transferring data into one or more disk drives in the content library 104, or delivering requested read data from them. The server machines keep track of which file is stored in which drive. Requests to access a file, i.e. create, write, or read, are typically received from what is referred to as a client application program that may be running on a client machine connected to the server network. For example, the application program may be a video editing application running on a workstation of a television studio, that needs a particular video clip (stored as a digital video file in the system).
Video data is voluminous, even with compression in the form of, for example, Motion Picture Experts Group (MPEG) formats. Accordingly, data storage systems for such environments are designed to provide a storage capacity of at least tens of terabytes or greater. Also, high-speed data communication links are used to connect the server machines of the network, and in some cases to connect with certain client machines as well, to provide a shared total bandwidth of one hundred Gb/second and greater, for accessing the data storage system 100. The storage system is also able to service accesses by multiple clients simultaneously.
The data storage system 100 can be accessed using client machines that can take a variety of different forms. For example, content files (in this example, various types of digital media files including MPEG and high definition (HD)) can be requested by media server 102 which as shown in FIG. 1 can interface with standard digital video cameras, tape recorders, and a satellite feed during an “ingest” phase 110 of the media processing. As an alternative, the client machine may be on a remote network, such as the Internet. In a “production” phase 112, stored files can be streamed to client machines for browsing 116, editing 118, and archiving 120. Modified files may then be sent to media servers 106, 108 or directly through a remote network 124 for distribution, during a “playout” phase 114.
The data storage system 100 provides a relatively high performance, high availability storage subsystem with an architecture that may prove to be particularly easy to scale as the number of simultaneous client accesses increase or as the total storage capacity requirement increases. The addition of media servers 102, 106, 108 (as in FIG. 1) and a content gateway (not shown) enables data from different sources to be consolidated into a single high performance/high availability system, thereby reducing the total number of storage units that a business must manage. In addition to being able to handle different types of workloads (including different sizes of files, as well as different client loads), an embodiment of the system may have features including automatic load balancing, a high speed network switching interconnect, data caching, and data replication. According to an embodiment, the data storage system 100 scales in performance as needed from 20 Gb/second on a relatively small, or less than 66 terabyte system, to over several hundred Gb/second for larger systems, that is, over 1 petabyte. For a directly connected client, this translates into, currently, a minimum effective 60 megabyte per second transfer rate, and for content gateway attached clients, a minimum 40 megabytes per second. Such numbers are, of course, only examples of the current capability of the data storage system 100, and are not intended to limit the full scope of the invention being claimed.
In accordance with an embodiment, the data storage system 100 may be designed for non-stop operation, as well as allowing the expansion of storage, clients and networking bandwidth between its components, without having to shutdown or impact the accesses that are in process. The data storage system 100 preferably has sufficient redundancy that there is no single point of failure. Data stored in the content library 104 has multiple replications, thus allowing for a loss of mass storage units (e.g., disk drive units) or even an entire server, without compromising the data. In the different embodiments of the invention, data replication, for example, in the event of a disk drive failure, is considered to be relatively rapid, and without causing any noticeable performance degradation on the data storage system 100 as a whole. In contrast to a typical RAID system, a replaced drive unit of the data storage system 100 may not contain the same data as the prior (failed) drive. That is because by the time a drive replacement actually occurs, the re-replication process will already have started re-replicating the data from the failed drive onto other drives of the system 100.
In addition to mass storage unit failures, the data storage system 100 may provide protection against failure of any larger, component part or even a complete component (e.g., a metadata server, a content server, and a networking switch). In larger systems, such as those that have three or more groups of servers arranged in respective enclosures or racks as described below, the data storage system 100 should continue to operate even in the event of the failure of a complete enclosure or rack.
Referring now to FIG. 2, a system architecture for a data storage system 200 connected to multiple clients is shown, in accordance with an embodiment of the invention. The system 200 has a number of metadata server machines 202, each to store metadata for a number of files that are stored in the system 200. Software running in such a machine is referred to as a metadata server 202 or a content director 202. The metadata server 202 is responsible for managing operation of the system 200 and is the primary point of contact for clients 204 and 206. Note that there are two types of clients illustrated, a smart client 204 and a legacy client 206.
The smart client 204 has knowledge of the proprietary network protocol of the system 200 and can communicate directly with the content servers 210 behind the networking fabric (here a Gb Ethernet switch 208) of the system 200. The switch 208 acts as a selective bridge between content servers 210 and metadata server 202 as illustrated in FIG. 2.
The other type of client is a legacy client 206 that does not have a current file system driver (FSD) installed, or that does not use a software development kit (SDK) that is currently provided for the system 200. The legacy client 206 indirectly communicates with content servers 210 behind the Ethernet switch 208 through a proxy or a content gateway 212, as shown, via an open networking protocol that is not specific to the system 200. The content gateway 212 may also be referred to as a content library bridge 212.
The file system driver or FSD is a software that is installed on a client machine, to present a standard file system interface, for accessing the system 200. On the other hand, the software development kit or SDK allows a software developer to access the system 200 directly from an application program. This option also allows system specific functions, such as the replication factor setting to be described below, to be available to the user of the client machine.
In the system 200, files are typically divided into slices when stored. In other words, the parts of a file are spread across different disk drives located within content servers. In a current embodiment, the slices are preferably of a fixed size and are much larger than a traditional disk block, thereby permitting better performance for large data files (e.g., currently 8 Mbytes, suitable for large video and audio media files). Also, files are replicated in the system 200, across different drives within different content servers, to protect against hardware failures. This means that the failure of any one drive at a point in time will not preclude a stored file from being reconstituted by the system 200, because any missing slice of the file can still be found in other drives. The replication also helps improve read performance, by making a file accessible from more servers. To keep track of what file is stored where (or where are the slices of a file stored), the system 200 has a metadata server program that has knowledge of metadata (information about files) which includes the mapping between a file name and its slices of the files that have been created and written to.
The metadata server 202 determines which of the content servers 210 are available to receive the actual content or data for storage. The metadata server 202 also performs load balancing, that is determining which of the content servers 210 should be used to store a new piece of data and which ones should not, due to either a bandwidth limitation or a particular content server filling up. To assist with data availability and data protection, the file system metadata may be replicated multiple times. For example, at least two copies may be stored on each metadata server 202 (and, for example, one on each hard disk drive unit). Several checkpoints of the metadata should be taken at regular time intervals. It is expected that on most embodiments of the system 200, only a few minutes of time may be needed for a checkpoint to occur, such that there should be minimal impact on overall system operation.
In normal operation, all file accesses initiate or terminate through a metadata server 202. The metadata server 202 responds, for example, to a file open request, by returning a list of content servers 210 that are available for the read or write operations. From that point forward, client communication for that file (e.g., read; write) is directed to the content servers 210, and not the metadata servers 202. The SDK and FSD, of course, shield the client 204, 206 from the details of these operations. As mentioned above, the metadata servers 202 control the placement of files and slices, providing a balanced utilization of the content servers.
In accordance with another embodiment, a system manager (not shown) may also be provided, for instance on a separate rack mount server machine, for configuring and monitoring the system 200.
The connections between the different components of the system 200, that is the content servers 210 and the metadata servers 202, should provide the necessary redundancy in the case of a network interconnect failure.
FIG. 3A illustrates a physical network topology for a relatively small data storage system 300. FIG. 3B illustrates a logical network topology for the data storage system 300. The connections are preferably Gb Ethernet across the entire system 300, taking advantage of wide industry support and technological maturity enjoyed by the Ethernet standard. Such advantages are expected to result in lower hardware costs, wider familiarity in the technical personnel, and faster innovation at the application layers. Communications between different servers of the OCL system preferably uses current, Internet protocol (IP) networking technology. However, other network switching interconnects may alternatively be used, so long as they provide the needed speed of switching packets between the servers.
A networking switch 302 automatically divides a network into multiple segments, acts as a high-speed selective bridge between the segments, and supports simultaneous connections of multiple pairs of computers which may not compete with other pairs of computers for network bandwidth. It accomplishes this by maintaining a table of each destination address and its port. When the switch 302 receives a packet, it reads the destination address from the header information in the packet, establishes a temporary connection between the source and destination ports, sends the packet on its way, and may then terminate the connection.
The switch 302 can be viewed as making multiple temporary crossover cable connections between pairs of computers. High-speed electronics in the switch automatically connect the end of one cable (source port) from a sending computer to the end of another cable (destination port) going to the receiving computer on a per packet basis. Multiple connections like this can occur simultaneously.
In the example topology of FIGS. 3A and 3B, multi Gb Ethernet switches 302, 304, 306 are used to provide connections between the different components of the system 300. FIGS. 3A & 3B illustrate 1 Gb Ethernet 304, 306 and 10 Gb Ethernet 302 switches allowing a bandwidth of 40 Gb/second available to the client. However, these are not intended to limit the scope of the invention as even faster switches may be used in the future. The example topology of FIGS. 3A and 3B has two subnets, subnet A 308 and subnet B 310 in which the content servers 312 are arranged. Each content server has a pair of network interfaces, one to subnet A 308 and another to subnet B 310, making each content server accessible over either subnet 308 or 310. Subnet cables 314 connect the content servers 312 to a pair of switches 304, 306, where each switch has ports that connect to a respective subnet. The subnet cables 314 may include, for example, Category 6 cables. Each of these 1 Gb Ethernet switches 304, 306 has a dual 10 Gb Ethernet connection to the 10 Gb Ethernet switch 302 which in turn connects to a network of client machines 316.
In accordance with one embodiment, a legacy client 330 communicates with a gateway server 328 through the 10 Gb Ethernet switch 302 and the 1 Gb Ethernet switch 304. The gateway server 328 acts as a proxy for the legacy client 330 and communicates with content servers 312 via the 1 GbE switch 306.
In this example, there are three content directors 318, 320, 322 each being connected to the 1 Gb Ethernet switches 304, 306 over separate interfaces. In other words, each 1 Gb Ethernet switch 304, 306 has at least one connection to each of the three content directors 318, 320, 322. In addition, the networking arrangement is such that there are two private networks referred to as private ring 1 324 and private ring 2 326, where each private network has the three content directors 318, 320, 322 as its nodes. Those of ordinary skills in the art will recognize that the above private networks refer to dedicated subnet and are not limited to private ring networks. The content directors 318, 320, 322 are connected to each other with a ring network topology, with the two ring networks providing redundancy. The content directors 318, 320, 322 and content servers 312 are preferably connected in a mesh network topology (see U.S. patent application entitled “Logical and Physical Network Topology as Part of Scalable Switching Redundancy and Scalable Internal and Client Bandwidth Strategy”, by Donald Craig, et al.). An example physical implementation of the embodiment of FIG. 3A would be to implement to each content server 312 as a separate server blade, all inside the same enclosure or rack. The Ethernet switches 302, 304, 306, as well as the three content directors 318, 320, 322 could also be placed in the same rack. The invention is, of course, not limited to a single rack embodiment. Additional racks filled with content servers, content directors and switches may be added to scale the system 300.
Turning now to FIG. 4, an example software architecture 400 for the system 200 is depicted. The system 200 has a distributed file system program that is to be executed in the metadata server machines 402, 404, the content server machines 406, 408, and the client machines 410, to hide complexity of the system 200 from a number of client machine users. In other words, users can request the storage and retrieval of, in this case, audio and/or video information though a client program, where the file system makes the system 200 appear as a single, simple storage repository to the user. A request to create, write, or read a file is received from a network-connected client 410, by a metadata server 402, 404. The file system software or, in this case, the metadata server portion of that software, translates the full file name that has been received, into corresponding slice handles, which point to locations in the content servers where the constituent slices of the particular file have been stored or are to be created. The actual content or data to be stored is presented to the content servers 406, 408 by the clients 410 directly. Similarly, a read operation is requested by a client 410 directly from the content servers 406, 408.
Each content server machine 406, 408 may have one or more local mass storage units, e.g. rotating magnetic disk drive units, and manages the mapping of a particular slice onto its one or more drives. In addition, in the preferred embodiment, replication operations are controlled at the slice level. The content servers 406, 408 communicate with one another to achieve slice replication and obtaining validation of slice writes from each other, without involving the client.
In addition, since the file system is distributed amongst multiple servers, the file system may use the processing power of each server (be it a content server 406, 408, a client 410, or a metadata server 402, 404) on which it resides. As described below in connection with the embodiment of FIG. 4, adding a content server to increase the storage capacity automatically increases the total number of network interfaces in the system, meaning that the bandwidth available to access the data in the system also automatically increases. In addition, the processing power of the system as a whole also increases, due to the presence of a central processing unit and associated main memory in each content server. Such scaling factors suggest that the system's processing power and bandwidth may grow proportionally, as more storage and more clients are added, ensuring that the system does not bog down as it grows larger.
The metadata servers 402, 404 may be considered to be active members of the system 200, as opposed to being an inactive backup unit. This allows the system 200 to scale to handling more clients, as the client load is distributed amongst the metadata servers 402, 404. As a client load increases even further, additional metadata servers can be added.
According to an embodiment of the invention, the amount of replication (also referred to as “replication factor”) is associated individually with each file. All of the slices in a file preferably share the same replication factor. This replication factor can be varied dynamically by the user. For example, the system's application programming interface (API) function for opening a file may include an argument that specifies the replication factor. This fine grain control of redundancy and performance versus cost of storage allows the user to make decisions separately for each file, and to change those decisions over time, reflecting the changing value of the data stored in a file. For example, when the system 200 is being used to create a sequence of commercials and live program segments to be broadcast, the very first commercial following a halftime break of a sports match can be a particularly expensive commercial. Accordingly, the user may wish to increase the replication factor for such a commercial file temporarily, until after the commercial has been played out, and then reduce the replication factor back down to a suitable level once the commercial has aired.
According to another embodiment of the invention, the content servers 406, 408 in the system 200 are arranged in groups. The groups are used to make decisions on the locations of slice replicas. For example, all of the content servers 406, 408 that are physically in the same equipment rack or enclosure may be placed in a single group. The user can thus indicate to the system 200 the physical relationship between content servers 406, 408, depending on the wiring of the server machines within the enclosures. Slice replicas are then spread out so that no two replicas are in the same group of content servers. This allows the system 200 to be resistant against hardware failures that may encompass an entire rack.
Replication of slices is preferably handled internally between content servers 406, 408. Clients 410 are thus not required to expend extra bandwidth writing the multiple copies of their files. In accordance with an embodiment of the invention, the system 200 provides an acknowledgment scheme where a client 410 can request acknowledgement of a number of replica writes that is less than the actual replication factor for the file being written. For example, the replication factor may be several hundred, such that waiting for an acknowledgment on hundreds of replications would present a significant delay to the client's processing. This allows the client 410 to tradeoff speed of writing verses certainty of knowledge of the protection level of the file data. Clients 410 that are speed sensitive can request acknowledgement after only a small number of replicas have been created. In contrast, clients 410 that are writing sensitive or high value data can request that the acknowledgement be provided by the content servers only after all specified number of replicas have been created.
According to an embodiment of the invention, files are divided into slices when stored in the system 200. In a preferred case, a slice can be deemed to be an intelligent object, as opposed to a conventional disk block or stripe that is used in a typical RAID or storage area network (SAN) system. The intelligence derives from at least two features. First, each slice may contain information about the file for which it holds data. This makes the slice self-locating. Second, each slice may carry checksum information, making it self-validating. When conventional file systems lose metadata that indicates the locations of file data (due to a hardware or other failure), the file data can only be retrieved through a laborious manual process of trying to piece together file fragments. In accordance with an embodiment of the invention, the system 200 can use the file information that are stored in the slices themselves, to automatically piece together the files. This provides extra protection over and above the replication mechanism in the system 200. Unlike conventional blocks or stripes, slices cannot be lost due to corruption in the centralized data structures.
In addition to the file content information, a slice also carries checksum information that may be created at the moment of slice creation. This checksum information is said to reside with the slice, and is carried throughout the system with the slice, as the slice is replicated. The checksum information provides validation that the data in the slice has not been corrupted due to random hardware errors that typically exist in all complex electronic systems. The content servers 406, 408 preferably read and perform checksum calculations continuously, on all slices that are stored within them. This is also referred to as actively checking for data corruption. This is a type of background checking activity which provides advance warning before the slice data is requested by a client, thus reducing the likelihood that an error will occur during a file read, and reducing the amount of time during which a replica of the slice may otherwise remain corrupted.
FIG. 5A is a block diagram illustrating a distributed file system with a notification system in accordance with one embodiment. In accordance with one embodiment, the distributed file system may include the data storage system 200. A client 502 communicates via a network with the distributed file system 504. One or more applications may be coupled to the distributed file system 504. For illustration purposes, Application A 512 and Application B 514 are coupled to the distributed file system 504.
In accordance with one embodiment, the distributed file system 504 may include the data storage system previously described in FIGS. 3A and 3B. Further, the distributed file system 504 may have a command executive module 506, a notification system module 508, and a notification table 510.
The client 502 communicates with the command executive module 506. For example, the client 502 may send a command for a file, such as writing a new file or editing an existing file on the content servers 328. The command executive module 506 receives the command and either executes or fails the command. For example, a lack of storage space on content servers 328 or access authority by client 502 may trigger a failed command. The client 502 may be notified of the failed command.
Upon successful execution of the command, the command executive module 506 notifies the notification system 508 of the executed command. The notification system 508 compares the command for the file with the notification table 510. FIG. 5B illustrates an example of a notification table 510. The notification table 510 may have an application field 516, a command field 518, and a scope field 520.
The application field 516 may include the name of an application such as Application A 512, and Application B 514 coupled to the distributed file system 504. In the example of FIG. 5A, application A 512, and application B 514 are registered in the notification table. The command field 518 may include the name of the actual command, such as read, write, delete, etc.
The scope field 520 may include the scope of the content of the distributed file system 504 on which the corresponding application is interested in monitoring, or learning about. For example, Application A 512 may be interested in a particular directory, a particular type of file, or a particular content server.
In accordance with one embodiment, Application A 512 may be an application transcoding high bit rate audio/video content stored on the distributed file system 504 into low bit rate proxies that can be viewed on low cost desktop computers. The distributed file system 504 may store large amounts of audio/video content across the multiple content severs 328. A typical workflow is for Application A 512 to automatically transcode any material appearing on the distributed file system 504. To detect new material on the distributed file system 504, Application A 512 may continuously scan the content severs 328 for new material. The scanning process may consume a lot of network and processing bandwidth. This consumption may introduce latency from the time a new material is stored on the content servers 328 to the time Application A 512 detects the new material through its scanning process.
In accordance with one embodiment, Application A 512 is coupled to the distributed file system 504 with the notification system module 508. Application A 512 may register with the notification system 508 using the notification table 510 that it is interested in new files stored in the content servers 328. When the distributed file system 504 receives a new file, the distributed file system 504 immediately notifies Application A 512. The notification system module 508 eliminates the resource intensive scanning process, and reduces the latency between the new material being stored on the content servers 328, and the start of transcoding on Application A 512. Other changes in files, such as deletion, renames, moves, or updates among others may also be notified. The notification system module 508 provides the capability to provide notification for a hierarchy of directories. Different events may be combined into a single notification mechanism. Notification may be allowed on different directories on the distributed file system 508 over a network. Each event is tagged, allowing resumption of service at the point immediately prior to the loss of connection, or even resumption of service on a different storage server in the same cluster, such as in the case of a complete hardware failure.
FIG. 6 is a flow diagram illustrating a method for notifying an application coupled to a distributed file system in accordance with one embodiment. At 602, a command for a file stored in the distributed file system is received. The command may be submitted by a client communicating with the distributed file system. The distributed file system stores portions of the file across one or more distinct physical storage locations. At 604, the distributed file system executes the command or fails the command. A failed command is returned to the client. At 606, the distributed file system notifies any executed command to a notification system. At 608, the command for the file is compared with a notification table of the notification system.
The notification table may have an application field, a command field, and a scope field. The application field may include the name of any application coupled to the distributed file system. The command field may include the name of the actual command, such as read, write, delete, etc. The scope field lists may include the scope of the content of the distributed file system on which the application is interested in monitoring, or learning about. Each application coupled to the distributed file system is registered in the notification table.
At 610, the corresponding application associated with the command from the notification table is notified. In accordance with one embodiment, the distributed file system sends a message to the application that an interested file is being operated on. Upon notification, the corresponding application may operate on the file. In accordance with one embodiment, the application may transcode, scale, filter the file in the distributed file system.
In the foregoing specification, the invention has been described with reference to specific exemplary embodiments thereof. It will, however, be evident that various modifications and changes may be made thereto without departing from the broader spirit and scope of the invention as set forth in the appended claims. The specification and drawings are, accordingly, to be regarded in an illustrative sense rather than a restrictive sense.

## Claims

1. A method comprising:
receiving, at a distributed file system comprising one or more server machines, a command for a digital media file, the distributed file system storing portions of the digital media file across a plurality of distinct physical storage locations;
comparing the command for the digital media file with a notification table of a notification system of the distributed file system; and
wherein the notification table comprises, for a transcoding application to be notified of the command:
a command field that matches the command;
an application field that identifies the transcoding application to be notified of the command; and
a scope field that identifies a scope of files on the distributed file system for which the transcoding application is to be notified;

determining that one or more portions of the digital media file is within the scope of files for which the transcoding application is to be notified; and
based at least in part on the determining, notifying the transcoding application of the command in response to the command being performed on the one or more portions of the digital media file;
wherein the notifying the transcoding application causes transcoding to automatically begin on a portion of the digital media file.

2. The method of claim 1, wherein the receiving comprises:
receiving the command from a client.

3. The method of claim 1, further comprising:
executing the command on the digital media file.

4. The method of claim 1, wherein the scope field includes a predefined portion of the plurality of distinct physical storage locations.

5. The method of claim 1, wherein the transcoding application resides outside the distributed file system.

6. The method of claim 1, wherein the notifying comprises:
sending a message to the transcoding application, wherein the message describes the command.

7. The method of claim 1, wherein the notifying the transcoding application causes transcoding to begin by causing the transcoding application to perform an operation on the digital media file, wherein the operation is selected from the group consisting of scaling and filtering the digital media file.

8. The method of claim 1, wherein the causing transcoding to automatically begin on a portion of the digital media file comprises causing high bit rate audio or video content stored on the distributed file system to be transcoded into low bit rate proxies.

9. An apparatus comprising:
a distributed file system storing portions of a digital media file across a plurality of distinct physical storage locations; and
a notification system module coupled to the distributed file system;
a notification table of the notification system;
wherein the notification system module is configured to compare a command received for the digital media file with the notification table;
wherein the notification table comprises, for a transcoding application to be notified of the command:
a command field that matches the command;
an application field that identifies the transcoding application to be notified of the command; and
a scope field that identifies a scope of files on the distributed file system for which the transcoding application is to be notified;

wherein the notification system module is configured to perform:
determining that one or more portions of the digital media file is within the scope of files for which the transcoding application is to be notified; and
based at least in part on the determining, notifying the transcoding application of the command in response to the command being performed on the one or more portions of the digital media file;

wherein the notification system module performing notifying the transcoding application causes transcoding to automatically begin on a portion of the digital media file.

10. The apparatus of claim 9, wherein the distributed file system further comprises:
an Ethernet switch;
a metadata server coupled to the Ethernet switch; and
a plurality of content servers coupled to the metadata server, the plurality of content servers storing portions of files.

11. The apparatus of claim 9, wherein:
the distributed file system is in communication with one or more clients; and
the distributed file system is in communication with one or more applications that are registered in the notification table.

12. The apparatus of claim 9, further comprising a server that is configured to execute the command for the digital media file.

13. The apparatus of claim 9, wherein the scope field includes a predefined portion of the plurality of distinct physical storage locations.

14. The apparatus of claim 9, wherein the transcoding application resides outside the distributed file system.

15. The apparatus of claim 9, wherein the notification system module is configured to perform notifying by sending a message to the transcoding application, wherein the message describes the command.

16. The apparatus of claim 9, wherein the notification system module performing notifying the transcoding application causes transcoding to begin by causing the transcoding application to perform an operation on the digital media file, wherein the operation is selected from the group consisting of scaling and filtering the digital media file.

17. The apparatus of claim 9, wherein the notification system module performing notifying the transcoding application causes transcoding to begin by causing high bit rate audio or video content stored on the distributed file system to be transcoded into low bit rate proxies.

18. A machine-readable medium storing instructions, which when executed by a machine, cause the machine to perform:
receiving a command for a digital media file for a distributed file system, the distributed file system storing portions of the digital media file across a plurality of distinct physical storage locations;
comparing the command for the digital media file with a notification table of the distributed file system; and
wherein the notification table comprises, for a transcoding application to be notified of the command:
a command field that matches the command;
an application field that matches the transcoding application to be notified of the command; and
a scope field that identifies a scope of files on the distributed file system for which the transcoding application is to be notified;

determining that one or more portions of the digital media file is within the scope of files for which the transcoding application is to be notified; and
based on the determining, notifying the transcoding application of the command in response to the command being performed on the one or more portions of the digital media file;
wherein the notifying the transcoding application causes transcoding to automatically begin on a portion of the digital media file.

19. The machine-readable medium of claim 18, wherein the instructions, when executed by the machine, cause the machine to perform the receiving by:
receiving the command from a client.

20. The machine-readable medium of claim 18, wherein the instructions, when executed by the machine, further cause the machine to perform executing the command for the digital media file.

21. The machine-readable medium of claim 18, wherein the scope field includes a predefined portion of the plurality of distinct physical storage locations.

22. The machine-readable medium of claim 18, wherein the transcoding application resides outside the distributed file system.

23. The machine-readable medium of claim 18, wherein the instructions, when executed by the machine, cause the machine to perform the notifying by sending a message to the transcoding application, wherein the message describes the command.

24. The machine-readable medium of claim 18, wherein the instructions, when executed by the machine, cause transcoding to begin by causing the transcoding application to perform an operation on the digital media file, wherein the operation is selected from the group consisting of scaling and filtering the digital media file.

25. The machine-readable medium of claim 18, wherein the instructions, when executed by the machine, cause transcoding to automatically begin by causing high bit rate audio or video content stored on the distributed file system to be transcoded into low bit rate proxies.