Stephen Munnings <steve@cormantech.com> wrote:
In article <> MPG.15b675f8e3f80d1f989695@inn.qnx.com> >, > steve@cormantech.com
says…
Hi,
I am at a point where I need to copy my (working, mostly) QNX6.1.0
partition to another partition (bigger, much) in order to “expand” my
partition.
The approach I am taking is as follows:
- Create the new partition of type 77 (The old one is type 79)
- Reboot the system so that the enumerator sees the new partition (even
though it sees it as corrupt)
- dinit the partition (with a ./diskroot file)
- Re-boot the system again - picking the “old” partition when asked
- slay fs-pkg (so I don’t get all those circular and “virtual” file
structures - after all what I want is essentially a ‘clone’ of my current
partition.
- run cp -r / to /fs/hd0-qnx4
( I had to find cp in the “real” file structure first…>
Is this a workable approach, and will it work correctly, or will I have
things like symbolic links and other things messed up?
Regards, and TIA
So…
Nobody at QSSL is willing to confirm or deny that this is a workable
approach?
No gotcha’s??
Assent by silence?
Well I don’t know if that would hold up in court or not, but
I’ll provide you with my thoughts in any case =;-)
Your steps above seem to be sane for the most part. My
personal preference in these matters is to take a whole
partition as “personal space” and use that for /home
and then leave all of the “system” things on the other
partition, this includes the packages. This also makes
some maintenance chores a little bit easier.
The things that you might want to do is to cp your shell
utilities to /dev/shmem before you slay fs-pkg so that
they are easier to find. In fact you could also copy
over the packages (/pkgs) directly to the new partition
first before copying any of the other data. Then installing
a prefix will allow you to map things over with a
restart of the package filesystem.
Of course perhaps the easiest thing to do would be just
to create a boot floppy with only devb-eide, a shell and
some assorted utilities. Mount your two partitions and
do a direct copy without even running any of the other
“things” in the system.
Here is a boot image that I typically use when I’m network
booting here:
Modify this to your liking
#[search=/usr/nto/x86/sbin:/usr/nto/x86/usr/sbin:/usr/nto/x86/bin:/usr/nto/x86/usr/bin:/usr/nto/x86/lib:/usr/nto/x86/lib/dll:/usr/nto/x86/boot/sys:/usr/nto/x86/boot/build:/usr/nto/x86/boot/sys]
[virtual=x86,bios +compress] boot = {
startup-bios -v -N thomasf3
PATH=/proc/boot:/bin LD_LIBRARY_PATH=/proc/boot:/dev/shmem:/lib:/dll procnto
}
[+script] startup-script = {
DL_DEBUG=1
SYSNAME=nto
PROCESSOR=x86
LD_LIBRARY_PATH=/proc/boot:/dev/shmem:/lib:/dll
PATH=/proc/boot:/bin
devc-con -n8
waitfor /dev/con1
reopen /dev/con1
display_msg Starting pipe server
pipe
waitfor /dev/pipe
#Start devb-eide and have it
display_msg Starting devb-eide
devb-eide
waitfor /dev/hd0
[+session pri=10r] esh &
reopen /dev/con2
[+session pri=10r] esh &
reopen /dev/con3
[+session pri=10r] esh &
reopen /dev/con4
[+session pri=10r] esh &
reopen /dev/con5
[+session pri=20r] esh &
}
[type=link] /dev/console=/dev/con1
[type=link] /tmp=/dev/shmem
[type=link] /bin/sh=/proc/boot/esh
An excessive amount of loading going on here!
#[type=link] /usr/lib/ldqnx.so.1=/lib/libc.so.1
[type=link] /usr/lib/ldqnx.so.1=/proc/boot/libc.so.2
[type=link] /usr/lib/ldqnx.so.2=/proc/boot/libc.so.2
[type=link] /usr/lib/ldqnx.so=/proc/boot/libc.so.2
libcam.so.2
io-blk.so
cam-disk.so
cam-cdrom.so
fs-qnx4.so
#fs-cd.so
#fs-dos.so
[data=c]
devc-con
devb-eide
seedres
pci-bios
ls
cp
esh
less
pipe
mount
pidin
\
You might also consider taking a look at the “rescue” disk image
that I put together a while ago.
http://staff.qnx.com/~thomasf/nto.html
Thomas (toe-mah) Fletcher QNX Software Systems
thomasf@qnx.com Neutrino Development Group
(613)-591-0931 http://www.qnx.com/~thomasf