Shared disk files synchronization

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I have two Centos 7 servers with a shared disk mounted via fstab with:



/dev/sdb /mnt/shared xfs rw,suid,dev,noexec,auto,user,sync 0 0


I can see the disk and its content on both servers, but when I create a new file it is not automatically seen on the opposite server. If I umount and mount the disk, then the files will appear.



Executing sync after file creation also won't create the file.



I have installed lsyncd as suggested here but nothing changed.







share|improve this question

















  • 1




    Are you using clustered XFS? If not you will be at serious risk of corrupting your filesystem, if both are mounted r/w
    – rusty shackleford
    Jun 7 at 13:50










  • @rustyshackleford Not clustered, thanks for the advice.!
    – Zumo de Vidrio
    Jun 7 at 13:54










  • No problem! Posted as an answer with some example clustered filesystems.
    – rusty shackleford
    Jun 7 at 14:20














up vote
0
down vote

favorite












I have two Centos 7 servers with a shared disk mounted via fstab with:



/dev/sdb /mnt/shared xfs rw,suid,dev,noexec,auto,user,sync 0 0


I can see the disk and its content on both servers, but when I create a new file it is not automatically seen on the opposite server. If I umount and mount the disk, then the files will appear.



Executing sync after file creation also won't create the file.



I have installed lsyncd as suggested here but nothing changed.







share|improve this question

















  • 1




    Are you using clustered XFS? If not you will be at serious risk of corrupting your filesystem, if both are mounted r/w
    – rusty shackleford
    Jun 7 at 13:50










  • @rustyshackleford Not clustered, thanks for the advice.!
    – Zumo de Vidrio
    Jun 7 at 13:54










  • No problem! Posted as an answer with some example clustered filesystems.
    – rusty shackleford
    Jun 7 at 14:20












up vote
0
down vote

favorite









up vote
0
down vote

favorite











I have two Centos 7 servers with a shared disk mounted via fstab with:



/dev/sdb /mnt/shared xfs rw,suid,dev,noexec,auto,user,sync 0 0


I can see the disk and its content on both servers, but when I create a new file it is not automatically seen on the opposite server. If I umount and mount the disk, then the files will appear.



Executing sync after file creation also won't create the file.



I have installed lsyncd as suggested here but nothing changed.







share|improve this question













I have two Centos 7 servers with a shared disk mounted via fstab with:



/dev/sdb /mnt/shared xfs rw,suid,dev,noexec,auto,user,sync 0 0


I can see the disk and its content on both servers, but when I create a new file it is not automatically seen on the opposite server. If I umount and mount the disk, then the files will appear.



Executing sync after file creation also won't create the file.



I have installed lsyncd as suggested here but nothing changed.









share|improve this question












share|improve this question




share|improve this question








edited Jun 7 at 13:42
























asked Jun 7 at 13:35









Zumo de Vidrio

1,267318




1,267318







  • 1




    Are you using clustered XFS? If not you will be at serious risk of corrupting your filesystem, if both are mounted r/w
    – rusty shackleford
    Jun 7 at 13:50










  • @rustyshackleford Not clustered, thanks for the advice.!
    – Zumo de Vidrio
    Jun 7 at 13:54










  • No problem! Posted as an answer with some example clustered filesystems.
    – rusty shackleford
    Jun 7 at 14:20












  • 1




    Are you using clustered XFS? If not you will be at serious risk of corrupting your filesystem, if both are mounted r/w
    – rusty shackleford
    Jun 7 at 13:50










  • @rustyshackleford Not clustered, thanks for the advice.!
    – Zumo de Vidrio
    Jun 7 at 13:54










  • No problem! Posted as an answer with some example clustered filesystems.
    – rusty shackleford
    Jun 7 at 14:20







1




1




Are you using clustered XFS? If not you will be at serious risk of corrupting your filesystem, if both are mounted r/w
– rusty shackleford
Jun 7 at 13:50




Are you using clustered XFS? If not you will be at serious risk of corrupting your filesystem, if both are mounted r/w
– rusty shackleford
Jun 7 at 13:50












@rustyshackleford Not clustered, thanks for the advice.!
– Zumo de Vidrio
Jun 7 at 13:54




@rustyshackleford Not clustered, thanks for the advice.!
– Zumo de Vidrio
Jun 7 at 13:54












No problem! Posted as an answer with some example clustered filesystems.
– rusty shackleford
Jun 7 at 14:20




No problem! Posted as an answer with some example clustered filesystems.
– rusty shackleford
Jun 7 at 14:20










1 Answer
1






active

oldest

votes

















up vote
1
down vote



accepted










If you are using a shared block device you must ensure you are using a clustered filesystem if you intend for both servers to be able to write to the filesystem. Otherwise you will undoubtedly corrupt the file system.



Examples of clustered file systems:



GFS
Lustre
OCF
LizardFS


If it's an option, it may be simpler to mount an NFS share on both servers, as this will handle file locking etc.






share|improve this answer





















  • btrfs would be a valid one? mopar4life.com/btrfs-centos-samba
    – Zumo de Vidrio
    Jun 8 at 7:19






  • 1




    No btrfs is not a clustered filesystem, and it doesn't look like they plan on making it one: btrfs.wiki.kernel.org/index.php/…
    – rusty shackleford
    Jun 8 at 7:50










Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f448427%2fshared-disk-files-synchronization%23new-answer', 'question_page');

);

Post as a guest






























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
1
down vote



accepted










If you are using a shared block device you must ensure you are using a clustered filesystem if you intend for both servers to be able to write to the filesystem. Otherwise you will undoubtedly corrupt the file system.



Examples of clustered file systems:



GFS
Lustre
OCF
LizardFS


If it's an option, it may be simpler to mount an NFS share on both servers, as this will handle file locking etc.






share|improve this answer





















  • btrfs would be a valid one? mopar4life.com/btrfs-centos-samba
    – Zumo de Vidrio
    Jun 8 at 7:19






  • 1




    No btrfs is not a clustered filesystem, and it doesn't look like they plan on making it one: btrfs.wiki.kernel.org/index.php/…
    – rusty shackleford
    Jun 8 at 7:50














up vote
1
down vote



accepted










If you are using a shared block device you must ensure you are using a clustered filesystem if you intend for both servers to be able to write to the filesystem. Otherwise you will undoubtedly corrupt the file system.



Examples of clustered file systems:



GFS
Lustre
OCF
LizardFS


If it's an option, it may be simpler to mount an NFS share on both servers, as this will handle file locking etc.






share|improve this answer





















  • btrfs would be a valid one? mopar4life.com/btrfs-centos-samba
    – Zumo de Vidrio
    Jun 8 at 7:19






  • 1




    No btrfs is not a clustered filesystem, and it doesn't look like they plan on making it one: btrfs.wiki.kernel.org/index.php/…
    – rusty shackleford
    Jun 8 at 7:50












up vote
1
down vote



accepted







up vote
1
down vote



accepted






If you are using a shared block device you must ensure you are using a clustered filesystem if you intend for both servers to be able to write to the filesystem. Otherwise you will undoubtedly corrupt the file system.



Examples of clustered file systems:



GFS
Lustre
OCF
LizardFS


If it's an option, it may be simpler to mount an NFS share on both servers, as this will handle file locking etc.






share|improve this answer













If you are using a shared block device you must ensure you are using a clustered filesystem if you intend for both servers to be able to write to the filesystem. Otherwise you will undoubtedly corrupt the file system.



Examples of clustered file systems:



GFS
Lustre
OCF
LizardFS


If it's an option, it may be simpler to mount an NFS share on both servers, as this will handle file locking etc.







share|improve this answer













share|improve this answer



share|improve this answer











answered Jun 7 at 14:19









rusty shackleford

1,135115




1,135115











  • btrfs would be a valid one? mopar4life.com/btrfs-centos-samba
    – Zumo de Vidrio
    Jun 8 at 7:19






  • 1




    No btrfs is not a clustered filesystem, and it doesn't look like they plan on making it one: btrfs.wiki.kernel.org/index.php/…
    – rusty shackleford
    Jun 8 at 7:50
















  • btrfs would be a valid one? mopar4life.com/btrfs-centos-samba
    – Zumo de Vidrio
    Jun 8 at 7:19






  • 1




    No btrfs is not a clustered filesystem, and it doesn't look like they plan on making it one: btrfs.wiki.kernel.org/index.php/…
    – rusty shackleford
    Jun 8 at 7:50















btrfs would be a valid one? mopar4life.com/btrfs-centos-samba
– Zumo de Vidrio
Jun 8 at 7:19




btrfs would be a valid one? mopar4life.com/btrfs-centos-samba
– Zumo de Vidrio
Jun 8 at 7:19




1




1




No btrfs is not a clustered filesystem, and it doesn't look like they plan on making it one: btrfs.wiki.kernel.org/index.php/…
– rusty shackleford
Jun 8 at 7:50




No btrfs is not a clustered filesystem, and it doesn't look like they plan on making it one: btrfs.wiki.kernel.org/index.php/…
– rusty shackleford
Jun 8 at 7:50












 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f448427%2fshared-disk-files-synchronization%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

Peggy Mitchell

Palaiologos

The Forum (Inglewood, California)