Keep everything from updating database

General discussion related to "Everything".
Post Reply
kazzybash
Posts: 110
Joined: Mon Mar 02, 2020 9:55 pm

Keep everything from updating database

Post by kazzybash »

Hello,

sometimes I use everything (which is a marvellous piece of software that I use daily) on a partition that has a lot of files of which only a small portion changes between sessions. Scanning this disk does take some time and even though I want to use some database, it does not have to be 100% accurate. Sometimes good enough is just good enough :-) .

My question is: is there a way to force everything to use a database that is not 100% up to date (or: not to update on startup)?

Regards, Kazz
void
Developer
Posts: 16680
Joined: Fri Oct 16, 2009 11:31 pm

Re: Keep everything from updating database

Post by void »

Please try the -read-only command line option when starting Everything:
Everything.exe -read-only
NotNull
Posts: 5458
Joined: Wed May 24, 2017 9:22 pm

Re: Keep everything from updating database

Post by NotNull »

void wrote: Mon Mar 02, 2020 11:02 pm Alternatively, start Everything with the monitors paused:
Starting Everything with Everything.exe -monitor-pause -debug
shows that it is still reading the USN Journal to updatae the database:
( I disabled the Index recent changes option to take that out of the equation)

Debug log (partial):

Code: Select all

Everything
Version 1.4.1.947 (x64)
Windows NT 6.2
Processors 2
IsAdmin 0
AppData 0
Service 1
cmdline "C:\Tools\Everything\Everything.exe" -monitor-pause -debug
db_load


enter setfocus
leave setfocus
enter main loop
new results 0
fs out of date 0
fs NTFS C: 1
fs out of date 0
fs out of date 0
loaded run history in 0.002127 seconds
run history data count: 145, data: 10921 bytes
run history ptr count: 122
total run history memory usage: 31441 bytes

update index C:
open volume \\?\Volume{ddd1ecb4-0000-0000-0000-f01500000000}
CreateFileW(): GetLastError(): 5: Failed to open volume \\?\Volume{ddd1ecb4-0000-0000-0000-f01500000000}
opened -1 0.009830
new thread (1)
open service volume \\?\Volume{ddd1ecb4-0000-0000-0000-f01500000000}
USN DATA_TRUNCATION EVERYTHING.EXE-035ED7A6.pf
USN DATA_EXTEND DATA_TRUNCATION EVERYTHING.EXE-035ED7A6.pf
USN DATA_EXTEND DATA_TRUNCATION CLOSE EVERYTHING.EXE-035ED7A6.pf

...

USN CREATE Everything.db.tmp
USN CREATE DATA_EXTEND Everything.db.tmp
USN CREATE DATA_EXTEND CLOSE Everything.db.tmp
USN DELETE CLOSE Everything.db
USN RENAME_OLD_NAME Everything.db.tmp
USN RENAME_NEW_NAME Everything.db
USN RENAME_NEW_NAME CLOSE Everything.db

updated C: in 0.258613 seconds
processed usn records in 0.003395 seconds
loaded 69344 folders, 318204 files, in 0.750200 seconds
DB_WAIT: _db_load_complete_proc waiting...
DB_WAIT: _db_load_complete_proc waited 0.001457 seconds
void
Developer
Posts: 16680
Joined: Fri Oct 16, 2009 11:31 pm

Re: Keep everything from updating database

Post by void »


-or-

Alternatively, start Everything with the monitors paused:
Everything -monitor-pause

To resume monitors:
  • In Everything, type in the following search and press ENTER:
    /monitor_resume



Thanks for bringing this to my attention.
Everything does do an update before the monitors are paused (It looks like this is how I initially designed it..). I've put this on my things to fix list.
NotNull
Posts: 5458
Joined: Wed May 24, 2017 9:22 pm

Re: Keep everything from updating database

Post by NotNull »

void wrote: Tue Mar 03, 2020 9:29 am I've put this on my things to fix list.
Sorry for that ...
kazzybash
Posts: 110
Joined: Mon Mar 02, 2020 9:55 pm

Re: Keep everything from updating database

Post by kazzybash »

Hi

thanks for the quick response. Very helpful, because it is exactly what i asked for.

In using this option however I found out the downside of my request very quickly. For instance: renaming a folder is not reflected in the database.

Obviously. You cannot eat your cake and have it. But it would be nice to be able to skip the process of initial scanning and have consecutive mutations reflected in real-time.

regards, kazz
NotNull
Posts: 5458
Joined: Wed May 24, 2017 9:22 pm

Re: Keep everything from updating database

Post by NotNull »

Another way to accomplish this, is to enable Start Everything on system startup ( Menu:Tools > Options > General ).
That way Everything will run in the background and keeps it's index up-to-date.

When you want to use Everything, it is already done reading all the file changes (and there are a lot! Even if you don't actively change anything at all) so you can use it right away.
void
Developer
Posts: 16680
Joined: Fri Oct 16, 2009 11:31 pm

Re: Keep everything from updating database

Post by void »

I've put this on my things to fix list.
Sorry for that ...
Thanks for testing the -monitor-pause command and letting me know it doesn't work as intended. It is appreciated.

-monitor-pause is currently sent to the active instance to pause the monitors, this will happen after the db has been loaded and updated.
I don't have an easy fix for this. I will address it in Everything 1.5.

Future versions of Everything (Everything 1.5+) will update in the background and you'll be able to search immediately after starting Everything.

Some suggestions:

1). Keeping Everything running in the background will help reduce the "updating database"... status (As NotNull mentioned).

2). Disable software that might be constantly changing your file system.
You can run Everything in debug mode to see file system changes:
  • In Everything, type in the following search and press ENTER:
    /debug
File system changes are shown in Cyan color.
To close the debug console:
  • In Everything, type in the following search and press ENTER:
    /debug
3). Try using folder indexing instead of NTFS indexing.
Folder indexes are always updated in the background.
  • In Everything, from the Tools menu, click Options.
  • Click the NTFS tab.
  • For each NTFS volume:
    • Uncheck Include in database.
  • Click the Folders tab.
  • Click Add....
  • Select a NTFS volume and click OK.
  • Repeat for additional NTFS volumes.
  • Click OK.
Your folder indexes will be updated in the background when you start Everything.
void
Developer
Posts: 16680
Joined: Fri Oct 16, 2009 11:31 pm

Re: Keep everything from updating database

Post by void »

Everything 1.4.1.967 fixes an issue with -monitor-pause not working as intended.


To start Everything with the monitors paused:
Everything -monitor-pause

To resume monitors:
  • In Everything, type in the following search and press ENTER:
    /monitor_resume
NotNull
Posts: 5458
Joined: Wed May 24, 2017 9:22 pm

Re: Keep everything from updating database

Post by NotNull »

Tested .. works as advertised.

Couple of notes (just a FYI):
- With the the monitors paused, "Updating database" is still shown in the status bar (briefly).
- As a test, I deleted Everything.db and started Everything with -montor-pause. The database is rebuild (as expected).
kazzybash
Posts: 110
Joined: Mon Mar 02, 2020 9:55 pm

Re: Keep everything from updating database

Post by kazzybash »

void wrote: Wed Mar 04, 2020 1:09 am Some suggestions: etc etc
thanks for this, I will try this out.

Sorry for not answering for some time.

All stay well, regards, Kazz
Post Reply