Koozali.org: home of the SME Server

How do I restore user, groups and email only

Offline kevinb

  • *
  • 237
  • +0/-0
How do I restore user, groups and email only
« on: August 25, 2007, 02:32:49 AM »
Hello everyone,

I was hoping someone could help me here. I want to restore only the users, groups and email (IMAP folders). I do not want to restore any contribs, settings configs, custom templates, etc.

Our server has gotten contrib loaded and it does not work predictably anymore. I want to re-install and start fresh but do not want to loose users, passwords, groups or emails (there are no Ibays).

I already performed a fresh install and restore and the issues are still there.

Can anyone help?

Thank you in advance!


Kevin

Offline chris burnat

  • *****
  • 1,135
  • +2/-0
    • http://www.burnat.com
Re: How do I restore user, groups and email only
« Reply #1 on: August 25, 2007, 06:35:34 AM »
You are not telling how you did the restore.  In any event, getting rid of existing templates-custom and templates-user should remove traces of most contribs and custom changes of the server:

go:/etc/e-smith/

[root@local2 e-smith]# mv templates-custom templates-custom.vs7
[root@local2 e-smith]# mkdir templates-custom

[root@local2 e-smith]# mv templates-user-custom templates-user-custom.vs7
[root@local2 e-smith]# mkdir templates-user-custom

[Then expand templates or simply reboot should do.]

No harm done, you can always reverse these operations.
Hope it helps.
- chris
If it does not work out of the box, please fill in a Bug Report @ Bugzilla (http://bugs.contribs.org)  - check: http://wiki.contribs.org/Bugzilla_Help .  Thanks.

Offline kevinb

  • *
  • 237
  • +0/-0
Re: How do I restore user, groups and email only
« Reply #2 on: August 25, 2007, 05:09:10 PM »
I did a restore use the DAR2 interface. Install SME 7.2, yum update, add the contribs we want and then restore the files followed by a reconfig and reboot.

I have two machines that are setup identically but act differently. One Spamassassin does not work on one. The other the SA white list does not work. On one machine squid with ident authorization logs the user's name but does not block unauthorized users the other machines works fine. One machine has a large delay when resolving outgoing DNS requests the other not.

I have learned that at these some of these issues do no appear until after the restore.

Kevin

Offline kevinb

  • *
  • 237
  • +0/-0
Re: How do I restore user, groups and email only
« Reply #3 on: August 27, 2007, 05:53:09 PM »
It looks like if I only restore:

Code: [Select]
etc/samba
home/e-smith/db/ldap
home/e-smith/db/accounts
home/e-smith/files/samba
home/e-smith/files/users
opt/egroupware/backup

I only get the users and their email .... but now the webmail does not work.

Can anyone confirm if I am missing something

Offline dmay

  • *
  • 450
  • +0/-0
    • http://myezserver.com
Re: How do I restore user, groups and email only
« Reply #4 on: August 27, 2007, 11:35:02 PM »
Contribs installed via rpm populate /etc/e-smith/templates, templates-user. To remove the contrib you remove the rpm. Contribs installed manually should populate /etc/e-smith/templates-custom, templates-user-custom but ultimately only you are in control of that. One of the problems you may be encountering is when removing a contrib associated db entries may remain. You really need to peak under the hood and compare your fresh install template directories and /home/e-smith/db entries to your contrib loaded entries.

Darrell

Offline kevinb

  • *
  • 237
  • +0/-0
Re: How do I restore user, groups and email only
« Reply #5 on: August 28, 2007, 12:41:37 AM »
Excellent!

That's the kind of information I was looking for. Thanks Darrell

Can a contrib modify the default values of a template or a db entry?

Now, if I delete the configuration db file for a contrib how can I reset the template or db to the default values? If so how?

Thanks again.

Offline raem

  • *
  • 3,972
  • +4/-0
Re: How do I restore user, groups and email only
« Reply #6 on: August 28, 2007, 03:36:56 AM »
kevinb

Quote
I only get the users and their email .... but now the webmail does not work.
Can anyone confirm if I am missing something

mysql data
You need to dump mysql and copy/merge that across too, that is a part of the backup/restore process.
...

Offline raem

  • *
  • 3,972
  • +4/-0
Re: How do I restore user, groups and email only
« Reply #7 on: August 28, 2007, 03:41:52 AM »
kevinb
Quote
Now, if I delete the configuration db file for a contrib how can I reset the template or db to the default values? If so how?

Maybe, depending what you did & whether doing that broke things;
/etc/e-smith/events/actions/initialize-default-databases
signal-event post-upgrade
reboot

« Last Edit: August 28, 2007, 03:49:46 AM by RayMitchell »
...

Offline CharlieBrady

  • *
  • 6,918
  • +3/-0
Re: How do I restore user, groups and email only
« Reply #8 on: August 28, 2007, 10:49:46 PM »
Contribs installed via rpm populate /etc/e-smith/templates, templates-user. To remove the contrib you remove the rpm.

There won't be any contribs installed if Kevin has done a fresh install followed by a restore. If he's done a fresh install followed by a restore, then removed any custom templates, and reconfigured the system, it should then work. And that should be a simpler and more reliable way to restore the system than trying to selectively resotre user, groups and email only.