Is there a way to sync only one partition instead of all partitions?
Something like "sync /dev/sdc1".
perl -MIO::File -e 'new IO::File($ARGV, "r+")->sync()' filename
There is no standard or common function or shell command to synchronize just one partition.
If you mean the
sync utility that flushes data in memory to disk, then the answer is no. This is due to the fact that
sync is generally used during a shutdown or reboot procedure, where it's advisable to get data written safely to disk, and the real target of the operation is memory, not the disks, and getting that buffered data out of RAM to somewhere safe. The disks are just where the data ends up.