Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've LAMP installed in my laptop. Now my question is

1 ) is this possible to copy LAMP directories to another computer.

2) if possible,which directories I need to copy??


share|improve this question
You mean copying the server files like /var/www/html ? – LnxSlck Sep 17 '12 at 15:53

If you have an identically setup of the machines (same Ubuntu version preferably, LAMP installed via tasksel), then you only need to copy /etc/apache5/sites-* (depending you have set-up multiple domain-names through "VirtualHost") and your www-data directory (by default /var/www/) to the other machine.

Concerning MySQL databases, you will have to do a mysqldump of the respective databases on the first machine, and import them on the other machine - via command-line or phpMyAdmin.

share|improve this answer

Let's say you have 2 computers with the same linux distributions, you would need to have LAMP installed on both computers.

Then, yes you can copy all files (configuration and relevant files) to the 2nd computer.

These could be depending on how you installed lamp, the configuration files for apache, /etc/http/* or /etc/apache/* and the sites /var/www/*

share|improve this answer
Yes, Both computers are running on Ubuntu. – Yasir Adnan Sep 17 '12 at 15:56
Do you know the answer of my 2nd question?? – Yasir Adnan Sep 17 '12 at 16:00
Just edited my answer, Marc-André Appel also gave a good answer – LnxSlck Sep 18 '12 at 9:09

Your Answer


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.