Re: Moving partition

1998-12-24 Thread Torsten Hilbrich
Alexander Kushnirenko <[EMAIL PROTECTED]> writes:

> > Symbolic links are just names of files. If the path of the
> > destination stays the same (/usr is still /usr, even though the
> > mount table is different) you shouldn't have problems just using
> > cp. But I haven't done this before in truth.
> 
> I'm not sure about that.  If I got it right plain cp will copy the
> file, it will not create a symobolic link.  So your symbolic link
> structure will be ruined.  tar on the other hand preserves it.

If you use the -d (preserve links), -p (preserve file attributes) and
-R (copy directories recursively) you should have no problems with cp.
The short cut for all three parameters is -a.

Torsten

-- 
Homepage: http://www.in-berlin.de/User/myrkr


Re: Moving partition

1998-12-24 Thread wtopa

Subject: Re: Moving partition
Date: Wed, Dec 23, 1998 at 11:01:03PM -0400

In reply to:[EMAIL PROTECTED]

Quoting [EMAIL PROTECTED]([EMAIL PROTECTED]):
> 
> >> In fact, my problem is : How do I move files from an old parttion to a new 
> >one while
> >> ensure all links (and things like that) are kept ?
> >
> This is the way I've done it dozens of times...its from the days prior to
> cp having the correct attributes to do it correctly, and maintain last
> access times, etc...
> 
> mount the target filesystem (lets say at /mnt)
> cd to the top of the one which you want to copy...lets say /usr
> then, this command:
> 
> find . -depth | cpio -pdmv /mnt
> 
> The result at /mnt will be AN EXACT duplicate of the filesystem.  I 
> understand that the more recent GNU cp will do the same, but this is
> the way I've always done it, and still do.
> 
> Paul

I prefer
 ( cd $DIR ; tar clf - . ) | ( cd /mnt$DESTDIR ; tar xvpBf - )

But as they say, in Linux there is Always another way!

Happy Holidays.

-- 
Real computer scientists don't program in assembler.  They don't write
in anything less portable than a number two pencil.
___
Wayne T. Topa <[EMAIL PROTECTED]>


Re: Moving partition

1998-12-24 Thread wb2oyc
>> In fact, my problem is : How do I move files from an old parttion to a new 
>one while
>> ensure all links (and things like that) are kept ?
>
This is the way I've done it dozens of times...its from the days prior to
cp having the correct attributes to do it correctly, and maintain last
access times, etc...

mount the target filesystem (lets say at /mnt)
cd to the top of the one which you want to copy...lets say /usr
then, this command:

find . -depth | cpio -pdmv /mnt

The result at /mnt will be AN EXACT duplicate of the filesystem.  I 
understand that the more recent GNU cp will do the same, but this is
the way I've always done it, and still do.

Paul


Re: Moving partition

1998-12-23 Thread Frank Barknecht
Alexander Kushnirenko hat gesagt: // Alexander Kushnirenko wrote:

> > On Wed, Dec 23, 1998 at 08:49:46AM +0100, root wrote:
> > > I already have different partitions for / , /var , /home , /usr.
> > > In fact, my problem is : How do I move files from an old parttion to a 
> > > new one while
> > > ensure all links (and things like that) are kept ?
> > 
> > Symbolic links are just names of files. If the path of the destination
> > stays the same (/usr is still /usr, even though the mount table is
> > different) you shouldn't have problems just using cp. But I haven't done
> > this before in truth.
> 
> I'm not sure about that.  If I got it right plain cp will copy the file, it 
> will not create a symobolic link.  So your symbolic link structure will be 
> ruined.  tar on the other hand preserves it.

The cp from GNU can be used with the option "-a". It will then copy
symbolic links as well. (see "man cp")

I always use "cp -ax" to copy whole partitions because I cannot memorize
command lines with more than 8 characters. 
-- 
 ____
 Frank Barknecht    __    __ trip\ \  / /wire __
  / __// __  /__/ __// // __  \ \/ /  __ \\  ___\   
 / /  / /  / /  / // // /\ \\  ___\\ \  
/_/  /_/  /_/  /_//_// /  \ \\_\\_\
/_/\_\ 


Re: Moving partition

1998-12-23 Thread Alexander Kushnirenko
Hi,

just a comment

> On Wed, Dec 23, 1998 at 08:49:46AM +0100, root wrote:
> > I already have different partitions for / , /var , /home , /usr.
> > In fact, my problem is : How do I move files from an old parttion to a new 
> > one while
> > ensure all links (and things like that) are kept ?
> 
> Symbolic links are just names of files. If the path of the destination
> stays the same (/usr is still /usr, even though the mount table is
> different) you shouldn't have problems just using cp. But I haven't done
> this before in truth.

I'm not sure about that.  If I got it right plain cp will copy the file, it 
will not create a symobolic link.  So your symbolic link structure will be 
ruined.  tar on the other hand preserves it.

Sasha.


Re: Moving partition

1998-12-23 Thread Michael E. Touloumtzis
> How do I move files from an old parttion to a new one while
> ensure all links (and things like that) are kept ?

One way to do this is to use tar:
( cd /old/location ; tar cf - . ) | ( cd /new/location ; tar xpf - )

> What is the command to format (initialise ?) a partition ?

To create a file system use the appropriate command for the files system
type, e.g. mke2fs for the "second extended files system" that is common
in Linux.  Beware: you will be erasing any data that currently exists
in the partition!

Use the mount command to mount the new partition and add an entry to
/etc/fstab to automatically mount it at boot time.

- MikeT

-- 
Michael E. Touloumtzis <[EMAIL PROTECTED]>


Re: Moving partition

1998-12-23 Thread Rafael Kitover
On Wed, Dec 23, 1998 at 08:49:46AM +0100, root wrote:
> I already have different partitions for / , /var , /home , /usr.
> In fact, my problem is : How do I move files from an old parttion to a new 
> one while
> ensure all links (and things like that) are kept ?

Symbolic links are just names of files. If the path of the destination
stays the same (/usr is still /usr, even though the mount table is
different) you shouldn't have problems just using cp. But I haven't done
this before in truth.

> 
> What is the command to format (initialise ?) a partition ?

mkfs

auto mounts are in /etc/fstab

-- 
Rafael Kitover
[EMAIL PROTECTED]


Re: Moving partition

1998-12-23 Thread root
I already have different partitions for / , /var , /home , /usr.
In fact, my problem is : How do I move files from an old parttion to a new one 
while
ensure all links (and things like that) are kept ?

What is the command to format (initialise ?) a partition ?

Thanks
Franck


>> On Tue, Dec 22, 1998 at 09:16:37AM +0100, [EMAIL PROTECTED] wrote:
>> > 
>> > I have no more space left on my /dev/hda2 partition which is mounted on /
>> > I have a swap partition /dev/hda3
>> > I can create a bigger partition (say /dev/hdb7) to temporary move my root 
>> > directory. I also can 
>> > create a new swap partition (/dev/hdb5)
>> 
>> You could also make a new partition and mount it as /home, or /usr, or some 
>> such.
>> 
>> -- 
>> Rafael Kitover
>> [EMAIL PROTECTED]
>> 
>> 
>> -- 
>> Unsubscribe?  mail -s unsubscribe [EMAIL PROTECTED] < /dev/null
>> 
>> 






Re: Moving partition

1998-12-22 Thread wb2oyc
>
>You could also make a new partition and mount it as /home, or /usr, or 
>some such.
>
Glad to hear that suggestion as that is precisely what I would do!
Actually, I never put it all on one partition anyway.  Old habits 
are hard to break.  I like to get /var and /home OFF the root if
possible, and generally use a single separate partition for /usr
also.

That also makes it easier to take advantage of multiple disks and
the 2nd IDE controller on most m'bds these days.  I typically put
the 1st disk along with the CD (if ATAPI) and a 2nd disk, even if
its small, on the 2nd IDE port.  Put swap and /var on it, or even
/home.

Another advantage of this is, when you decide to try another distribution
you just use /home with it, and swap, plus, you often have a partition or
two around that comes in handy when it comes time to resize one, or move
stuff around, etc.

You'll find the system performance will be a little better too, 'cause
it'll be able to take better advantage of the capabilities by keeping
the I/O going on two disks instead of all of it on one, plus the
additional controller channel.

Paul


Re: Moving partition

1998-12-22 Thread Rafael Kitover
On Tue, Dec 22, 1998 at 09:16:37AM +0100, [EMAIL PROTECTED] wrote:
> 
> I have no more space left on my /dev/hda2 partition which is mounted on /
> I have a swap partition /dev/hda3
> I can create a bigger partition (say /dev/hdb7) to temporary move my root 
> directory. I also can 
> create a new swap partition (/dev/hdb5)

You could also make a new partition and mount it as /home, or /usr, or some 
such.

-- 
Rafael Kitover
[EMAIL PROTECTED]


Re: moving partition boundries???

1998-08-13 Thread Christopher Barry
I used to have Partition Magic 3.0x installed back in the days when I
was using a 2GB disk and it was definately one of my favorite programs.
There was a posting on Slashdot awhile back that Partition Magic 4.0,
when released, will fully support Linux partitions with ext2 formating,
and IIRC this part would be available for free download. Definately a
good thing

I remember 3.0x would at least recognise ext2 partitions but you
couldn't move, resize, play with cluster sizes (don't know why you'd
want to do this with ext2 anyways though), etc... none of the cool
things PM lets you do with fat/vfat/fat32/hpfs/ntfs partitions. Another
cool thing about PM is that you don't need to manually defrag a
partition before resizing it. Quite an impressive piece of software
Powerquest managed to pull off

Of course, now that I have my 9.1GB disk I don't really need it anymore
since at any given time it seems I have at least 2GB of unpartitioned
space and I keep my disk _very_ split so if I want to move ext2
partitions around I can use the 2GB+ for temporary space to store the
files from an Ext partition while preparing where the files are to go.

The ability to change the boundaries of the extended partition sure is
something I miss though when I had PM 3.0x. This operation never took
more than a fraction of a second (unlike, say, resizing a partition and
changing the cluster size at the same time, which would take _FOREVER_,
understandably). Since the extended partition resize only takes a
fraction of a second and the extended partition itself has no formatting
of any kind to complicate matters then I suppose that fundamentally all
that defines an extended partition may just be a few bytes of data in
the MBR to set boundaries, so if that is true then AFAIK it couldn't be
modifying more than 512 bytes of data, which leads one to wonder if a
free extended partition resizer could be developed without taking too
much time/effort. Of course, I think partitioning software is the last
thing on the list of stuff most people would be willing to beta test


Hank Fay wrote:
> 
> I checked with PM tech, and they confirmed this. They can recognize and I
> think create; but that's it.
> 
> Hank
> 
> -Original Message-
> From: Ed Cogburn [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, August 12, 1998 11:37 AM
> To: Debian Users
> Subject: Re: moving partition boundries???
> 
> Richard E. Hawkins Esq. wrote:
> >
> > I thought I saw an option for this in fdisk along the way, but now i can't
> > find it.  Now that I've moved about 40 floppies over by hand (no network
> > card), I've found that if I set up a hibernation file in dos, the hardware
> > will automatically use it.  So I'd like to peel back the end of my
> > / partition by 20mb . . . Is there any way to do this, or am I stuck
> > with a complete reinstall if i want this?
> >
> > rick
> >
> 
> I'm afraid you are stuck.  I think somebody said the commercial app
> Partition Magic can do this, but I'll bet it can only split DOS/Win FAT
> type partitions.  There is no prog in the Linux world, that I've heard
> of, that can split an ext2 partition.
> 
> --
> Ed C.
> 
> --
> Unsubscribe?  mail -s unsubscribe [EMAIL PROTECTED] < /dev/null


RE: moving partition boundries???

1998-08-13 Thread Hank Fay
I checked with PM tech, and they confirmed this. They can recognize and I
think create; but that's it.

Hank

-Original Message-
From: Ed Cogburn [mailto:[EMAIL PROTECTED]
Sent: Wednesday, August 12, 1998 11:37 AM
To: Debian Users
Subject: Re: moving partition boundries???


Richard E. Hawkins Esq. wrote:
>
> I thought I saw an option for this in fdisk along the way, but now i can't
> find it.  Now that I've moved about 40 floppies over by hand (no network
> card), I've found that if I set up a hibernation file in dos, the hardware
> will automatically use it.  So I'd like to peel back the end of my
> / partition by 20mb . . . Is there any way to do this, or am I stuck
> with a complete reinstall if i want this?
>
> rick
>


I'm afraid you are stuck.  I think somebody said the commercial app
Partition Magic can do this, but I'll bet it can only split DOS/Win FAT
type partitions.  There is no prog in the Linux world, that I've heard
of, that can split an ext2 partition.


--
Ed C.


Re: moving partition boundries???

1998-08-12 Thread Ed Cogburn
Richard E. Hawkins Esq. wrote:
> 
> I thought I saw an option for this in fdisk along the way, but now i can't
> find it.  Now that I've moved about 40 floppies over by hand (no network
> card), I've found that if I set up a hibernation file in dos, the hardware
> will automatically use it.  So I'd like to peel back the end of my
> / partition by 20mb . . . Is there any way to do this, or am I stuck
> with a complete reinstall if i want this?
> 
> rick
> 


I'm afraid you are stuck.  I think somebody said the commercial app
Partition Magic can do this, but I'll bet it can only split DOS/Win FAT
type partitions.  There is no prog in the Linux world, that I've heard
of, that can split an ext2 partition.


-- 
Ed C.