Problem removing /var/hda/files

evylrat
Posts: 106
Joined: Sun Jan 02, 2011 6:37 pm

Problem removing /var/hda/files

Postby evylrat » Mon Feb 18, 2013 12:20 pm

Versions;

Code: Select all

2.6.35.6-45.fc14.x86_64 samba-3.5.8-76.fc14.x86_64 hda-greyhole-0.9.31-1.x86_64
/etc/samba/smb.conf

Code: Select all

http://fpaste.org/XFBr/
/etc/greyhole.conf

Code: Select all

http://fpaste.org/79Sb/
Originally I'd found lots of files in the /var/hda/files/gh folder, that had not appeared on the share. So I followed the advice on http://forums.amahi.org/viewtopic.php?f=39&t=4035 and tried to use the GOING command on /var/hda/files/gh.
Greyhole said it couldn't find it. So I unchecked if from the control panel anyway, then when I checked greyhole, my drive 1 was missing. I stopped and restarted the service, did not fix it.
I check the /etc/greyhole.conf file and there was an error.

Code: Select all

df_cache_time = 15 delete_moves_to_attic = true sticky_files = Music/storage_pool_directory = /var/hda/files/drives/drive1/gh, min_free: 10gb storage_pool_directory = /var/hda/files/drives/drive2/gh, min_free: 10gb storage_pool_directory = /var/hda/files/drives/drive3/gh, min_free: 10gb num_copies[Books] = 1 num_copies[Pictures] = 1 num_copies[Movies] = 1
It had moved one of the lines to the end of another line. I fixed this (as you can see from fpaste above) and I got my drive back. Is this a bug?

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Problem removing /var/hda/files

Postby bigfoot65 » Wed Feb 20, 2013 2:43 pm

Had you been editing the .conf file? Sometimes changing what the dashboard and Greyhole expects causes other issues.

If you suspect this may be a bug with Greyhole, please use it's bug tracker. If you think it's Amahi related, use ours.

Either way, if you file a bug please provide details.
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

evylrat
Posts: 106
Joined: Sun Jan 02, 2011 6:37 pm

Re: Problem removing /var/hda/files

Postby evylrat » Sat Mar 16, 2013 8:18 am

This error has recurred this morning. A vast amount of my MP3s disappeared from my shared music directory this morning. When I checked the status of Greyhole, it showed only drives 2 and 3. Checking the greyhole.conf file, it was as shown in the first post, with two lines merged.

Oh, just spotted the error. Looking at https://wiki.amahi.org/index.php/Greyho ... ed_options.
I've written

Code: Select all

sticky_files: - - Music/
rather than

Code: Select all

sticky_files: - - Music/
I hope that fixed it.

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Problem removing /var/hda/files

Postby bigfoot65 » Sat Mar 16, 2013 8:35 am

Syntax is crucial. I tend to not make changes to the .conf file. Minimizes error :-)

[ Post made via Android ] Image
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

evylrat
Posts: 106
Joined: Sun Jan 02, 2011 6:37 pm

Re: Problem removing /var/hda/files

Postby evylrat » Sun Mar 17, 2013 10:24 am

Still doing it. I've commented out the line in /var/hda/platform/html/config/greyhole.yml

Code: Select all

# sticky_files: # - - Music/
But the lines in greyhole.conf keep combining, which stops Drive1 from being picked up.

Debating whether going from Fedora to Ubuntu on my Atom D525 machine will make any difference.

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Problem removing /var/hda/files

Postby bigfoot65 » Sun Mar 17, 2013 10:29 am

Did you follow the guidance in the wiki for modifying this file?

https://wiki.amahi.org/index.php/Greyhole

Seems like there may be something out of place still. Might consider checking the Greyhole site as well. Could go back to the default greyhole.yml file, then try modifying it again.
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

evylrat
Posts: 106
Joined: Sun Jan 02, 2011 6:37 pm

Re: Problem removing /var/hda/files

Postby evylrat » Sun Mar 17, 2013 11:27 am

I just remembered what I changed originally. I wanted the CrashPlan share NOT to use the Attic. running the scripts at the top of the YML file, it showed an error on that line.

BUT using the sample conf file on the greyhole page also errors...

Code: Select all

echo 'require "yaml"; YAML::load(File.open("greyhole.yml"))' | irb require "yaml"; YAML::load(File.open("greyhole.yml")) ArgumentError: syntax error on line 18, col 0: ` email_to = root' from /usr/lib/ruby/1.8/yaml.rb:133:in `load' from /usr/lib/ruby/1.8/yaml.rb:133:in `load' from (irb):1 from /usr/lib/ruby/1.8/date.rb:247
using the sample file at https://gist.github.com/deanperry/1379102

I've put it back to as it was, with the crashplan line commented out, but it still fails the syntax check at the end of the file. Argh! Still broken! It's like it's not even reading the greyhole.yml file. I am going into HDA shares, clicking on a path, and hitting save, the greyhole.conf is being regenerated incorrectly.

If it worth DOWNGRADING it?

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Problem removing /var/hda/files

Postby bigfoot65 » Sun Mar 17, 2013 11:50 am

What version of Greyhole are you using? Also if you cut and paste from a web page, it is likely there may be hidden characters embedded.

There is a util called dos2unix that you can try to ensure that is not a problem. Install it via the package manager, then do

Code: Select all

dos2unix greyhole.yml
.

It's those darn DOS characters that sometimes get in the way. Not sure if it will fix your issue, but worth a shot.
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

evylrat
Posts: 106
Joined: Sun Jan 02, 2011 6:37 pm

Re: Problem removing /var/hda/files

Postby evylrat » Sun Mar 17, 2013 12:02 pm

Done,

Code: Select all

[xxxx@amahi config]$ sudo dos2unix greyhole.yml dos2unix: converting file greyhole.yml to UNIX format ... [xxxx@amahi config]$ echo 'require "yaml"; YAML::load(File.open("greyhole.yml"))' | irb require "yaml"; YAML::load(File.open("greyhole.yml")) ArgumentError: syntax error on line 58, col 1: `' from /usr/lib/ruby/1.8/yaml.rb:133:in `load' from /usr/lib/ruby/1.8/yaml.rb:133:in `load' from (irb):1 from /usr/lib/ruby/1.8/date.rb:247
The last line of greyhole.yml is just a comment.

Code: Select all

Fedora :: 2.6.35.6-45.fc14.x86_64 Samba :: samba-3.5.8-76.fc14.x86_64 Greyhole :: hda-greyhole-0.9.31-1.x86_64
Using the sample on the greyhole site and dos2unix still gives an error.

Code: Select all

[richardt@amahi config]$ sudo dos2unix greyhole.yml dos2unix: converting file greyhole.yml to UNIX format ... [richardt@amahi config]$ echo 'require "yaml"; YAML::load(File.open("greyhole.yml"))' | irb require "yaml"; YAML::load(File.open("greyhole.yml")) ArgumentError: syntax error on line 18, col 0: ` email_to = root' from /usr/lib/ruby/1.8/yaml.rb:133:in `load' from /usr/lib/ruby/1.8/yaml.rb:133:in `load' from (irb):1 from :0
But still the greyhole.conf generates with the error.

User avatar
bigfoot65
Project Manager
Posts: 11924
Joined: Mon May 25, 2009 4:31 pm

Re: Problem removing /var/hda/files

Postby bigfoot65 » Sun Mar 17, 2013 2:17 pm

Definitely something odd going on here.

Ensure the files is owned by apache:apache. I have listed what mine looks like to see if that will help.

Code: Select all

# # Greyhole default settings # # Note: if you make changes to this file and they do not appear # in the greyhole.conf, please double check the formatting. To # test the parsing of this file do: # # echo 'require "yaml"; YAML::load(File.open("greyhole.yml"))' | irb # # db_engine: sqlite or mysql db_engine: mysql # options for sqlite db engine db_path: /var/cache/greyhole.sqlite # options for mysql db engine db_name: greyhole db_user: greyhole db_pass: greyhole db_host: localhost # other defaults: email_to: root greyhole_log_file: /var/log/greyhole.log log_level: DEBUG log_memory_usage: no dir_selection_algorithm: most_available_space df_cache_time: 15 delete_moves_to_attic: yes balance_modified_files: no # sticky_files and stick_into options can have special nested formatting. *indentation matters* # see the details here http://wiki.amahi.org/index.php/Greyhole#Greyhole_advanced_options sticky_files: - - Music/ # special note about this field: # # * the format of this section is passed *raw* # to he greyhole.conf file. i.e. use setting = value in greyhole # style, not setting: value # * do not use tabs in new lines below, use spaces. otherwise the # yaml parser gets confused. (fwiw: vim does that automatically) # other: |- # add any group of other settings # here in multiple lines
I have not made any modifications and I am running the latest Greyhole, v0.9.31.
ßîgƒσστ65
Applications Manager

My HDA: Intel(R) Core(TM) i5-3570K CPU @ 3.40GHz on MSI board, 16GB RAM, 1TBx1+2TBx2+4TBx2

Who is online

Users browsing this forum: No registered users and 28 guests