Linux Help
guides forums blogs
Home Desktops Distributions ISO Images Logos Newbies Reviews Software Support & Resources Linuxhelp Wiki

Welcome Guest ( Log In | Register )



Advanced DNS Management
New ZoneEdit. New Managment.

FREE DNS Is Back

Sign Up Now
 
Reply to this topicStart new topic
> Moving /boot From One Disk To Other, via ssh (if possible)
Robert83
post May 19 2005, 08:01 AM
Post #1


Its GNU/Linuxhelp.net
*******

Group: Support Specialist
Posts: 1,439
Joined: 3-January 04
From: Germany
Member No.: 2,069



Hello everyone,

I need to move /boot from a smaller (and very old drive) to a newer one.

CODE
[root@frodo root]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/hdc1             4.8G  692M  3.9G  16% /
/dev/hda1             3.4G   42M  3.2G   2% /boot
none                  502M     0  502M   0% /dev/shm
/dev/hdc2              29G   16G   12G  57% /share
/dev/hdc3              29G  7.7G   20G  28% /share2
/dev/hdc5              29G   23G  4.4G  84% /share3
/dev/hdc6              21G  367M   20G   2% /var
/dev/hdb1             113G   67G   41G  63% /backuppc


I would like to move /boot from /dev/hda1 to /dev/hdc1 /
how can one do this safely (cause I'm doing it via ssh)

Sincerely
Robert B


--------------------
Robert Becskei
robert83@linuxhelp.net
--------------------
May the source be with us!
--------------------
AMD X2-3800 @ 2400Mhz
2048MB DDR 400Mhz
DFI Lanparty UT4 NF4 ULTRA-D
GeForce 7800GT
250GB+250GB
Pioneer DVD-RW
17inch Samsung Syncmaster 757NF
WinXP Pro (SP2)/ CentOS 4.3
--------------------
Go to the top of the page
 
+Quote Post
Corey
post May 19 2005, 11:16 AM
Post #2


Its GNU/Linuxhelp.net
*******

Group: Admin
Posts: 1,254
Joined: 21-September 02
From: St John's, Newfoundland, Canada
Member No.: 3



QUOTE
mkdir temp
mount /dev/hdc1 /mnt/temp
cp -a /boot/* /mnt/temp/
umount /mnt/temp
umount /mnt/boot
mount /dev/hdc1 /mnt/boot


If you're using grub, go into the grub config file and change the references from your old boot device to your new one, may be something like:

hd(2,0)

That should be all there is to it. Double check the permissions on /boot afterwards, but the cp -a should preserve the permisssions and owners.

I do this often with my /home directory. Whenever i install linux with a seperate /home partition, i always wanna use that partition for something else, so i just do what i stated above, and it usually works fine.


--------------------
Corey Quilliam
(former) Linuxhelp.ca Administrator
cquilliam-AT-gmail-dot-com

Want to help out Linuxhelp.net? Check out our Linuxhelp Wiki and see if there are some articles you would like to submit!!

--
Ubuntu 8.04 64-bit - Work Laptop (HP-Compaq NC6400 Core2)
Kubuntu 8.04 64-bit - Desktop (HP m8120n QuadCore)
Ubuntu 6.04 - Server (I'm not upgrading this baby until support runs out in 2012) (Some old POS dell)
Go to the top of the page
 
+Quote Post
Robert83
post May 19 2005, 12:27 PM
Post #3


Its GNU/Linuxhelp.net
*******

Group: Support Specialist
Posts: 1,439
Joined: 3-January 04
From: Germany
Member No.: 2,069



Thanx Corey !


--------------------
Robert Becskei
robert83@linuxhelp.net
--------------------
May the source be with us!
--------------------
AMD X2-3800 @ 2400Mhz
2048MB DDR 400Mhz
DFI Lanparty UT4 NF4 ULTRA-D
GeForce 7800GT
250GB+250GB
Pioneer DVD-RW
17inch Samsung Syncmaster 757NF
WinXP Pro (SP2)/ CentOS 4.3
--------------------
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 17th October 2017 - 01:54 PM