Not sure if it's better suited for superuser of serverfault boards, let me know.
I have a drive which I repartitioned with
fdisk. Initially there was only one big partition, now there are a number of partitions. Now the new partition table won't be taken into account by the kernel until the next reboot.
The point is that there are some data on this drive which are shared through NFS, and which should be present on the drive when rebooting. Also, I want to avoid modifying configuration files, even temporarily. So I would like to ensure these data are on the first partition,
/dev/sdb1, corresponding to the previous single partition, so that they are immediately available at next boot.
So is there a (simple) way to write data on particular sectors or blocks on the drive ? Is it the purpose of the
dd "seek" option ? If I manage to do that the data will still be readable at next reboot once the new partition has been taken into account, right ?
FWIW, the amount of data is not so large, 2.1 MB, but
/dev/sdb1 is only 82 MB and the drive is 160 GB.
Edit : For the whole history and why I cannot reload the partition table (which would be the best solution), see this question on serverfault.
Edit2 : Ok, I may have found a workaround, which would be to copy files from elsewhere as soon as the machine is rebooted, before NFS is set up.
Edit3 : Nevermind Edit2, the new
/dev/sdb1 wouldn't be formatted yet…
Edit4 : Actually, this last edit probably discards the whole question, as it applies in any case. Should have think of that earlier…