Cloning Ubuntu over network
up vote
3
down vote
favorite
I want to migrate with my 12.04 to another machine. I have found the way with dd and hope it will work for me. The thing is that I have to somehow connect both drives to do the actual cloning. I'm trying NFS. When I write in /etc/exports:
/dev/sda1 10.42.0.16(rw,async,subtree_check)
and invoke exportfs -a I end up with the following error:
exportfs: /dev/sda1 is neither a directory nor a file. Remote access will fail
Any clues how I can overcome the problem? Is it a matter of configuration or NFS is a dead end and I have to use something different?
installation file-sharing nfs dd cloning
add a comment |
up vote
3
down vote
favorite
I want to migrate with my 12.04 to another machine. I have found the way with dd and hope it will work for me. The thing is that I have to somehow connect both drives to do the actual cloning. I'm trying NFS. When I write in /etc/exports:
/dev/sda1 10.42.0.16(rw,async,subtree_check)
and invoke exportfs -a I end up with the following error:
exportfs: /dev/sda1 is neither a directory nor a file. Remote access will fail
Any clues how I can overcome the problem? Is it a matter of configuration or NFS is a dead end and I have to use something different?
installation file-sharing nfs dd cloning
add a comment |
up vote
3
down vote
favorite
up vote
3
down vote
favorite
I want to migrate with my 12.04 to another machine. I have found the way with dd and hope it will work for me. The thing is that I have to somehow connect both drives to do the actual cloning. I'm trying NFS. When I write in /etc/exports:
/dev/sda1 10.42.0.16(rw,async,subtree_check)
and invoke exportfs -a I end up with the following error:
exportfs: /dev/sda1 is neither a directory nor a file. Remote access will fail
Any clues how I can overcome the problem? Is it a matter of configuration or NFS is a dead end and I have to use something different?
installation file-sharing nfs dd cloning
I want to migrate with my 12.04 to another machine. I have found the way with dd and hope it will work for me. The thing is that I have to somehow connect both drives to do the actual cloning. I'm trying NFS. When I write in /etc/exports:
/dev/sda1 10.42.0.16(rw,async,subtree_check)
and invoke exportfs -a I end up with the following error:
exportfs: /dev/sda1 is neither a directory nor a file. Remote access will fail
Any clues how I can overcome the problem? Is it a matter of configuration or NFS is a dead end and I have to use something different?
installation file-sharing nfs dd cloning
installation file-sharing nfs dd cloning
edited Apr 13 '17 at 12:23
Community♦
1
1
asked Jul 19 '13 at 16:46
savick01
1286
1286
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
up vote
5
down vote
accepted
On the receiver end:
nc -l 5678 | sudo dd if=/dev/stdin of=/dev/sda
Then on the sender end:
sudo dd if=/dev/sda of=/dev/stdout | nc 1.2.3.4 5678
This copies sda from one PC to another over the network to IP 1.2.3.4 and port 5678. Be sure to install one of the nc packages (just run nc in the terminal and you will get the suggestion if not installed yet.)
Also make sure not any volume on either of the sda drives has a filesystem mounted, so run off a live CD on both ends if you're unsure.
Thank you very much! It was so easy:) In the meantime I started doubting if cloning is such a good idea. I will copy all the drivers and randomly installed packages from the 'sender' machine. What do you think? Is it healthy to reinstall the system from time to time to make it work better or I can just make a clone and enjoy everything working immediately?
– savick01
Jul 19 '13 at 19:08
@savick01 That's a new question - please ask it as such. And if you think this was useful, then consider marking it as correct.
– gertvdijk
Jul 19 '13 at 22:28
0. I already upvoted it and will accept when test (now I have no internet cable available and wifi is too slow(-:). 1. AFAIK discussion questions are not welcome at SE sites, so I just asked for your opinion via comment. 2. If you think it fits here, I can ask it, but there already is a similar question here. Would you be so kind to post your opinion there including the 'healthy or unnecessary to reinstall' part?
– savick01
Jul 19 '13 at 22:46
Yeah! Everything works perfectly! And the cloning process was very fast - much faster than normal copying files. I think it was a good decision to make a clone. P.S. I disabled proprietary drivers before clone just in case.
– savick01
Jul 21 '13 at 14:15
add a comment |
up vote
1
down vote
I can't comment, but I'd like to add to @gertvdijk 's answer that you can use | pv | to show a progress report and it is also wise to add explicit buffer size bs=8M (e.g.) to speed things up (default is 512 bytes which is pretty small). The size depends on your hardware and if you're cloning on local gigabit network or a slower connection. The final command on the receiving end could look like this (add sudo if needed):
nc -l 5678 | dd if=/dev/stdin | pv | of=/dev/sda bs=8M
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
5
down vote
accepted
On the receiver end:
nc -l 5678 | sudo dd if=/dev/stdin of=/dev/sda
Then on the sender end:
sudo dd if=/dev/sda of=/dev/stdout | nc 1.2.3.4 5678
This copies sda from one PC to another over the network to IP 1.2.3.4 and port 5678. Be sure to install one of the nc packages (just run nc in the terminal and you will get the suggestion if not installed yet.)
Also make sure not any volume on either of the sda drives has a filesystem mounted, so run off a live CD on both ends if you're unsure.
Thank you very much! It was so easy:) In the meantime I started doubting if cloning is such a good idea. I will copy all the drivers and randomly installed packages from the 'sender' machine. What do you think? Is it healthy to reinstall the system from time to time to make it work better or I can just make a clone and enjoy everything working immediately?
– savick01
Jul 19 '13 at 19:08
@savick01 That's a new question - please ask it as such. And if you think this was useful, then consider marking it as correct.
– gertvdijk
Jul 19 '13 at 22:28
0. I already upvoted it and will accept when test (now I have no internet cable available and wifi is too slow(-:). 1. AFAIK discussion questions are not welcome at SE sites, so I just asked for your opinion via comment. 2. If you think it fits here, I can ask it, but there already is a similar question here. Would you be so kind to post your opinion there including the 'healthy or unnecessary to reinstall' part?
– savick01
Jul 19 '13 at 22:46
Yeah! Everything works perfectly! And the cloning process was very fast - much faster than normal copying files. I think it was a good decision to make a clone. P.S. I disabled proprietary drivers before clone just in case.
– savick01
Jul 21 '13 at 14:15
add a comment |
up vote
5
down vote
accepted
On the receiver end:
nc -l 5678 | sudo dd if=/dev/stdin of=/dev/sda
Then on the sender end:
sudo dd if=/dev/sda of=/dev/stdout | nc 1.2.3.4 5678
This copies sda from one PC to another over the network to IP 1.2.3.4 and port 5678. Be sure to install one of the nc packages (just run nc in the terminal and you will get the suggestion if not installed yet.)
Also make sure not any volume on either of the sda drives has a filesystem mounted, so run off a live CD on both ends if you're unsure.
Thank you very much! It was so easy:) In the meantime I started doubting if cloning is such a good idea. I will copy all the drivers and randomly installed packages from the 'sender' machine. What do you think? Is it healthy to reinstall the system from time to time to make it work better or I can just make a clone and enjoy everything working immediately?
– savick01
Jul 19 '13 at 19:08
@savick01 That's a new question - please ask it as such. And if you think this was useful, then consider marking it as correct.
– gertvdijk
Jul 19 '13 at 22:28
0. I already upvoted it and will accept when test (now I have no internet cable available and wifi is too slow(-:). 1. AFAIK discussion questions are not welcome at SE sites, so I just asked for your opinion via comment. 2. If you think it fits here, I can ask it, but there already is a similar question here. Would you be so kind to post your opinion there including the 'healthy or unnecessary to reinstall' part?
– savick01
Jul 19 '13 at 22:46
Yeah! Everything works perfectly! And the cloning process was very fast - much faster than normal copying files. I think it was a good decision to make a clone. P.S. I disabled proprietary drivers before clone just in case.
– savick01
Jul 21 '13 at 14:15
add a comment |
up vote
5
down vote
accepted
up vote
5
down vote
accepted
On the receiver end:
nc -l 5678 | sudo dd if=/dev/stdin of=/dev/sda
Then on the sender end:
sudo dd if=/dev/sda of=/dev/stdout | nc 1.2.3.4 5678
This copies sda from one PC to another over the network to IP 1.2.3.4 and port 5678. Be sure to install one of the nc packages (just run nc in the terminal and you will get the suggestion if not installed yet.)
Also make sure not any volume on either of the sda drives has a filesystem mounted, so run off a live CD on both ends if you're unsure.
On the receiver end:
nc -l 5678 | sudo dd if=/dev/stdin of=/dev/sda
Then on the sender end:
sudo dd if=/dev/sda of=/dev/stdout | nc 1.2.3.4 5678
This copies sda from one PC to another over the network to IP 1.2.3.4 and port 5678. Be sure to install one of the nc packages (just run nc in the terminal and you will get the suggestion if not installed yet.)
Also make sure not any volume on either of the sda drives has a filesystem mounted, so run off a live CD on both ends if you're unsure.
answered Jul 19 '13 at 16:56
gertvdijk
49.6k18140234
49.6k18140234
Thank you very much! It was so easy:) In the meantime I started doubting if cloning is such a good idea. I will copy all the drivers and randomly installed packages from the 'sender' machine. What do you think? Is it healthy to reinstall the system from time to time to make it work better or I can just make a clone and enjoy everything working immediately?
– savick01
Jul 19 '13 at 19:08
@savick01 That's a new question - please ask it as such. And if you think this was useful, then consider marking it as correct.
– gertvdijk
Jul 19 '13 at 22:28
0. I already upvoted it and will accept when test (now I have no internet cable available and wifi is too slow(-:). 1. AFAIK discussion questions are not welcome at SE sites, so I just asked for your opinion via comment. 2. If you think it fits here, I can ask it, but there already is a similar question here. Would you be so kind to post your opinion there including the 'healthy or unnecessary to reinstall' part?
– savick01
Jul 19 '13 at 22:46
Yeah! Everything works perfectly! And the cloning process was very fast - much faster than normal copying files. I think it was a good decision to make a clone. P.S. I disabled proprietary drivers before clone just in case.
– savick01
Jul 21 '13 at 14:15
add a comment |
Thank you very much! It was so easy:) In the meantime I started doubting if cloning is such a good idea. I will copy all the drivers and randomly installed packages from the 'sender' machine. What do you think? Is it healthy to reinstall the system from time to time to make it work better or I can just make a clone and enjoy everything working immediately?
– savick01
Jul 19 '13 at 19:08
@savick01 That's a new question - please ask it as such. And if you think this was useful, then consider marking it as correct.
– gertvdijk
Jul 19 '13 at 22:28
0. I already upvoted it and will accept when test (now I have no internet cable available and wifi is too slow(-:). 1. AFAIK discussion questions are not welcome at SE sites, so I just asked for your opinion via comment. 2. If you think it fits here, I can ask it, but there already is a similar question here. Would you be so kind to post your opinion there including the 'healthy or unnecessary to reinstall' part?
– savick01
Jul 19 '13 at 22:46
Yeah! Everything works perfectly! And the cloning process was very fast - much faster than normal copying files. I think it was a good decision to make a clone. P.S. I disabled proprietary drivers before clone just in case.
– savick01
Jul 21 '13 at 14:15
Thank you very much! It was so easy:) In the meantime I started doubting if cloning is such a good idea. I will copy all the drivers and randomly installed packages from the 'sender' machine. What do you think? Is it healthy to reinstall the system from time to time to make it work better or I can just make a clone and enjoy everything working immediately?
– savick01
Jul 19 '13 at 19:08
Thank you very much! It was so easy:) In the meantime I started doubting if cloning is such a good idea. I will copy all the drivers and randomly installed packages from the 'sender' machine. What do you think? Is it healthy to reinstall the system from time to time to make it work better or I can just make a clone and enjoy everything working immediately?
– savick01
Jul 19 '13 at 19:08
@savick01 That's a new question - please ask it as such. And if you think this was useful, then consider marking it as correct.
– gertvdijk
Jul 19 '13 at 22:28
@savick01 That's a new question - please ask it as such. And if you think this was useful, then consider marking it as correct.
– gertvdijk
Jul 19 '13 at 22:28
0. I already upvoted it and will accept when test (now I have no internet cable available and wifi is too slow(-:). 1. AFAIK discussion questions are not welcome at SE sites, so I just asked for your opinion via comment. 2. If you think it fits here, I can ask it, but there already is a similar question here. Would you be so kind to post your opinion there including the 'healthy or unnecessary to reinstall' part?
– savick01
Jul 19 '13 at 22:46
0. I already upvoted it and will accept when test (now I have no internet cable available and wifi is too slow(-:). 1. AFAIK discussion questions are not welcome at SE sites, so I just asked for your opinion via comment. 2. If you think it fits here, I can ask it, but there already is a similar question here. Would you be so kind to post your opinion there including the 'healthy or unnecessary to reinstall' part?
– savick01
Jul 19 '13 at 22:46
Yeah! Everything works perfectly! And the cloning process was very fast - much faster than normal copying files. I think it was a good decision to make a clone. P.S. I disabled proprietary drivers before clone just in case.
– savick01
Jul 21 '13 at 14:15
Yeah! Everything works perfectly! And the cloning process was very fast - much faster than normal copying files. I think it was a good decision to make a clone. P.S. I disabled proprietary drivers before clone just in case.
– savick01
Jul 21 '13 at 14:15
add a comment |
up vote
1
down vote
I can't comment, but I'd like to add to @gertvdijk 's answer that you can use | pv | to show a progress report and it is also wise to add explicit buffer size bs=8M (e.g.) to speed things up (default is 512 bytes which is pretty small). The size depends on your hardware and if you're cloning on local gigabit network or a slower connection. The final command on the receiving end could look like this (add sudo if needed):
nc -l 5678 | dd if=/dev/stdin | pv | of=/dev/sda bs=8M
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
up vote
1
down vote
I can't comment, but I'd like to add to @gertvdijk 's answer that you can use | pv | to show a progress report and it is also wise to add explicit buffer size bs=8M (e.g.) to speed things up (default is 512 bytes which is pretty small). The size depends on your hardware and if you're cloning on local gigabit network or a slower connection. The final command on the receiving end could look like this (add sudo if needed):
nc -l 5678 | dd if=/dev/stdin | pv | of=/dev/sda bs=8M
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
up vote
1
down vote
up vote
1
down vote
I can't comment, but I'd like to add to @gertvdijk 's answer that you can use | pv | to show a progress report and it is also wise to add explicit buffer size bs=8M (e.g.) to speed things up (default is 512 bytes which is pretty small). The size depends on your hardware and if you're cloning on local gigabit network or a slower connection. The final command on the receiving end could look like this (add sudo if needed):
nc -l 5678 | dd if=/dev/stdin | pv | of=/dev/sda bs=8M
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
I can't comment, but I'd like to add to @gertvdijk 's answer that you can use | pv | to show a progress report and it is also wise to add explicit buffer size bs=8M (e.g.) to speed things up (default is 512 bytes which is pretty small). The size depends on your hardware and if you're cloning on local gigabit network or a slower connection. The final command on the receiving end could look like this (add sudo if needed):
nc -l 5678 | dd if=/dev/stdin | pv | of=/dev/sda bs=8M
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
answered Nov 24 at 14:39
Alex
111
111
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Alex is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f321956%2fcloning-ubuntu-over-network%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown