Lab 1 Operating System
Lab 1 Operating System
LAB RECORD
Semester-I
THEORY
A computer file is defined as a medium used for saving and managing data in the computer system. The
data stored in the computer system is completely in digital format, although there can be various types of
files that help us to store the data.
File systems are a crucial part of any operating system, providing a structured way to store, organize, and
manage data on storage devices such as hard drives, SSDs, and USB drives. Essentially, a file system acts as
a bridge between the operating system and the physical storage hardware, allowing users and applications
to create, read, update, and delete files in an organized and efficient manner.
A file system is a method an operating system uses to store, organize, and manage files and directories on a
storage device. Some common types of file systems include:
• LINUX : ext2,ext3,ext4,XFS,btrfs
• WINDOWS : NTFS,FAT32
• ANDROID : ext4,f2fs,FAT32/exFAT
Here we discussed the file system of Windows and Linux operating system.
ext3:
The third ext developed in 1999 is a journaling file system. It is reliable and unlike ext2, it prevents long
delays at system boot if the file system is in an inconsistent state after an unclean shutdown. Other factors
3
that make it better and different than ext2 are online file system growth and HTree indexing for large
directories.
ext4:
The fourth ext developed in 2006, is a journaling file system. It has backward compatibility with ext3 and
ext2 and it provides several other features, some of which are persistent pre-allocation, unlimited number
of subdirectories, metadata checksumming and large file size. ext4 is the default file system for many Linux
distributions and also has compatibility with Windows and Macintosh.
XFS:
XFS is a 64-bit journaling file system and was ported to Linux in 2001. It now acts as the default file system
for many Linux distributions. It provides features like snapshots, online defragmentation, sparse files,
variable block sizes, and excellent capacity. It also excels at parallel I/O operations.
NTFS:
NTFS stands for New Technology File System. First introduced in 1993, it is used in newer versions of
operating systems such as Windows NT and 2000 and later versions of Windows. NTFS is a more robust,
high-performance logging file system with multi-user access control, ACLs, and many other things that
make it appropriate to work with an Operating System that has protection. NTFS includes characteristics
such as data recovery, multi-streaming, fault tolerance, security, extended file size, and file systems,
UNICODE names. exFAT is used where NTFS is not feasible, due to its data-structure overhead, but a greater
file-size limit than the standard FAT32 file system is needed.
4
LAB ENVIRONMENT
REQUIREMENTS:
• A Kali Linux Based System
• A Windows Operating System
LAB TASKS
• Lsblk -f
The lsblk command lists the information about available block devices.Running it with the -f option will
show the file system type of each partition.
• df -T
df -T command reports file system disk space usage,to include the file system type on a particular disk
partition,use the -T to lists mounted filesystems and their types.
• blkid
Shows the file system type and UUID of all partitions. $sudo blkid
5
This command identifies the file type.The -s flag enables reading of block or character files and -L enables
following of symlinks.
• Cat /etc/fstab
The /etc/fstab file contains information about disk partitions and their associated file systems.Checking this
file can also reveal the file system types cat /etc/fstab.
• mount
Running the mount command without argument shows all mounted file systems along with their types :
mount | grep “^/”
• GParted
6
GParted is a graphical tool for managing disk partitions.Run the following command : $sudo gparted
• fsck
It is used to check and optionally repair linux file systems,it can also print the file system type on specified
disk partitions.The flag -N disables checking of the file system for errors.
fsck -N /dev/sda1
• STEP 1
• STEP 2
• STEP 3
RESULTS
LINUX
COMMAND OUTPUT
lsblk -f ext4
df -T ext4
sudo blkid ext4
/etc/fstab ext4
sudo file -sL ext4
mount | grep “^/” ext4
sudo gparted ext4
fsck -N ext4
WINDOWS:
CONCLUSION
This lab successfully demonstrated the identification of file system on Linux and Windows.Knowing the file
system type is critical for tasks like partitioning,formatting,secuirity and ensuring compatibility across
platforms.
9
Signature Of Faculty –