<<

International Journal of Scientific Engineering and Applied Science (IJSEAS) - Volume-1, Issue-3, June 2015 ISSN: 2395-3470 www.ijseas.com

TIME EFFICIENT DISTRIBUTED FILE STORAGE AND SHARING USING P2P NETWORK IN

Sapana Kapadnis1,Prof. Ranjana Dahake2 Department of Computer Engineering, MET BKC, Adgoan

ABSTRACT services are metered such as user can be charged In cloud most of the application only for the resources they have. Basic reason follows client/server architecture. Basic demand behind lower cost in is resource of cloud computing is anytime and anywhere multiplexing. Data mining, gaming and social service. Files stored at cloud can be of any type networking, scientific and engineering like multimedia files, virtual machine image files applications, computational financing as well etc. These files are large in size as compare to many data-intensive and computational activities other files. Proposed system is distributed file can be benefit from cloud computing. Various storage and sharing system which improves approaches are used in cloud computing like provisioning time, availability, , speed client/server approach and P2P approach. In while eliminating various bottlenecks like jitter, client/server system centralized approach is delay etc. Logically connected nodes share many followed where P2P system is highly files having large size. For improving peers decentralized [2]. limited storage space this strategy is put forward. The problem of client/server architecture Diversity of stored can be improve with the same is studied here by using concept of distributed storage space. This system is used to improve file storage and sharing using P2P network in efficient sharing of file between peers. cloud. Peer-to-peer networking is a distributed Keywords: Cloud Computing, P2P system, application architecture which partitions tasks or Virtual Machine Files. workloads between peers. Equal privileges are provided to each peer. They are said to form a peer-to-peer network of nodes. Peers are both suppliers and consumers of resources, in contrast I. INTRODUCTION to the traditional client server model in which The last decades have reinforced the idea that the consumption and supply of resources is information processing and sharing can be done divided. Emerging collaborative P2P systems are more efficiently centrally, on large forms of going beyond the era of peers doing similar computing and storage systems accessible via things while sharing resources, and are looking the . Which leads to introduction of new for diverse peers that can bring in unique technology called cloud computing. Cloud resources and capabilities to a virtual community computing is a technical and social reality and thereby empowering it to engage in greater tasks an emerging technology. Cloud computing beyond those that can be accomplished by provides various services like as a individual peers, yet that are beneficial to all the Service (SaaS), Platform (PaaS), peers[5]. In P2P networks, clients both provide and Infrastructure as a Service (IaaS)[1]. These and use resources. This means that unlike client-

537

International Journal of Scientific Engineering and Applied Science (IJSEAS) - Volume-1, Issue-3, June 2015 ISSN: 2395-3470 www.ijseas.com

server systems, the content serving capacity of broadcast time. User has given privilege to peer-to-peer networks can actually increase as watch/listen and select audio and video more users begin to access the content [4]. This whenever the required. It does not rely on property is one of the major advantages of using specific broadcast time. But it is costly because P2P networks because it makes the setup and entire load is placed on video server. Combining running costs very small for the original content this application with peer-to-peer techniques distributor. Popularity of video streaming load is shifted from single node/server to increasing day by day various strategies are used peers[4]. for video as discuss above like client/server and peer-to-peer. Same mechanism is applicable for C.GridCast multimedia files in case of client server approach In GridCast many operation on video are server provides video stream through unicast provided pause, play, and seek and it also links to client. As all load for broadcasting is at support peer sharing to improve system center server so as number of users workload on performance and scalability. It is live on server also increases which makes this approach CERNET and many videos are served by it. In unscalable [3]. high time where demand of videos is more it Here goal is to design a system which serves up to 23,000 users at a time. With single stores the file which is large in size where each video caching (SVC) GridCast can decrease load peer is contributing for serving others which on source servers by an average of 22 percent leads to reduction in prefetching delay. In this from client-server architecture. By using results system chunk of file is shared among the users of deployment of this system further improve which can be videos or virtual machine files. A peer sharing is done through caching and peer can access chunk or small prefix store at replication. But sharing is not done in efficient other peer. It reduces the workload of server. It way[5]. is distributed protocol as to store and track data. D.Peercasting II. LITERRATURE SURVEY In peercasting concept live stream is broken into small length files and these files are distributed A.Client/Server Architecture by using concept of peer-to-peer sharing[6]. This In the existing system the client/server concept of peercasting is used by in architecture is used where complete data is at which if any user downloads any file, which server and complete workload is on single node. belongs to swarm and may not be offline then It is costly in terms of storage and bandwidth. It other user from same swarm can download file is also not scalable with amount of users[1]. In instead of requesting to server, which is not done this architecture on server many clients are in case of GridCast[7]. present and server is provider of source and client is the one who sends request for resources. E.Bit torrent Server provides service to one or more clients. BitTorrent is used to reduce impact on server Client does not bother about working of server it and network of distributing large files. Instead of is only interested in response to the request [3] downloading file from single node multiple peers are involved which uploads and downloads B.Video-on-Demand files simultaneously. First small torrent Video-on-Demand (VoD)[5] is a application in descriptor is created by user who wants to which we can see video any time independent of upload a file. File is available through a

538

International Journal of Scientific Engineering and Applied Science (IJSEAS) - Volume-1, Issue-3, June 2015 ISSN: 2395-3470 www.ijseas.com

BitTorrent node which at as a seed. Those who information related to provider, fetcher. Also wants download file they can directly get keeps track related to each and every file. connected to no seed or peer and can download Handles request from fetcher save activities like file from peer[8]. announcement, role change etc.

In BitTorrent and other applications data from users devise automatically get upload without permission of user[9]. But in proposed system user has privilege of announcing data at data tracker, without permission of user file from user’s storage space cannot be accessed.

III. PROPOSE SYSTEM Concept of video-on-demand can be replaced by file-on-demand. Files in generalized form like multimedia server. Here it has been proposed that, announcer contains file where data is divided into chunk. In that case fetcher node request to announcer for specific chunk of file. Announcer node pushes the chunk to another node. After that any request related to that chunk Fig.1 P2P File Storage and Sharing System is forwarded provider (i.e source node or other nodes under source node). All these nodes Fetcher: Fetcher requests for metadata of totally forms cluster of interested & it keeps required file which may contain filename, file growing in proportion to the number of clients type, client id, location of provider etc. If needing it. So basic drawback of client server particular file found into client id architecture is overcome by this architecture. related that file is retrieved and send to fetcher. Extra overhead on server is reduced by using Using client id fetcher get connects to announcer peer-to-peer technology. Each peer may perform and receives file from announcer. some task and contribute for file sharing and storage.Fig.1 shows system architecture for P2P A.SystemFlow File Storage and Sharing System. 1.Announcer creates a small announcement for As shown in fig.1 there are three components of file which he wants to distribute with other P2P system as provider, fetcher, and announcer. nodes. This announcement contains filename, Provider/Announcer: Announcer announces client id of announcer as shown in step 1 of the file name, client Id, hash value to data fig.2. tracker. If any request for that particular ip received at data tracker will send corresponding 2. Fetcher sends request for file to data tracker file as per the request in chunk form to fetcher. along with file name.

Datatracker: At Data Tracker announcer 3. Data Tracker searches metadata for that file. If announce the file name, client id, hash value. any record related to that file founds data tracker Data Tracker maintain log about file and sends metadata client id of provider to fetcher. If

539

International Journal of Scientific Engineering and Applied Science (IJSEAS) - Volume-1, Issue-3, June 2015 ISSN: 2395-3470 www.ijseas.com

that file is not present in database then file not found message is send to fetcher. IV. PROCESSING STEPS 4. After arrival of request for file that file is Basic three components are involved in this divided into 1mb chunks. Each chunk is send to system as datatracker, provider and fetcher. fetcher along with checksum which protects each and every chunk. Modification in chunk is detected which prevent malicious and accidental Algorithm : Datatracker alteration of chunk. To achieve integrity Data tracker maintains metadata and displays checksum is introduced. information related to role change if any. At data tracker if any request comes from fetcher data 5. Chunks received are of same size as 1mb tracker search for metadata of that file. It also each. When a peer completely downloads a file, displays all information related to file which is it becomes provider. This eventually shifted announced. from peer to peer. Definition: uname=username 6. At datatracker another fetcher sends request upass= password for the file which is present with multiple nodes. ddate= date of download chunks= Number of chunks of file 7. Data Tracker sends metadata for requested file uploaddate=date of file upload to fetcher which contains ip address of multiple owner=owner of file providers along with there information. 1. create socket 2.get ip address of data tracker 8. Fetcher will send request to these providers 3.bind ip address and as per the request some of the part of file 4.check for registration of user with his uname fetcher gets downloaded from each providers. and upass 5.WHILE TRUE 6.accept connection from provider or fetcher 7.print the role of user along with owner name 8.fetch metadata related to requested file 9.IF list contains ip address for requested file 10.display metadata at datatracker 11.IF file download is completed then change the role from fetcher to provider 12.print role of fetcher along with time to download file, number 13. act as a fetcher 14..END WHILE

Algorithm : Provider and Fetcher Any registered user can at as both provider and fetcher as per the role. 1.IF file announcement is equal to true Fig.2 System Flow 2.filename= file path

540

International Journal of Scientific Engineering and Applied Science (IJSEAS) - Volume-1, Issue-3, June 2015 ISSN: 2395-3470 www.ijseas.com

3.descr= description single node is time required to file download is 4.IF file path exists less. Time to download is decreases as two 5.split the filename and open file in read mode nodes are involved. 6.read entire content of file 7.get the length of data i.e size of input file in bytes 7.divide chunks as per the size of file 8.calculate checksum for file 9.send metadata along with announcer, filename, size, chunks 10.ELSE please enter valid file 11.ENDIF 12.IF requests are pending for file download 13.approve request of fetcher 14.IF file download equal to true then send request Fig.4 File Type V/S Time for Two Nodes 14. IF request approved 15. download file from provider Fig.5 shows time to download same file from 16. else multiple nodes. As compared to graph in fig.3 17. wait for approval from provider and fig.4 time required for file download is less 18.ENDIF for same file. As three nodes are involved each

node is contributing for file download which

leads to reduction in time. V. EXPRIMENTAL RESULTS AND ANALYSIS Fig.3 shows time to download various types of file along with file type. As single node is involved time required to file download is more as compared to multiple nodes. All the analysis is done on the basis of results from table.1.

Fig.5 File Type V/S Time for Three Nodes

In fig.6 clear difference in reduction time can be observed as compared to above graphs three Fig.3 File Type V/S Time for Single Node graph. Contribution of multiple nodes makes system more efficient and also increases system Fig.4 shows time to download various types of performance. Time to download the file is file along with file type. As compared to node

541

International Journal of Scientific Engineering and Applied Science (IJSEAS) - Volume-1, Issue-3, June 2015 ISSN: 2395-3470 www.ijseas.com

Form table.1 comparative analysis can be observed for file with variable size and variable type.

CONCLUSION Distributed P2P File Storage and Sharing system stores files in a peer to peer network where each peer is contributing for serving others which leads to reduction in perfecting delay as well as Fig.6 File Type V/S Time for Four Nodes eliminating bandwidth bottleneck. In this system almost reduces by half as compared to time files are shared among the nodes in a distributed required for single node. way. A peer to peer approach is best suited for Table.1 Results downloading or sharing large data files. It is distributed protocol as to store and track data Time In Seconds while continuously verifying the data integrity Time For Time Time Time using check sums. Ratio of file download from No Of Single For 2 For 3 For 4 File name File Size Chunks Node node node node single peer to four peers is 2:1 so time almost 3Ediots_21541. reduces by half. It reduces workload of single avi 1535MB 1535 624 480 312 250.84 node/peer also provides time efficient WINDOWS 8_ACTIVATE distribution and sharing of file having large size D.iso 3817 MB 3817 1794 1348 1074 869 which reduces time of file sharing. a.pdf 27 MB 27 10 8 7 5 Ongole Githa.avi594.a vi 1481MB 1481 593 379 303 243 ora_setup_file. REFERENCES exe 948MB 948 513 402 317 238 OpenCV- [1] Mladen A. Vouk “Cloud Computing –Issues, 2.4.6.0.exe 291MB 291 221 171 149 130 Research and Implementations” Department of The Covenant - Copy.avi 788MB 788 508 471 292 270 Computer Science, North Carolina State See No Evil University, Raleigh, North Carolina, USA - CIT (2).avi 998 MB 998 694 541 474 363 God of War.7z 2138MB 2138 1139 927 673 481 16, 2008, 4, 235–246 [2] Ilango Sriram, Ali Khajeh-Hosseini Avatar..iso 1567MB 1567 672 495 334 263 Prince_Persia_ ”Research Agenda in Cloud Technologies” SOT.iso 1342MB 1342 563 393 287 197.34 Department of Computer Science, University of photoshop_csX 6.rar 1827MB 1827 814 639 479 363 Bristol, Bristol UK illustratorCS.e xe 1172MB 1172 623.94 461 334 247 [3] IEEE COMMUNICATIONS SURVEYS Wednesday.w TUTORIALS on "A Survey and Synthesis of mv 752MB 752 481 415.37 341 285.41 User Behavior Measurements in P2P Streaming i.mkv 700MB 700 453 374 304.1 275 eclipse.exe 526MB 526 367 296 229 192 Systems" by Ihsan Ullah, Guillaume Doyen, WindowsInstal Gregory Bonnet ler 1220MB 1220 527 382 223 154 [4] Z. Li, H. Shen, H.Wang, G. Liu and J. Brothers(2012) 845MB 845 641 472 318 251 180.01 Li,"SocialTube:P2P-assisted Video Sharing in abc.avi 780.2MB 781 322.253 6 149.33 115.84 Online Social Networks," In Proc. IEEE WINDOWS_7 _AIO_ACTIV 3817.52 TRANSACTIONS ON PARALLEL AND ATED.iso MB 3818 1694.1 1148.7 874.6 769.5 novel.pdf 13 MB 13 8.033 6.86 4.39 3.2

542

International Journal of Scientific Engineering and Applied Science (IJSEAS) - Volume-1, Issue-3, June 2015 ISSN: 2395-3470 www.ijseas.com

DISTRIBUTED SYSTEMS, VOL. 25, NO. 9, SEPTEMBER 2014 [5] B. Cheng, L. Stein, H. Jin, X. Liao, and Z. Zhang, "Gridcast: Improving Peer Sharing for P2P VoD," ACM Trans. Multimedia Computer., Communication., Appl., vol. 4, no. 4, p. 26, Oct. 2008. [6] Yaning Liu ,Gwendal Simon ,"Peer-to-Peer Time-shifted Streaming Systems ",Institute Telecom - Telecom Bretagne, France,November 6, 2009. [7] Laizhong Cui and Nan Lu SocialStreaming: P2P-assisted Streaming in Social Networks In IEEE Trans. on Computers,2013. [8] J.A. Pouwelse, P. Garbacki, D.H.J. Epema, H.J. Sips, THE BITTORRENT P2P FILE- SHARING SYSTEM: MEASUREMENTS AND ANALYSIS, Department of Computer Science, Delft University of Technology, the Netherlands [9] H. Wang, J. Liu, and K. Xu, On the Locality of Bittorrent-Based Video File Swarming, in Proc. P2P, 2009, p. 12. [10] Peersim: A Peer-to-Peer Simulator. [Online]. Available: http:// peer- sim.sourceforge.net/. [11]PlanetLab. [Online]. Available: http://www.planet-lab.org/. [12] Facebook Users Average 7 hrs a Month in January as Digital Universe Expands. [Online].Available:http://blog.nielsen.com/nielse nwire.

543