Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Possible Duplicate:
LAMP Staging Server with linux users

I need to have a mirror server of my production server so that I can test everything on that server first before implementing on production.

To mirror production server I need to copy current PHP code, uploaded files, database and linux machine users (as my PHP script need these accounts and home directories) from production server to new server and I also need to update all these from production server each time when I need to test anything on staging server because production server gets updated by the users.

I can update everything manually except Linux users and their home directories as they may affect the system. Is there any way to replicate a Linux machine users to another machine at the same time when they are created on production machine or is there any automated system they to staging.

Thanks!

share|improve this question

migrated from stackoverflow.com Jan 10 '10 at 1:35

This question came from our site for professional and enthusiast programmers.

marked as duplicate by Sam Nov 22 '11 at 20:23

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

add comment

1 Answer 1

I need to test anything on staging server because production server gets updated by the users

You are doing this backwards. Users should be updating the staging server, and then changes should tested and then pushed to production.

Use a configuration management tool like puppet to create define user accounts, then they can be applied to staging and production servers, and kept in sync.

share|improve this answer
    
No, I mean the site users. They will surely be updated the live/production server so when I need to test something on staging server should I copy these changes (like database/ uploaded media files/ databases) to staging server or it will automatically sync everything. + The production server administrator needs to create some users account in production machine frequently and all these users should be replicated automatically on staging server as well so that I can test my code on staging server. –  Acharya Jan 11 '10 at 7:42
add comment

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