> I have been unsuccessful in booting my Solaris 2.3 machine after moving /usr
> to a different disk (on another controller) labeled /usr2. I've tried
> linking /usr to /usr2 but the system still will not boot. My last attempt
> will be to make changes to the vfstab (it's more direct) however I need to
> know how can I change the /usr2 directory to /usr now that the original /usr
> is gone?. I'm afraid if I do just a cp -r the links will not be properly
> managed. I would have to do this from CD-ROM of course.
> Any ideas?.
> Thanks.
In brief all you want to do is mount your usr on usr rather than usr2
should be pretty simple.
and remove your symlink!!!, just make it a mount point instead
Hope I havent confused you as much as I did myself :)
Arran
My opinions are my own and do not reflec those of my employer.
Could you please post a copy of you actual /etc/vfstab file as well as
an explanation of how are /usr and /usr2 configured (is any one of them a
link, a filesystem, a subdirectory? More details please!)
Now, to move FILESYSTEMS you can use this command:
ufsdump 0f - /dev/rdsk/cwtxdysz | (cd /target_dir;ufsrestore xf - )
where: /dev/rdsk/cwtxdysz is the raw partition where your source
filesystem is living. Change w,x,y,z as appropiate and if in doubt ask
first.
Cheers
init 1 (single user mode)
make the new directory as you have indicated you already have, with a
unique name.
Copy the files from device to device with:
find {source_dir} -print | cpio -pmud {target_dir}
-or-
tar cvf - {source_dir} | tar xvf - {target_dir}
-or-
bounce it to-from tape. This has advantages is all else failes!
{hopefully you used the /etc/vfstab for creating the temp usr directory}
reverse the naming in /etc/vfstab
reboot -- -sr (reboot w/no takedown options, single user, reconfigure
boot)
if [it worked] then
do
fsck /usr
reboot
done
else
do
insert Solaris CDRom
boot cdrom -s
undo /usr /usr2 switch mentioned earlier
done
endif
*REMEMBER: do not do anything bad to the origional /usr until you are
sure all worked, and have tested the system in multi-user mode.
--
=====================================================
my opions are mine and do not represent my employer
and
I have brain damage
so
don't take life so seriosly, you won't get out alive!
=====================================================
First of all you don't want to use cp -r it will not keep your permissions
intact etc. instead use:
find . -depth -print | cpio -pdlmv /newdir
Scott R. Haven
Scotch_
Quote:> I have been unsuccessful in booting my Solaris 2.3 machine after moving
/usr
> to a different disk (on another controller) labeled /usr2. I've tried
> linking /usr to /usr2 but the system still will not boot. My last
attempt
> will be to make changes to the vfstab (it's more direct) however I need
to
> know how can I change the /usr2 directory to /usr now that the original
/usr
> is gone?. I'm afraid if I do just a cp -r the links will not be properly
> managed. I would have to do this from CD-ROM of course.
> Any ideas?.
> Thanks.
> > I have been unsuccessful in booting my Solaris 2.3 machine after moving
> /usr
> > to a different disk (on another controller) labeled /usr2. I've tried
> > linking /usr to /usr2 but the system still will not boot. My last attempt
> > will be to make changes to the vfstab (it's more direct) however I need to
> > know how can I change the /usr2 directory to /usr now that the original
> /usr
> > is gone?. I'm afraid if I do just a cp -r the links will not be properly
> > managed. I would have to do this from CD-ROM of course.
> > Any ideas?.
> > Thanks.
> You have really a mess here and you ought to explain exactly how your
> machine is right now before you go any further, from there I am sure you
> will find sound advice in this newsgroup.
> Could you please post a copy of you actual /etc/vfstab file as well as
> an explanation of how are /usr and /usr2 configured (is any one of them a
> link, a filesystem, a subdirectory? More details please!)
> Now, to move FILESYSTEMS you can use this command:
> ufsdump 0f - /dev/rdsk/cwtxdysz | (cd /target_dir;ufsrestore xf - )
> where: /dev/rdsk/cwtxdysz is the raw partition where your source
> filesystem is living. Change w,x,y,z as appropiate and if in doubt ask
> first.
> Cheers
> reply:
> Well I was sucessfull in doing the following: I edited the vfstab /usr2
> entry and changed it to /usr (deleting the original /usr entry) pointing to
> the new slice on my 2nd disk (on c1t1d0s1). The systme booted!. What's
> confusing is that I created a /usr2 in root, made an entry in vfstab for
> usr2 to point to c1t1d0s1 then mounted /usr2 and dumped /usr to /usr2.
> Since the system booted, I deleted /usr2 directory (nothing was in it).
> There is no link to /usr2 from /usr. All this worked but I don't fully
> understand why?
What you did changing /usr2 to /usr was to provide a bunch of programs
that your machine needs to do anything useful.
No problem. Just use the command I gave earlier and then edit yourQuote:> Next I formated c0t3d0s6 & 7 and re-arranged the partition sizes and newfs'd
> the 2 slices. I'm ready to move /usr to the new slice but I'm hesitant to
> do so until I understand why the above worked.
> Included are attachements for vfstab, ls output, mount and df-k output.
Cheers
---------------------------------------------------
To send e-mail please remove the anti-spam and use:
my username: jlms
my mailbox sits in: geocities.com
1. Consequences of moving /usr/dt, /usr/java1.1, /usr/share
Guys,
I've got a pretty full /usr directory and I could free up a bunch of
space by moving /usr/dt, /usr/java1.1 and /usr/share and creating
appropriate links. Near as I can tell, there's nothing essential to the
boot up process in any of these directories.
Can anybody think of any other consequences?
Thanks,
BV
--
egrep -v '(celery|broccoli|spinach)' /dev/plate|\
cat - /dev/beer_can|chew|swallow 2>/dev/burp|\
digest 2>/dev/fart >/dev/toilet\
:wq
2. core files
3. Moving /usr, /usr/src to new disk?
5. Moving /usr/lpp or subtrees to diff. filesys
7. Move /usr
8. Need an Xwindows server for a pc
9. can't boot after moving /usr partition/drive
10. Safe way to move /usr, /var
11. Moving /USR to a new partition
13. moving /usr to /