Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Is it possible to share the local folders from one Evolution client to another? How? Thanks.

share|improve this question
    
Could you add a few more details on what you want to achieve? // I'm afraid sharing mail folders might lead to trouble when two clients want to write-access them simultaneously -- so the least you had to take care for in such a case is that always only one of the clients is running, however you do the actual "sharing". –  Izzy May 7 '13 at 6:45
    
What I need is to be able to "connect" to the local folders of one Evolution client from another. The idea is to have only one set of local folders that are used by two evolution clients. The write-access permissions won't be a problem because only one client will be running at a time. –  williepabon May 9 '13 at 0:04
    
I doubt both clients are running on the same machine. How is the storage shared then? NFS? In that case it might work with symlinks. However, note that Evolution has multiple data locations; I'm not sure if it works just sharing the one containing the "local folders", but it might. –  Izzy May 9 '13 at 10:44
    
You are correct. Clients are in different hard drives. I will be running one client and be using the local folders of the other client(on the other hard drive) that will be attached via usb. So one client is active at a time. The folders of the other client are used just to store data. –  williepabon May 11 '13 at 20:17
    
In that case (locally attached drive) symlinks could do: try to symlink ~/.local/share/evolution/mail/local from the USB attached disk to the same place on the other client. Pre-condition: Both use the same userID, or access would fail due to permissions. Let me know the results then; if it works out fine, I should make that an answer with some additional details ;) –  Izzy May 11 '13 at 20:33

1 Answer 1

up vote 1 down vote accepted

According to your descriptions both clients are connected locally to the same storage, one using the internal harddisk and the other an attaches USB drive. Only one client is active at a time (never both at the same time), so simultaneous write-access should not happen.

I cannot give any guarantees for the following, since I've never tried (and also will not try, at least in the nearer future), but using symbolic links, the following should be possible -- provided the userIDs (of the user on both machines) match.

Assumptions:

Let's call the machine with the "internal disk" local, and the one primarily using the USB disk external. On both machines, your user is willie. On local, your home directory such should be /home/willie, and let's assume the USB drive is mounted at /mnt/usbdrive with willie's external account such being at /mnt/usbdrive/home/willie when looking from local.

Setting it up:

  1. make sure userIDs match: when logged in as "willie", on each machine at a shell prompt enter the command id. Output should start with uid=1000(willie) gid=1000(willie). Make sure uid on local matches uid on external, same for the gid. Otherwise you will certainly run into a permissions problem.
  2. just in case: make a backup on local (on external, it cannot hurt either). You might want to run an export from Evolution, but at least do a cp -R ~/.local/share/evolution/mail/local ~/backup/mail_local while Evolution is shut down (of course, you might want to use a different target).
  3. now remove the local mail on local: rm -rf ~/.local/share/evolution/mail/local
  4. and create a symlink from the USB disk: ln -s /mnt/usbdrive/home/willie/.local/share/evolution/mail/local ~/.local/share/evolution/mail/local

Conclusion:

That should be it. For willie@external, nothing has changed -- so everything should still work as before. For willie@local things might be a little different: local mail now comes from the USB disk (if Evolution accepted the symlink). Provided local mail doesn't use any "external configuration" in ~/.config/evolution/mail, it should work. Hopefully, it uses only the symlinked directory (it certainly does for folder organization, as it saves its folder.db here).

Good luck, and please report back! Though I do not intend to have use for this kind of solution in the near future, others might :)

share|improve this answer
    
Thanks Izzy for the help. Your solution worked perfectly. The only thing I did differently was that, to create the symlinks I didn't use command (terminal) mode. I used the GUI within Nautilus to create the links. Thanks again. –  williepabon May 16 '13 at 20:48
    
Glad it worked -- and thanks for the feedback! Well, using Nautilus (GUI) or the command line directly, it gives the same result :) Please watch it closely for a while, and don't forget to report back if you encountered any "late issues". Of course, a comment like "3 months heavy use, and still works fine" is at least as welcome :D –  Izzy May 16 '13 at 20:52
    
Izzy: Will do and let you know any issues. Thanks agn. –  williepabon May 17 '13 at 22:04

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.