Data storage method and device

The embodiment of the invention provides a data storage method and device applied to a server, and the method comprises the steps: obtaining a to-be-stored access log file; performing fragmentation processing on the logs contained in the access log file to obtain the logs contained in the fragments...

Ausführliche Beschreibung

Gespeichert in:
Bibliographische Detailangaben
1. Verfasser: MENG YONGMING
Format: Patent
Sprache:chi ; eng
Schlagworte:
Online-Zugang:Volltext bestellen
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
Beschreibung
Zusammenfassung:The embodiment of the invention provides a data storage method and device applied to a server, and the method comprises the steps: obtaining a to-be-stored access log file; performing fragmentation processing on the logs contained in the access log file to obtain the logs contained in the fragments to which each log of the access log file belongs; and storing the logs contained in the obtained fragments to which the logs belong to a storage device in a parallel manner. According to the technical scheme provided by the embodiment of the invention, the access log file is fragmented to obtain thelog contained in the fragment to which the log belongs, and the obtained log is stored in a parallel mode, so that the storage efficiency of the access log file by the server is improved. 本发明实施例提供了一种数据存储方法及装置,应用于服务器,该方法包括:获得待存储的访问日志文件;对访问日志文件所包含的日志进行分片处理,获得访问日志文件的每一日志所属分片所包含的日志;以并行方式,将所获得的每一日志所属分片所包含的日志存储至存储设备。通过本发明实施例提供的技术方案,将访问日志文件进行分片处理,得到日志所属分片所包含的日志,并通过并行方式对所得到的日志进行存储,这样,提高了服务器对访问日志文件进行存储的效率。