First time post on here. I'm studying for the LFCS course so I'm relatively new to Linux sysadmin, so apologies if this is an obvious question.
I'm having a very frustrating issue that has had me stuck for a few days. I've searched high and low on this site and across google and have yet to find an answer that relates to my exact problem.
I'm doing a little project on my own CentOS 7 VM , I'm setting up Kibana and Elastic search. Firstly - I'm setting up a partition on my HD for this, and have created a partition with no problem using fdisk. When i write the new partition to table , I always get the error that tables did not update correctly. But after running partprobe, this resolves this. Next it's time to put the file system on the new partition, but here is where I have the problem , i always get this error - /dev/sda1 is apparently in use by the system; will not make a filesystem here!
# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 24.5G 0 disk
└─sda1 8:1 0 1023.8M 0 part
sdb 8:16 0 512M 0 disk [SWAP]
# mkfs -t ext4 /dev/sda1
mke2fs 1.42.9 (28-Dec-2013)
/dev/sda1 is apparently in use by the system; will not make a filesystem here!
#
I have read similar posts and many answers include checking to see if raid info is stored on the disk, but that is definitely not the case with my VM.
The disk is also unmounted and def does not have a filesystem on it :-
# file -sL /dev/sda1
/dev/sda1: data#
Any help or ideas anyone has would be gratefully received. I'm pulling my hair out here! Many Thanks :)
