Build your own NAS! A custom Raspberry Pi build with OpenMediaVault and an Argon One M2 Case

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] [Music] hello again everyone welcome back to learn linux tv in today's video i am going to show you guys how to build a nas using open media vault in the argon 1 m2 case which allows you to attach an ssd to a raspberry pi and this is the unit that i decided to build right here i wanted to have an open media vault instance in my home lab here so that i always have it available to test on but i figured if i'm going to be building one i may as well show you guys how i built it so i recorded the entire process and in this video if you want to create your very own open media vault server just like this you'll be able to do so i'm going to show you the entire process i'm going to show you an unboxing of this case i'll then show you how to put it together i'll also go over how to install raspberry pi os as well and then we'll tweak raspberry pi os and then finally i will show you how to install open media vault it's going to be a lot of fun so if you wanted to create a new nas for your home lab then this is the video for you let's get started okay so first of all what do you need to get started if you want to mimic the build that i put together honestly all you really need is a raspberry pi an sd card and a power cable now it's definitely preferred to have a case though not only does it protect your raspberry pi but the argon one case looks pretty cool and that's the case that i'm going over in this video you don't have to use the argon one case but it is something that i recommend if you don't already have a favorite case to use and again in this video i'm going to show you how to put this case together now the best feature of this case in my opinion is that it allows you to attach an m2 ssd and mount it inside the case along with the raspberry pi so i think this case is a great fit for what we're trying to do today to be fair though you don't need an ssd straight away and you can always add that later if you don't actually attach an ssd or some sort of additional storage to the raspberry pi then you'll be stuck using the sd card for your storage and there's nothing wrong with that but you'll have additional overhead so keep that in mind and some people can just start with an sd card and then add the ssd later so you don't have to order every component all at once but i will have a shopping link in the description down below it'll contain all of the components that i'm using today so if you want to order the same components that i'm using in this video you'll be able to grab them from that link and doing so also helps support the channel and i really appreciate it in regards to the ssd though the case i'm using supports m2 ssds not nvme so just keep that in mind if you are ordering a different ssd than the one that i am using in this video i also recommend that you hardwire your finished build with ethernet for faster transfer speeds but since the pi has built-in wi-fi you can use that instead if you want to make it a portable nas just keep in mind that you will have better transfer speeds over ethernet but if that doesn't matter so much to you then again building a portable and wireless raspberry pi based nas is actually pretty cool too anyway let's go ahead and get started with the build in order for this build to work you're going to need an operating system for your raspberry pi i decided to go with raspberry pi os and you can download it from the url that you see on the screen right now i will have a link in the description below from which you can grab the download file for raspberry pi os and i will also have it linked in the wiki article that you can also find below that wiki article will contain all the links that you see in this video as well as the commands that i'm using to build this device now specifically i decided to go with the lite version of raspberry pi os and the difference there is that the light edition has no gui so it's often the case when you are setting up a server or an appliance such as this that you'll omit the gui from the build to save cpu cycles now there's nothing wrong with installing the desktop edition of raspberry pi os if you want to everything i'm going over in this video will still work if you do that but i'm using the light edition which is why you will not see a graphical user interface while i set it up when you download raspberry pi os it'll come in the form of a zip file you can put that aside after it's done downloading because you'll also need to download a utility that you can use to basically flash that image onto an sd card properly and i like to use usb imager for that purpose and the reason why is because whatever your operating system is on your laptop or desktop the device on which you are downloading raspberry pi os and preparing your sd card you can use usb imager with your computer because it supports mac linux and windows it's the same utility on each so i can go over one utility and regardless of your operating system the process will be mostly the same so you just download usb imager for your specific operating system as for me i downloaded the ubuntu in version and that's what i installed my popos laptop i just used the built-in package installer to install the package after i downloaded it and after i installed it usb imager was available in the applications menu so i launched it then i clicked on the three dots to select the raspberry pi os image that was downloaded earlier and finally i clicked on the write button i typed in my password for approval and i waited until it was done flashing it didn't take long at all for that to be written and then it was all set now i do recommend that you enable ssh it just makes remote access even easier and you can do that by creating a file called ssh and saving that in the boot directory of the sd card so basically after you write the os image to the sd card you eject the sd card reinsert it and you should see a volume that is called boot and in that volume just create an empty file called ssh with no file extension at all and what that will do is cause raspberry pi os at first boot to turn on ssh and then you can use ssh to connect to the raspberry pi and that's how we're going to configure the open media vault software as well as the tweaks for the operating system once you're all set with the sd card set it aside for now we'll come back to it let's go ahead and unbox the case and then we'll put it together so here's the argon one m2 in the box i'm excited to check it out before we do i'll go ahead and see if i can give you a closer look at the box so nothing too exciting and we're going to go ahead and open it we have this quick start guide right here nothing too out of the ordinary just basically tells you how to set it up but i'm going to show you how to do that in this video here we have the actual case it's in there pretty tight it's kind of like a uh it's like a stretchy bag we have the argon one m2 case right here so we have the top layer i think it looks very sleek and almost futuristic it's definitely an awesome looking case we have what i believe is a daughter board this goes into the raspberry pi we also have this usb dongle and actually what this is going to do if i can even get it to focus is this is actually going to attach the bottom layer to the top layer which i have to admit is really not my favorite aspect about this case but i guess if it works it works that also means that we are limited to usb bus speed as well so there's bad we have some hardware here in the baggie and we have this right here which is the bottom layer of the case which is where you can insert the m2 ssd it's a usb port here on the bottom and well that's pretty much all there's to it in addition to that i also have this right here and this is for those of you that already own the argon one case but for whatever reason at first you didn't decide to get the bottom layer with the m.2 ssd this is essentially an upgrade that'll give you that functionality so you don't have to buy a brand new case just to get that oops and i'm a bit clumsy but of course we have the same little attachment there in that box quick start guide again and of course we have the same bottom layer here the same one i just showed you so again if you bought the argon one case without the m.2 bottom half then you can actually upgrade and i plan on doing that with my retropies because maybe it'll just make more sense to store the roms on the m.2 ssd so i'm going to be upgrading those but there you go that's a possibility if you already own an argon one case now for the purposes of this video i purchased a cheap ssd and to be honest i didn't really buy the fastest one i just wanted something relatively cheap so i have this one right here is 240 gigabytes but i bought a few of these i plan on upgrading other devices around the studio and here's one already out of the package and it's pretty straightforward to install the ssd into the case you have a black screw that would normally be right here i've already removed it off camera it was actually hard to remove it without also removing the standoff that's underneath the screw so i took care of that off camera as well and the standoff is important because you don't want the ssd to touch the board so you basically just slide the ssd into the slot and this is the screw right here i'll just set this in place i'll screw it down and that's about it as you can see it's nice and snug so here i have the i o board that came with the case and then here i have of course the raspberry pi so what you want to do at this point is just line up the headphone jack just like this and very carefully you want to just nudge that in there is a little bit of resistance here so so i don't want to use too much force but i had to nudge it along a bit and we should be good now before we actually insert the raspberry pi and the i o board into the case we want to make sure that we have the sd card inserted first because unfortunately there's no exposed sd card slot on the case itself which is in my opinion not a very good thing so just make sure that you've done that already and then next we have these thermal pads that come with the case there's two of them so what you want to do is remove the plastic from one side and then you're going to place it on the raspberry pi and then also make sure you remove the plastic from the top as well in my original review for the argon one case i forgot to do that and somebody pointed that out to me in the comments so don't be like me make sure you actually remove the plastic from both sides and then we're going to do the same thing again with another one of these thermal pads there's two of them and this time we're actually going to place it right here and then of course remove the plastic from the top as well which is actually a little hard to get to and i have the thermal pads there on the raspberry pi so now we can insert the raspberry pi and the i o board into the case so here we have the top layer of the case and then right here we have the gpio pins and then we have the gpio pins here on the raspberry pi so we're going to make sure that everything is lined up especially the back we're going to basically slide everything in then you want to make sure that the gpio pins here are lined up it's hard to see in the camera you don't want to force it if it's not actually going to fit just gently nudge it in there and everything appears to be secure so now what we can do is secure the board to the case and you're going to do that with the four shorter screws and here we have the two screws that come with the case one is shorter than the other and you are going to use the shorter one for this step you'll need four of them and i'm just going to place them where they go so we need one right there also right here up here and down here so i have one here here here and here just make sure they're all tightened don't want to over tighten them that should be all there is to it the board is secure so next we're going to grab the top layer and the bottom layer and we're going to join them together and as you can see pretty self-explanatory just kind of sets on there and then we have the longer screws we're going to use them to secure the two pieces together and here we have the finished product so already a couple of things i don't like about it again the sd card slot is not exposed anywhere so if i wanted to change the sd card i'm going to need to disassemble this unit i did already attach the rubber feet to the unit as well that basically stops it from slipping and now that we have the bottom layer and the top layer connected it's not going to be able to use the m2 storage yet because we need this dongle right here to essentially marry the two together and we just attach it like that and as you can see it's essentially a usb dongle that connects the usb port here on the top basically the raspberry pi to the bottom layer and what i don't like about that is it still looks like i have a flash drive on the back of the raspberry pi and yeah the bottom layer is going to give me an actual m2 ssd in here so this is going to make the connection possible but i still think it's a little weird to have this sticking out of the back which looks like a flash drive when i'm not even using a flash drive but it's just cosmetic it doesn't matter but i do like the fact that we have full hdmi ports here which is pretty cool i don't really mind the smaller hdmi ports on the raspberry pi but full-sized hdmi cables are easier to find so i really like that they did that and we have the usb-c connector for power here headphone jack the remainder of the usb ports ethernet and of course we have our power toggle we can power on the unit with this button here and we could also enable safe shutdown which i'm going to show you how to do after you power on the raspberry pi for the first time i recommend that you install all the latest updates set the host name and then reboot the unit so basically we have a few tweaks to do first you can ssh into the unit by finding its ip address for me i just looked at the dhcp lease list inside my firewall it showed up there with a hostname of raspberry pi so i copied the ip address and i used the ssh command along with the username of pi and the ip address to connect to the unit and the default password is simply raspberry to set the host name i first edited the etsy hostname file and on my end i set it to a fully qualified domain name as you see here but you don't have to have a domain name though you can shorten it down to something like omv if you want or whatever you want to call it and then i went ahead and edited the etsy host file so basically just make sure that the host name is the same here as it was in the file that we've edited earlier after that was done i ran sudo apt update ampersand ampersand sudo apt dist upgrade and what that command will do is chain two commands together the first of which will update the list of available updates and the second will go ahead and install those updates and the last process that i went through for os setup was i ran sudo raspy config that opens up the configuration menu for raspberry pi os and in there we can set up some additional tweaks first i access the localization options then the first option in that menu locale the locale defaults to engb utf-8 and you can leave it as that if that's correct for you but on my end it needs to be changed that's not what my locale is here in the united states so i deselected that by highlighting it and then i pressed space to remove the asterisk then i scrolled down i looked for enus utf-8 which is the correct setting for me and then i press space to add an asterisk to that field and i'll have a link down below for a list of locales if you don't know what yours should be you can find it from that list there's a bunch of them so i can't go over them all just check that link if you don't already know and then i pressed enter to confirm my changes and that was all set next i went back to localization options and this time to time zone you definitely want to make sure that you have the correct time zone for a nas in that menu i selected america and then detroit which is correct for me just set it to whatever yours should be and then once all of that was done i decided to reboot the pi so that all the changes i made would take effect and to reboot i simply ran sudo reboot after the pi has had a few minutes to reboot the next thing that i recommend you do is to install the safe shutdown script for the argon one case you only need to do this if you are using the same case as the case that i'm using if you are using something else then don't complete this step now what this script will allow you to do is hold down the power button on the back of the case for a few seconds and that'll trigger it to actually shut down and that's certainly better than having it abruptly power off hence the term safe shutdown now in my end i switched to root to run this command probably out of habit and then i ran the install command command that you see on the screen right now and that was the only command that i needed to run in order to set this up that's all there is to it with all of that done it's finally time to install openmediavault now installing openmediavault actually takes quite a bit of time the process is a little bit on the lengthy side but even though it's lengthy there's only one command to run and the rest is just a waiting period you run the command that you see on the screen right now and again it'll be in the wiki article as well if you prefer to copy and paste it and once you kick that off you basically just go grab a coffee and then come back later and it should be done once the script has completed you should be able to access open media vault by typing in the ip address or hostname of your raspberry pi in the address bar of your browser and the default username for the web console is admin and the default password for that is openmediavault and once you log in you can go ahead and set up your disk in the open mediavault gui and to do that you can go into the disk section in the left-hand menu and you should see the ssd in the list then you can click on the wipe button and that should ensure that the ssd is completely wiped out and ready to be used after that you can go to the file system section and create a new file system for your ssd so click on create select your ssd from the device drop down leave it on ext4 unless you prefer something else and then the ssd should be formatted and ready to go then you can click on the mount button to make the ssd available for use within omv after i formatted the sst i created a few shares in the shared folder section for a test i also went into services and enabled the services that i wish to use with my shared folders for example samba and nfs and once you do that you should be able to go to the file manager of your operating system and access the server from there you should be able to see the shared folders inside your file manager window if all has gone according to plan and then be able to save your data into those folders i'll leave it up to you to configure your openmedia vault the way you like it but it's pretty straightforward you simply create the shared folders you set the level of security that you want on those folders maybe you want something wide open and maybe another shared folder that's more private it's up to you and then you should be able to access those folders from other computers on your network now in my end in pop os i had to manually type snb colon slash and then the host name of the pi for it to actually show the shares but as soon as i've done that i was able to access them so there you go if everything has gone according to plan you should have your very own open media vault build like i have here powered by a raspberry pi a really awesome case and ssd back storage this is an awesome build and i really enjoyed putting it together now it probably goes without saying or at least i hope it does this build only has one ssd so if that ssd was to fail you would lose everything so definitely make sure that you have everything backed up somewhere else that's just a good practice anyway you don't want to have all of your important files and documents and things on one device definitely have everything on this that's important copied over to somewhere else just keep that in mind but i really enjoyed putting this together and i hope you enjoyed this build as well let me know your thoughts in the comments down below i have some awesome videos coming very soon so make sure you subscribe and i'll see you again real soon thanks for watching [Music] you
Info
Channel: LearnLinuxTV
Views: 50,189
Rating: undefined out of 5
Keywords: Linux, Tutorial, Howto, Guide, os, install openmediavault, open media vault, openmediavault setup, raspberry pi, raspberry pi 4, raspberry pi nas, argon one, raspberry pi 4 nas, argon 40, raspberry pi os, how to build, nas server, nas, raspberry pi 4 nas server, raspberry pi 4 nas storage, raspberry pi 4 nas setup, raspberry pi 4 nas project, raspberry pi nas server, storage, diy, raspberry nas, nas with pi, raspbian, pi 4 nas, pi 4 nas server, pi ssd, ssd, openmediavault, argon
Id: SdpTEYxfa9A
Channel Id: undefined
Length: 28min 5sec (1685 seconds)
Published: Thu Mar 18 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.