I've been running Amahi for a while now (ubuntu 12.04 server) and got to the point of having to extend my storage capacity by adding another drive.
While pondering which format to choose for the new disk this ZFSDriveConversion caught my attention and I thought - why not?
Since I needed at least 0.9.29 to make this work I've manually upgraded greyhole to the most recent stable 0.9.35 (with a little help from the wiki)
I then put in a brand new Toshiba 3TB harddisk, used
Code: Select all
parted /dev/sdb mklabel gpt
Code: Select all
$ sudo zfs list
NAME USED AVAIL REFER MOUNTPOINT
toshiba3TB 764K 2.69T 136K none
toshiba3TB/ROOT 148K 2.69T 148K /mnt/toshiba3tb
I created the directory
Code: Select all
/mnt/toshiba3tb/gh
Code: Select all
/etc/greyhole.conf
Code: Select all
storage_pool_directory = /mnt/wd1500gb/gh, min_free: 10gb
However, the new disk is never used by greyhole (as far as I can see anyways). ie: It is not listed on the amahi frontend (no big deal) and fsks will not put data in /gh (big deal ). Also:
Code: Select all
$ mysql -u root -phda -e "select * from disk_pool_partitions" hda_production
+----+-----------------+--------------+---------------------+---------------------+
| id | path | minimum_free | created_at | updated_at |
+----+-----------------+--------------+---------------------+---------------------+
| 4 | /mnt/wd1500gb | 10 | 2012-08-04 17:27:49 | 2012-08-04 17:27:49 |
| 5 | /mnt/wd2tb | 10 | 2012-08-04 17:27:50 | 2012-08-04 17:27:50 |
| 6 | /mnt/seagate3tb | 10 | 2012-08-04 17:27:50 | 2012-08-04 17:27:50 |
+----+-----------------+--------------+---------------------+---------------------+
Code: Select all
$ less /etc/greyhole.conf
[...]
log_level = DEBUG
log_memory_usage = false
dir_selection_algorithm = most_available_space
df_cache_time = 15
delete_moves_to_attic = true
sticky_files = Music/
# add any group of other settings
# here in multiple lines
drive_selection_groups = OK: /mnt/wd1500gb/gh, /mnt/wd2tb/gh, /mnt/seagate3tb/gh
REMOTE: /mnt/toshiba3tb/gh
drive_selection_algorithm = forced (1xOK, 1xREMOTE) most_available_space
storage_pool_directory = /mnt/toshiba3tb/gh, min_free: 10gb
storage_pool_drive = /mnt/toshiba3tb/gh, min_free: 10gb
storage_pool_directory = /mnt/wd1500gb/gh, min_free: 10gb [...]
EDIT: The entry in mysql (hda_production/disk_pool_partitions) was missing. Adding it via phpmyadmin (amahi webapp) did the trick.
fsck works now and it is listed in the Amahi 'Storage Pool'. There is, however, a white on orange exclamation mark where 'Total space' would list its size. Anyone know why or what I'm still missing?
Making changes to greyhole from the amahi web frontend will reset the config file (as is noted at the top of said file).
It is also noted that changes should go to
Code: Select all
/var/hda/platform/html/config/greyhole.yml
EDIT: never mind the last paragraph - the .yml file passes a section of raw strings and so this one is hackable
Thanks for reading!