ZFS Data Deduplication

In solaris 11, you can use the deduplication (dedup) property to remove redundant data from your ZFS file systems.

To turn in on use

zfs set dedup=on rpool

But before you do that make sure that you need it

# zdb -S rpool
Simulated DDT histogram:

bucket allocated referenced
______ ______________________________ ______________________________
—— —— —– —– —– —— —– —– —–
1 116K 8.14G 8.14G 8.14G 116K 8.14G 8.14G 8.14G
2 3.12K 101M 101M 101M 6.72K 208M 208M 208M
4 788 11.7M 11.7M 11.7M 3.73K 60.5M 60.5M 60.5M
8 260 460K 460K 460K 2.71K 5.10M 5.10M 5.10M
16 76 42K 42K 42K 1.63K 918K 918K 918K
32 30 20.5K 20.5K 20.5K 1.10K 764K 764K 764K
64 11 8K 8K 8K 991 718K 718K 718K
128 1 1.50K 1.50K 1.50K 138 207K 207K 207K
256 2 1K 1K 1K 979 490K 490K 490K
1K 2 130K 130K 130K 3.01K 176M 176M 176M
Total 120K 8.25G 8.25G 8.25G 136K 8.58G 8.58G 8.58G

dedup = 1.04, compress = 1.00, copies = 1.00, dedup * compress / copies = 1.04

Here the dedup ratio (dedup = 1.04) is less than 2, so enabling is not recommended.

Solaris 11 – install the desktop

So you just used the Solaris 11 text cd to install Solaris 11 but now you have no desktop.

# pkg install solaris-desktop

and sit back and wait while it takes forever to download 539Mb

Or, you can use the alternate boot environment of Solaris to install (basically they merged pkgadd and lucreate from Solaris 10

# pkg install –require-new-be –be-name newBEname solaris-desktop

By default the new boot environment you specified will be the default on the next reboot.

If you specify the –no-be-activate option, the new BE is not the default boot selection the next time you reboot

Creating an Oracle Solaris 11 USB install device

Creating an Oracle Solaris 11 USB install device.

From: The let’s put the cart before the horse department

First off, in order to create a solaris 11 bootable USB stick, you need the usbcopy utility which is only on Solaris 11.

Booting off the Solaris 11 live DVD won’t work because /var/pkg/lock and / are read only
(And here I thought I was going to be sneaky).

Also the opensolaris windows utility for creating a boot-able USB stick won’t work with the Solaris 11 USB image.

1. Download the Solaris 11 text install iso

2. Burn it to CD

2. Install Solaris 11

4. Install the Solaris install utilities

root@solaris11:/# pkg install install/distribution-constructor

5. Download the Solaris 11 USB image

6. Burn the image to the USB stick

root@solaris11:/# usbcopy sol-11-1111-text-x86.usb
Found the following USB devices:
0: /dev/rdsk/c5t0d0p0 7.8 GB SanDisk Cruzer Contour 4.08
Enter the number of your choice: 0

WARNING: All data on your USB storage will be lost.
Are you sure you want to install to
SanDisk Cruzer Contour 4.08, 7800 MB at /dev/rdsk/c5t0d0p0 ? (y/n) y
Copying and verifying image to USB device
Finished 515 MB in 136 seconds (3.7MB/s)
0 block(s) re-written due to verification failure
Installing grub to USB device /dev/rdsk/c5t0d0s0
Completed copy to USB

root@solaris11:/# umount /media/PENDRIVE-1