suchusernamemuchcreative Posted October 24, 2014 Report Share Posted October 24, 2014 Hello,how can I set up a config file under linux to change the folder_rescan_interval? First dump a sample config file with btsync-core --dump-sample-config and then? I still want to use the web interface.How can I set this file as the default config file? Or is there any other way to change that interval?Kind Regards Quote Link to comment Share on other sites More sharing options...
Anh Huynh Posted October 24, 2014 Report Share Posted October 24, 2014 here is an example{ "device_name": "example.net", "listening_port" : 1234, // 0 - randomize port /* storage_path dir contains auxilliary app files if no storage_path field: .sync dir created in the directory where binary is located. otherwise user-defined directory will be used */ "storage_path" : "/home/btsync/data/", "folder_rescan_interval": 300,}To start the daemon, use/home/btsync/bin/btsync --config /path/to/btsync.confI use supervisor to monitor btsync process. So I start with/home/btsync/bin/btsync --config /path/to/btsync.conf --nodaemonbecause supervisor already has daemon support. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 24, 2014 Author Report Share Posted October 24, 2014 But I don't want to have a completely new configuration of btsync. I already have it configured via the web interface and only want to change that single argument 'folder_rescan_interval'. Quote Link to comment Share on other sites More sharing options...
Anh Huynh Posted October 24, 2014 Report Share Posted October 24, 2014 Not complete actually. you can use "folder_rescan_interval" from config files, and folder settings still come from web UI. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 25, 2014 Author Report Share Posted October 25, 2014 Not complete actually. you can use "folder_rescan_interval" from config files, and folder settings still come from web UI. But my btsync is fully configured at the moment via debconf. Can't I change only this parameter now without losing all my other settings? Starting btsync with a custom config file makes it use completely new settings. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 25, 2014 Author Report Share Posted October 25, 2014 Does nobody have an answer? Quote Link to comment Share on other sites More sharing options...
GreatMarko Posted October 25, 2014 Report Share Posted October 25, 2014 Does nobody have an answer? Use of a config file will override settings in the Web UI. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 25, 2014 Author Report Share Posted October 25, 2014 Use of a config file will override settings in the Web UI.And is there any way I can keep my current Web UI settings and just change that single parameter? Can't be that hard to accomplish... Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 26, 2014 Author Report Share Posted October 26, 2014 So I guess there is no way then?! Quote Link to comment Share on other sites More sharing options...
trevellyan Posted October 26, 2014 Report Share Posted October 26, 2014 And is there any way I can keep my current Web UI settings and just change that single parameter? Can't be that hard to accomplish... I think you'll find if you only put the settings you need in the config file, the other settings will remain untouched. Also, the new settings will be stored in the internal config that Sync maintains and you won't have to use the config file each time. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 26, 2014 Author Report Share Posted October 26, 2014 I think you'll find if you only put the settings you need in the config file, the other settings will remain untouched. Also, the new settings will be stored in the internal config that Sync maintains and you won't have to use the config file each time. Ok, I think I got my interval changed to 43200 seconds which is half a day. At least the settings.dat file that I just found shows that. But even after a reboot btsync is constantly indexing all the folders, never letting my external hard drive spin down. I can't sleep at night! Any idea? Quote Link to comment Share on other sites More sharing options...
RomanZ Posted October 27, 2014 Report Share Posted October 27, 2014 @suchusernamemuchcreative Please use this python script to set some particular value. Run it with next params:settings.dat set folder_rescan_interval <your_value>Script is experimental, so use with care and backup your settings.dat first. What makes you think that it is indexing files all the time? Also, how many files and folders do you actually have there? Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 27, 2014 Author Report Share Posted October 27, 2014 @suchusernamemuchcreative Please use this python script to set some particular value. Run it with next params:settings.dat set folder_rescan_interval <your_value>Script is experimental, so use with care and backup your settings.dat first. What makes you think that it is indexing files all the time? Also, how many files and folders do you actually have there? Thanks! It ran successfully. Viewing the settings.dat file now shows the value I entered (I tried 43201 just to be sure it took the value). But after a reboot btsync still rescans the folders every ~5 minutes. I can hear my drive spin up and btsyncs shows "Indexing" in the status column. I have 9 folders (all on the external drive) with about 190GiB of data. Btsync appears to always begin indexing with the same folder of 130GiB but then indexes other folders, too. There are no system files on the drive so it must be btsync causing it to spin up. Also it starts to show "Indexing" right when it spins up. Quote Link to comment Share on other sites More sharing options...
RomanZ Posted October 27, 2014 Report Share Posted October 27, 2014 @suchusernamemuchcreative Can you please set the "log_size" preference to, say 500 (Mb), turn on debug logs and sent debug log to me? It looks suspicious indeed, so I'd like to see what makes your Sync to rescan so often. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 27, 2014 Author Report Share Posted October 27, 2014 Ok, what is the unit of log_size? Is ./btsync_edit_settings.py settings.dat set log_size 500correct? Also, my Windows btsync just started showing a blank window (IE11 and everything). :/ Getting tired... Quote Link to comment Share on other sites More sharing options...
RomanZ Posted October 27, 2014 Report Share Posted October 27, 2014 @suchusernamemuchcreativeThe unit is Mb. So, 500 means 500 Mb.For the blank UI - it is a known issue, will be fixed very soon. As a workaround - set the "webui_local_storage" in settings.dat to empty string ("") - it should fix your blank UI. Note that Sync shouldn't be running when you modify settings.dat. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 27, 2014 Author Report Share Posted October 27, 2014 Ok, windows works again. But the sync.log file doesn't seem to collect any data. Still only 1,4kB. I created the file debug.txt containing the stringFFFFin the .sync directory and rebooted. Is that correct? Quote Link to comment Share on other sites More sharing options...
RomanZ Posted October 27, 2014 Report Share Posted October 27, 2014 Looks correct - it your storage folder is .sync, it can be changed in config file is you run binary with the config file. If your storage is .sync - well, let me take a look what these 1.5kb actually contain... Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 27, 2014 Author Report Share Posted October 27, 2014 This is the content. http://paste.pm/jl8.js It's two days old?! Quote Link to comment Share on other sites More sharing options...
RomanZ Posted October 28, 2014 Report Share Posted October 28, 2014 @suchusernamemuchcreativeIt looks like the debug.txt is created in wrong directory, not the one Sync is using to store DB. How do you run Sync? Command line / or some preinstalled package? If first - please share the command line, if it contains config - please share config as well. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 28, 2014 Author Report Share Posted October 28, 2014 I installed this http://forum.bittorrent.com/topic/28106-linux-desktop-gui-unofficial-packages-for-bittorrent-sync/ and now it updates and starts automatically. No separate config file I start it with. I just tried to locate the *.db files (like in windows?) and couldn't find them. That is the folder I should put the debug.txt into, right? You should really embed a lot more options in the web UI! Quote Link to comment Share on other sites More sharing options...
RomanZ Posted October 28, 2014 Report Share Posted October 28, 2014 @suchusernamemuchcreativeOh, okay then. I don't remember exact path where the package stores the data, but there is a simple way to find that out. Once you've started sync, run the command: ps aux | grep sync And one of process displayed will be started with --config <path_to_config> parameter. Look into this config file - it will contain the preference "storage_path" which indicates where DBs are stored and where you need to put the debug.txt (and actually get the log). Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 28, 2014 Author Report Share Posted October 28, 2014 Ok, thanks. That worked fine. When starting btsync via/etc/init.d/btsync startit gives me[ ok ] Autostarting btsync instance 'debconf-default':.Sounds like it always uses the default debconf settings instead of the settings I set up in the settings. dat file. So I tried changing the default debconf file (even though it clearly says I you shouldn't do that, as it will reset itself after an update) and it works. Btsync stopped indexing my files all the time. But how can I make this permanent? Is there a line in the startup script I can change to use the settings.dat instead of the debconf default config file? By the way, logging works now, but doesn't seem to contain any unusual activity as far as I can tell... Quote Link to comment Share on other sites More sharing options...
trevellyan Posted October 29, 2014 Report Share Posted October 29, 2014 Ok, thanks. That worked fine. When starting btsync via/etc/init.d/btsync startit gives me[ ok ] Autostarting btsync instance 'debconf-default':.Sounds like it always uses the default debconf settings instead of the settings I set up in the settings. dat file. I believe the correct way to adjust settings for the packaged version is to use the dpkg-reconfigure command. This will allow you to adjust options that weren't available during the initial install. Quote Link to comment Share on other sites More sharing options...
suchusernamemuchcreative Posted October 29, 2014 Author Report Share Posted October 29, 2014 I believe the correct way to adjust settings for the packaged version is to use the dpkg-reconfigure command. This will allow you to adjust options that weren't available during the initial install. Yeah, I tried it already with the --priority=high argument though. I misunderstood it and I should've used low priority. Now it asked me to enter the rescan interval. So the problem seems to be resolved. Thanks! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.