1 00:00:00,000 --> 00:00:05,040 Linux file system. Now what is a file system? A 2 00:00:05,040 --> 00:00:09,120 file system is basically, think of as a closet as a 3 00:00:09,120 --> 00:00:14,250 shelf. When you come in, you change, you put your 4 00:00:14,250 --> 00:00:17,610 T shirts in one shelf, you put your socks in the 5 00:00:17,610 --> 00:00:21,150 other. So there is a systematic way in your 6 00:00:21,150 --> 00:00:24,570 closet, where you put all your stuff. The file 7 00:00:24,570 --> 00:00:27,270 system in an operating system works exactly the 8 00:00:27,270 --> 00:00:30,780 same. The operating system has file system where 9 00:00:30,870 --> 00:00:34,320 command files go to a different folder, peripheral 10 00:00:34,500 --> 00:00:38,580 devices or files go to a different folder, all the 11 00:00:38,580 --> 00:00:41,220 programs and applications that you install go to a 12 00:00:41,220 --> 00:00:43,950 different folder. So it will be easier, much 13 00:00:43,950 --> 00:00:46,740 easier for operating system to access those files. 14 00:00:47,760 --> 00:00:51,240 Now, operating system stores data on a disk drives 15 00:00:51,240 --> 00:00:54,330 using a structure called file system,consisting of 16 00:00:54,330 --> 00:00:57,420 files, directories, and information needed to 17 00:00:57,450 --> 00:01:01,440 access and locate them. There are many different 18 00:01:01,440 --> 00:01:04,650 types of file system. In general improvements have 19 00:01:04,650 --> 00:01:07,290 been made to file system with new releases of 20 00:01:07,290 --> 00:01:10,050 operating system, and each new file system has 21 00:01:10,050 --> 00:01:14,070 been given a different name. In Linux, we have 22 00:01:14,070 --> 00:01:18,900 file system called ext3, ext4, XFS, 23 00:01:18,900 --> 00:01:21,720 and in Windows, it's the file system called 24 00:01:21,750 --> 00:01:26,640 NTFS, or FAT. Linux file system stores information 25 00:01:26,640 --> 00:01:29,910 in hierarchy of directories and files. Meaning, 26 00:01:29,910 --> 00:01:34,170 there is a first folder, one folder, which is slash 27 00:01:34,410 --> 00:01:38,550 a root filesystem. And every other file is created 28 00:01:38,580 --> 00:01:42,120 within the first file or directory. The file 29 00:01:42,120 --> 00:01:45,720 system structure in Linux actually looks like 30 00:01:45,750 --> 00:01:50,580 this. As I mentioned, the first file system or 31 00:01:50,580 --> 00:01:54,000 first folder always start with slash, which is 32 00:01:54,000 --> 00:01:57,870 also referred to as root. Now please keep in mind 33 00:01:58,050 --> 00:02:02,190 slash root is not as just slash. Slash is the 34 00:02:02,190 --> 00:02:04,710 first directory structure where you have to start 35 00:02:05,100 --> 00:02:07,920 your, navigating your file system. And then 36 00:02:07,950 --> 00:02:10,229 underneath it has different folders as you could 37 00:02:10,229 --> 00:02:15,150 see, it has bin, boot, dev, etc. So this is the way 38 00:02:15,150 --> 00:02:19,020 Linux structure, its file system. Or if we compare 39 00:02:19,350 --> 00:02:22,620 this Linux file system with Windows, you will see 40 00:02:22,620 --> 00:02:26,190 the Windows has also something like that similar 41 00:02:26,250 --> 00:02:28,890 structure, but they have given a different name. 42 00:02:28,890 --> 00:02:33,090 So let's look at the Windows file system. If you 43 00:02:33,090 --> 00:02:37,800 go to Start, and you go to Computer, you're going 44 00:02:37,800 --> 00:02:41,940 to see your C drive. In this case, our C drive, 45 00:02:42,120 --> 00:02:46,380 when we refer to our file system structure diagram 46 00:02:46,380 --> 00:02:49,350 in the background, you'll see why here, that this 47 00:02:49,350 --> 00:02:54,360 one has slash. So in Windows, it starts with C. So 48 00:02:54,360 --> 00:02:57,690 C or slash is the same, but C and Windows and slash 49 00:02:57,690 --> 00:03:00,630 and Linux. So when you double click on Windows C 50 00:03:00,630 --> 00:03:03,780 drive, you're going to see all those different 51 00:03:03,780 --> 00:03:06,600 folders. Now why do we have all those different 52 00:03:06,600 --> 00:03:08,730 folders, why not just one folder, then it will be 53 00:03:08,730 --> 00:03:11,910 so hard for the operating system to find the right 54 00:03:11,940 --> 00:03:14,490 file or directory that you're looking for. So for 55 00:03:14,490 --> 00:03:18,510 example, like apps and Dell, then you have Intel 56 00:03:18,510 --> 00:03:22,170 folder, all the Intel chip related files are in 57 00:03:22,170 --> 00:03:25,890 that directory, the logs, Program Files, Program 58 00:03:25,890 --> 00:03:28,980 Files or the folder when you install a third party 59 00:03:28,980 --> 00:03:33,450 applications. That's where they are downloaded or 60 00:03:33,450 --> 00:03:36,090 the files get. Then we have another one, Program 61 00:03:36,090 --> 00:03:39,630 Files(x86). That's where the 32 bit related 62 00:03:40,110 --> 00:03:44,040 directories are created. And Users that are the 63 00:03:44,040 --> 00:03:46,770 user directories. If you click on it, you'll see 64 00:03:46,770 --> 00:03:49,980 my directory right here as well. And then of 65 00:03:49,980 --> 00:03:52,170 course, the windows, anything that related to 66 00:03:52,170 --> 00:03:56,970 Windows, so that's why it is predefined by Windows 67 00:03:57,030 --> 00:04:00,510 that every time we create a file or every time we 68 00:04:00,510 --> 00:04:03,810 install a program automatically, it gets installed 69 00:04:03,810 --> 00:04:07,170 into these files and directories. So just like 70 00:04:07,170 --> 00:04:12,270 that when we come here, you'll see here, this is 71 00:04:12,270 --> 00:04:15,240 the file system the same way in Linux, the file 72 00:04:15,240 --> 00:04:17,370 system is created but of course the naming 73 00:04:17,370 --> 00:04:20,700 convention is different. Now let's take a look at 74 00:04:20,730 --> 00:04:24,480 our Linux file system. So I'm going to open up 75 00:04:24,480 --> 00:04:26,700 [No audio] 76 00:04:26,700 --> 00:04:28,051 Oracle VirtualBox. 77 00:04:28,051 --> 00:04:34,842 [No audio] 78 00:04:34,842 --> 00:04:36,810 So let's go to the file system. 79 00:04:36,810 --> 00:04:39,930 So as I said in the Linux file system, it starts 80 00:04:39,930 --> 00:04:43,050 with the root. So when you do cd slash, which is 81 00:04:43,050 --> 00:04:49,200 root slash, hit enter, and then you do ls -l. 82 00:04:51,360 --> 00:04:54,450 Here you have a list of all the directories and 83 00:04:54,450 --> 00:04:58,800 files that are starting with slash. You could go 84 00:04:58,800 --> 00:05:02,640 into each of the directories and you could see how 85 00:05:02,640 --> 00:05:06,450 the file system is structured. So I hope you guys 86 00:05:06,600 --> 00:05:10,380 got the gist of how the file system looks like and 87 00:05:10,380 --> 00:05:13,560 why do we have file system in our operating system. 88 00:05:13,560 --> 00:05:14,474 [No audio]