How to Mount and Partition Disks in CentOS
#/list block devices
lsblk
fdisk -l
#list disk
fdisk -l /dev/sdb
#partitioning
fdisk /dev/sdb
1.
#new disk:
fdisk /dev/sdb
2.
#partition
p
3.
#new
n
4.
#new primary partition
p
(enter enter )
5.
#write
w
#list block devices
lsblk
df -h
#displaying free disk space, disk free
#viser også hvor mounted
#make filesystem
sudo mkfs -t ext4 /dev/sdb1
#blkid
shows id on disk + filsystem
mount on media
#sudo mount /dev/sdb1 /media
df -h
#disk free, viser nu nye disk
centos 7
Thanks for this!
Thnxx buddy…. You saved me from a live ticketing environment…
thanks but after restart the mount remove why ?
this video was a life saver, great content!