Greyhole behind the scenes
Greyhole behind the scenes
I have a system which is a mix of internal and external drives. I want to prioritize the internal drives in the pool so that the external drive gets used as a last resort. Having recently read http://www.pommepause.com/blog/2010/03/ ... l-is-that/ I decided this woudl get me some of the way there but cannot work out how to modify the greyhole.yml file to achieve this.
Re: Greyhole behind the scenes
The sticky_files option will probably get you where you want to be.
What you want is to define sticky_files for all your shares, with stick_into value that will point to your internal drives.
The downside of this is that the same drive will always be used first for the files of a specific share. i.e. you'll need to manage the pooling manually.
You can see examples of sticky_files & stick_into here: http://wiki.amahi.org/index.php/Greyhol ... ed_options
For example, if your internal drives are drive1 to drive3 in /var/hda/files/drives/
Notice how I alternate the order the drives are used. This is to try to spread the data on the different drives.
What you want is to define sticky_files for all your shares, with stick_into value that will point to your internal drives.
The downside of this is that the same drive will always be used first for the files of a specific share. i.e. you'll need to manage the pooling manually.
You can see examples of sticky_files & stick_into here: http://wiki.amahi.org/index.php/Greyhol ... ed_options
For example, if your internal drives are drive1 to drive3 in /var/hda/files/drives/
Code: Select all
sticky_files = Videos/
stick_into = /var/hda/files/drives/drive1
stick_into = /var/hda/files/drives/drive2
stick_into = /var/hda/files/drives/drive3
sticky_files = Music/
stick_into = /var/hda/files/drives/drive2
stick_into = /var/hda/files/drives/drive3
stick_into = /var/hda/files/drives/drive1
sticky_files = Photos/
stick_into = /var/hda/files/drives/drive3
stick_into = /var/hda/files/drives/drive1
stick_into = /var/hda/files/drives/drive2
- Guillaume Boudreau
Re: Greyhole behind the scenes
OK sounds good so can I just make sure I understand this
lets say I have 3 internal drives and 2 external drives.
I want to be able to say for example
which would mean 'prefer' Videos on drive1, overspill onto drive2 then drive3
How does this affect pooling? I am worried that for example some areas I want to do this for require multiple copies. Ideally I'd like to specify that that external drives should be used for secondary copies, but I know that today I cannot do that.
So what I want to do is weight the USB to be the least favoured drive (which is why I mentioned that link in my original post).
lets say I have 3 internal drives and 2 external drives.
I want to be able to say for example
Code: Select all
sticky_files = Videos/
stick_into = /var/hda/files/drives/drive1
stick_into = /var/hda/files/drives/drive2
stick_into = /var/hda/files/drives/drive3
How does this affect pooling? I am worried that for example some areas I want to do this for require multiple copies. Ideally I'd like to specify that that external drives should be used for secondary copies, but I know that today I cannot do that.
So what I want to do is weight the USB to be the least favoured drive (which is why I mentioned that link in my original post).
Re: Greyhole behind the scenes
The example you give above also applies to multiple copies.
If you specify you want two copies of your files, the first one would be on drive1, and the second on drive2.
If drive1 ever gets filled, the 1st copy would go on drive2, and the 2nd copy on drive3. etc.
So if you want a share with 2 file copies, and you want the 2nd on an external drive, you can specify that drive as the second stick into drive. This will work until the 1st drive is filled to capacity. At that point, you'd need to manually change the stick_into options to specify other drives to use.
As I said, using sticky_files forces you to manually manage the pooling.
This is not ideal, but it's the best you can do with Greyhole, unless you're a programer and would like to add this feature into Greyhole yourself.
Note: the correct stick_into path to use would be /var/hda/files/drives/drive#/gh, since Amahi creates a gh folder at the root of your drives, and uses that to store pooled data.
If you specify you want two copies of your files, the first one would be on drive1, and the second on drive2.
If drive1 ever gets filled, the 1st copy would go on drive2, and the 2nd copy on drive3. etc.
So if you want a share with 2 file copies, and you want the 2nd on an external drive, you can specify that drive as the second stick into drive. This will work until the 1st drive is filled to capacity. At that point, you'd need to manually change the stick_into options to specify other drives to use.
As I said, using sticky_files forces you to manually manage the pooling.
This is not ideal, but it's the best you can do with Greyhole, unless you're a programer and would like to add this feature into Greyhole yourself.
Note: the correct stick_into path to use would be /var/hda/files/drives/drive#/gh, since Amahi creates a gh folder at the root of your drives, and uses that to store pooled data.
- Guillaume Boudreau
Re: Greyhole behind the scenes
An issue has been created on the Greyhole issue tracker, to keep track of this enhancement request: http://code.google.com/p/greyhole/issues/detail?id=69
You can star that issue if you'd like to be notified if this ever gets implemented.
You can star that issue if you'd like to be notified if this ever gets implemented.
- Guillaume Boudreau
Re: Greyhole behind the scenes
Thanks gboudreau
Who is online
Users browsing this forum: No registered users and 12 guests