Learning Library

← Back to Library

Block vs File Storage Overview

Key Points

  • Block storage splits data into independent blocks that can be moved across disks or cloud clusters for efficiency, while file storage presents data as hierarchical files and directories.
  • In cloud environments, block devices can be attached to virtual servers either directly via a mount point (e.g., using Linux or Windows) or through the hypervisor layer, making them behave like physical disks.
  • Block storage volumes can be unmounted from one virtual server and re‑mounted on another, providing flexibility for OS, application data, and backups.
  • File storage, by contrast, is accessed over network protocols (such as NFS or SMB) and is optimized for sharing files among multiple clients rather than low‑level block manipulation.
  • Choosing between block and file storage depends on the workload: block storage suits databases and performance‑critical applications, while file storage is ideal for collaborative file sharing and hierarchical data organization.

Full Transcript

# Block vs File Storage Overview **Source:** [https://www.youtube.com/watch?v=PmxWTTpXNLI](https://www.youtube.com/watch?v=PmxWTTpXNLI) **Duration:** 00:10:52 ## Summary - Block storage splits data into independent blocks that can be moved across disks or cloud clusters for efficiency, while file storage presents data as hierarchical files and directories. - In cloud environments, block devices can be attached to virtual servers either directly via a mount point (e.g., using Linux or Windows) or through the hypervisor layer, making them behave like physical disks. - Block storage volumes can be unmounted from one virtual server and re‑mounted on another, providing flexibility for OS, application data, and backups. - File storage, by contrast, is accessed over network protocols (such as NFS or SMB) and is optimized for sharing files among multiple clients rather than low‑level block manipulation. - Choosing between block and file storage depends on the workload: block storage suits databases and performance‑critical applications, while file storage is ideal for collaborative file sharing and hierarchical data organization. ## Sections - [00:00:00](https://www.youtube.com/watch?v=PmxWTTpXNLI&t=0s) **Block Storage vs File Storage** - IBM’s Bradley Knapp outlines the fundamental differences between block and file storage, explaining how block storage breaks files into movable independent blocks for efficiency, while file storage uses a different presentation and use‑case model. ## Full Transcript
0:00hi there and thanks so much for joining 0:02us today my name is bradley knapp and 0:03i'm with ibm and the question that we're 0:05answering today is what is block storage 0:08versus file storage 0:10so this is a pretty intro intro and 0:13basic level question i'm glad you guys 0:15came to learn the difference because 0:17when you're talking about cloud 0:18computing these are far and away the two 0:20most commonly used kinds of storage and 0:24so to start off we're going to get our 0:26block over here 0:28and then we're going to put our file 0:30over here 0:31and let's talk about the difference 0:33between these two because this 0:34difference is really important there are 0:36two different kinds of storage the way 0:38that they present is different the 0:39underlying technology is is different 0:42but most importantly they have specific 0:45uses that make them very very distinct 0:48so let's start over here with block 0:50let's get into that one first so if we 0:52think about block storage on the 0:54underlying layer if we think about the 0:56physical devices that the data is stored 0:58on when you write 1:01out to a block volume you're going to 1:03write a file out that file is going to 1:05get broken up into lots of independent 1:08parts and each of those independent 1:10parts is going to go onto that storage 1:12device now what makes block really 1:14useful as a storage media 1:17is each of these different parts can be 1:19moved around for efficiency's sake so 1:21you can move them around on a single 1:23disk you can move them around on a raise 1:25of disk or in the case of cloud storage 1:27where we have entire clusters of 1:28physical hardware you can move these 1:30things around to wherever they need to 1:32be that's the block part now 1:35when it comes time to mount 1:37this block device to your virtual 1:39machine that's where things get really 1:41interesting right so over here i've got 1:44my vsi my virtual server and to my vsi i 1:48want to attach storage right i have to 1:50have something to run my operating 1:51system off of i have to have storage to 1:53store the data that is being processed i 1:56have to have 1:57storage in order to store my backups and 1:59so a blocked device can actually be 2:01mounted to this virtual server in two 2:03different ways 2:05the first is it can be mounted directly 2:08via a mount point m and t 2:11so via mount point so when you order a 2:13block device you're gonna get a little 2:15mount point that goes along with it it 2:17can be mounted to your virtual server 2:19using windows or linux whatever your 2:21preference is you just put in the 2:23address that proper security information 2:25and you can mount it and then you can 2:26start using it have to apply file system 2:29obviously but 2:30away you go 2:31in addition to that during the 2:33provisioning process so when this 2:35virtual server is being provisioned we 2:38can have a block device that gets 2:40mounted up here into the hypervisor 2:42layer 2:44and it acts looks and feels just like it 2:47was a physical 2:49disk that's mounted into the machine now 2:51big difference here if you're talking 2:53about a block device that is mounted 2:54directly to the virtual server you can 2:57unmount it and mount it to another 2:59virtual server over here so let's say 3:01that all right i've written a bunch of 3:03data out to it and i don't want it 3:04attached to that one anymore i'm going 3:06to spin up a second vsi i'm going to put 3:08an x over that bad boy and i'm now going 3:11to mount it to my new virtual server let 3:14that new virtual server work on all of 3:16the data that's in there let me give you 3:18another use case for it let's imagine 3:20that i have a virtual server that is 3:23doing a bunch of processing information 3:26and it's writing that out so let's put 3:27that bad boy over here 3:29vsi 3:31and i have a block device 3:33that is mounted to it 3:36and so my virtual server here it's doing 3:38lots of processing right it's preparing 3:40data sets data analytics maybe 3:43but 3:44it is only doing all of the processing 3:46it's not actually serving that data out 3:48to anybody else let's say that i have 3:51four more vsis 3:53that are over here 3:56that those are the ones that are going 3:57to serve this data out and so what they 4:00can do is each of them 4:02can mount 4:04this block device but mount it read only 4:06and so when you've mounted this thing 4:08read only you don't have to worry about 4:09data corruption or anything like that 4:10because all they can do is read from it 4:13but they can get access to it in real 4:16time and so they can bring down the 4:17latest information 4:19so block device probably the most 4:21commonly used storage in cloud now let's 4:25talk for a minute about file 4:28file storage um is the other most 4:31commonly used storage and the big 4:33difference between file and block so 4:35remember i said block whenever we write 4:37out we write out in all these little 4:39bits right there's some metadata that 4:41goes along with them but not just a ton 4:43mainly it's the job of the operating 4:45system in that virtual server to provide 4:47you all of the other information 4:49file stores on the other hand or a file 4:52share 4:53maintains the directory hierarchy in the 4:56same way that you think about it in 4:58displayed at the operating system layer 5:00so if i have an a file share here inside 5:04that file share i'm going to have 5:05folders 5:09and inside those folders i'm going to 5:11have files 5:13just like if i was looking at 5:15any other kind of a storage device on a 5:18local machine but it is native to this 5:21actual storage media itself the media 5:24maintains 5:26this logical hierarchy and maintains the 5:28metadata that goes along with that 5:30hierarchy so 5:32whenever i mount an nfs share i can do 5:34interesting things like collaboration 5:36remember over here in order to maintain 5:38file integrity we had to lock the entire 5:41volume and make it read only well file 5:44is not quite that inflexible file you 5:47have the ability because you have all of 5:49the metadata in it and you're 5:50maintaining that hierarchy you can lock 5:52individual files within a file share so 5:55over here 5:56in that example so now let's get our vsi 6:01and we are going to mount 6:03a file share and we're going to call 6:05this one mntf 6:07for file 6:09now let's imagine that i have a bunch of 6:12laptops right so my 6:14my users 6:15have a network share in the office that 6:18they use and so i've got no i don't know 6:20two different laptops right 6:22and each of these laptops is accessing 6:25files that are stored on this central 6:26directory 6:28so laptop one can go out and access it 6:30read it make changes whatever it's 6:33locked only while it's being written to 6:35laptop two can do the same thing 6:37you know it's locked only while it's 6:39being written too now you always run 6:40into the issue of potential data 6:42integrity errors in that you'll get out 6:45of sync right so what what one machine 6:48is seeing may not be synced up with what 6:49another machine is thinking but you 6:51probably won't corrupt and kill the file 6:53the way you would have five or ten years 6:54ago 6:55now another place that file storage is 6:58kind of nifty 6:59is it can be performance adjusted to be 7:02pretty fast and so if you're talking 7:04about storing a structured backup file 7:08so rather than just a single backup file 7:10that has the integrity within it maybe 7:12you've got a bunch of backup files that 7:15you know that you need to maintain in a 7:17specific series of folders in order for 7:19your rewrite to happen correctly or your 7:21restore to happen correctly that is 7:23going to be better stored in file 7:25storage than it is in block storage 7:26because again with file you're just 7:28going to take you're going to mount it 7:29to your virtual server and then your 7:31backup software can pick up that logical 7:33hierarchy and start your restoration 7:36so 7:37file storage block storage both are 7:39mounted at the operating machine level 7:42at the virtual server level at the os 7:44level uh the big difference there is 7:46remember block can also be mounted up at 7:48the hypervisor level file storage cannot 7:50you cannot boot from a file share 7:53right file is purely for storing whereas 7:56block is both bootable 7:58and used for file storage itself so 8:01that's the big difference between the 8:02two let's talk about practical 8:04applications block storage you can boot 8:06from it right your operating system can 8:08run on it a database you're always going 8:11to want to put a traditional database 8:13and a relational database 8:16into block storage you do not want to 8:18store that on file storage you're going 8:19to have all kinds of issues and you try 8:20and do that because the inherent 8:23chunking ability of that block storage 8:26is going to make it 8:27much easier to tweak and get higher 8:29performance out of so these block 8:31volumes obviously you can adjust the 8:33performance every cloud provider is 8:35going to give you the ability to have 8:36low performing medium performing high 8:38performing ultra high performing 8:40but they're going to adjust your ability 8:43to do 8:44to have as much performance as you need 8:47file storage again same idea you can 8:49adjust the amount of performance that 8:50you need but you can't dial the knobs 8:52quite as neatly as you can on the block 8:54side so again block you're going to put 8:56your databases on there operating system 8:57boot images 8:59um 9:00data that is right once read many times 9:03it's going to go great there file file 9:05is great for 9:06mounting to many devices right 16 32 50 9:10or 100 devices at once 9:12it maintains that hierarchy so it's 9:14really useful for traditional shares and 9:17when it comes to access control 9:19you know it can inherit user directory 9:21permissions and things like that so that 9:24certain users are only authorized to see 9:26certain folders within the within the 9:28construct 9:30other places that you might use file um 9:33oh let's see you could use file storage 9:35for documents you can use it for videos 9:37you can use it for collaboration 9:40uh let's imagine cad files all right so 9:42computer aided design files you're an 9:44architect or you're 9:46some sort of a machine designer you're 9:48an engineer you're working on these big 9:50huge cad documents you're going to want 9:53to store those cad files into a file 9:56share that way you can share that out 9:58because you again just like our example 10:00down here you've got many users that 10:02need to access it and make changes and 10:04most cad software is pretty clever now 10:07and so you don't have to worry about 10:08running into data conflicts as you're 10:10doing that so that's an overview of 10:12block versus file it's why you would use 10:14one versus the other they're both 10:16incredibly important in the world of 10:18cloud and hopefully you found it helpful 10:22thank you so much for your time today if 10:24you have any questions please drop us a 10:26line below if you want to see more 10:28videos like this in the future please do 10:30like and subscribe and let us know 10:50you