This paper focuses on the management and control of raw event files as well as all their associated metadata in the LHCb data acquisition system. The typical foreseen file life cycle is presented, starting from the file creation to its transfer to the CERN tape storage system and the offline processing GRID system. To answer the management needs a dedicated database is implemented (Online Run Database) together with the necessary management software. The solution is integrated with the rest of the data acquisition software chain and with the experiment control system. The software and hardware configuration is explained together with the testing methods, current status and future plans.