A friend of mine asked me the other day if there was such a thing as Partition Magic for Solaris. Apparently, someone had installed a system on a single slice and they’re security team was requiring a separate partition for the DB.
Here are the givens:
- Sunfire V210
- Solaris 8 (Otherwise we’d be using zfs)
- 2 73GB disks
- 1 slice on disk1
- Disk 2 is supposed to be a mirror of disk 1 but it isn’t used yet
- Downtime is allowed
- Reinstalling is not an option
I personally don’t know of any tool that lets you shrink UFS partitions but that doesn’t mean that we can’t perform some Partition Magic of our own.
NOTE: I have not tested this procedure. I think it is logical and should work and it should do no harm as the first disk remains fully intact.
- Go into single user mode
- Partition the second disk as required.
- newfs the partitions on the second disk
- Mount the second disk’s partitions
- Use ufsdump/ufsrestore to copy the filesystem into it’s smaller home
ufsdump 0f - / | ( cd /mnt/newroot ;ufsrestore xvf - )
- When all the partitions are done, use installboot to make the second disk bootable.
installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk /dev/rdsk/c1t2d0s0
- Shutdown the system, physically swap the disks, and do a reconfiguration reboot.
If rebooting goes smoothly, test your new system thoroughly and then build your mirrors.
I recently installed Solaris 10 06/06 x86 on my desktop machine, a Compaq Evo with an onboard Intel 10/100 network card.
At first the Solaris installation seemed to hang while trying to find a network configuration from a non-existant RPC boot server. In retrospect, I think the problem was that Solaris didn’t find an appropriate driver for the card but after waiting a long time, the installation continued skipping the network configuration.
Running prtconf -pv shows the pci identification details for the ethernet card:
model: ‘Ethernet controller’
Looking up the identification information in the PCI ID repository tells me I’m dealing with a 82801DB PRO/100 VM (LOM) Ethernet Controller
Looking at /boot/solaris/devicedb/master, I found the following similar drivers:
bash-3.00# grep 82801DB /boot/solaris/devicedb/master
pci8086,1039 pci8086,1039 net pci iprb.bef “Intel 82801DB Ethernet 82562ET/EZ PHY”
pci8086,103d pci8086,103d net pci iprb.bef “Intel 82801DB PRO/100 VE Ethernet”
Both cards use the iprb driver so I add the identifier for my driver into /etc/driver_aliases:
Load the driver with the modload command and plumb the interface:
ifconfig iprb0 plumb
If that works, create the /etc/hostname.iprb0 file. I wanted to use DHCP so I did the following:
Then do a reconfigure reboot.