LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   nfs for syncing dirs, but want to exclude a dir (https://www.linuxquestions.org/questions/linux-networking-3/nfs-for-syncing-dirs-but-want-to-exclude-a-dir-743030/)

Nielsrohrig 07-27-2009 03:33 AM

nfs for syncing dirs, but want to exclude a dir
 
Hello,

Im using nfs exports for syncing the home dirs between 2 servers.
that works fine but i have a network mount under /home/<user>/projects wich i would like to exclude from syncing because syncing the network mount gives troubles. Is that possible or maybe with some handy program/tool?
It just needs to sync the whole /home except /home/<user>/projects
in /etc/fstab on lnxserver02 i have:
#lnxserver01:/home /home nfs defaults 0 0
thx for your help!

jschiwal 07-28-2009 05:53 PM

That isn't syncing. Without the "#" commenting out the fstab entry, the /home directory of lnxserver01 is mounted on the /home directory of lnxserver02.

Syncing is when you copy new or changed files from one directory to another, so they contain the same files. E.G. using rsync.
The files exist in only one place, on lnxserver01.

Please explain what particular problem you are having.

Nielsrohrig 07-29-2009 01:06 AM

of course i tested it without the comment in the fstab.
Looks like that is working fine but not when i mount a network folder in that same directory. the network mount is from a filer and needs to be mounted on both servers into /home/<user>/projects. when i turn on the nfs share i can only mount it once, on 1 server. i can mount it on server 2 but then i dont see the files.
i want both /home directorys on both servers syncronized. plus i want to use the root account for it otherwise i have to do it for every user who works on the linuxserver. (around 100 people)

jschiwal 07-29-2009 06:58 AM

Look at the exports manpage for the "crossmnt" option.

You could maybe call this mirroring, but there is no replication involved.

Quote:

plus i want to use the root account for it
Use the root account for what?


All times are GMT -5. The time now is 11:20 AM.