Multiple Instances + Removable Drives + Local?

If you are experiencing problems with "Everything", post here for assistance.
Post Reply
hapworth
Posts: 1
Joined: Thu Jun 04, 2009 5:55 am

Multiple Instances + Removable Drives + Local?

Post by hapworth » Thu Jun 04, 2009 6:01 am

Hey Everyone!

I apologize if this has already been addressed somewhere, but I did a bit of a search and couldn't find what I needed.

I have three external drives that I occasionally shuffle around from my primary machine, a secondary, and one I take back and forth to work. I want Everything running on all of these drives as well as my local one on my primary machine.

However, I'd love it if each drive had it's own instance that only searched it's own drive.

I had installed the Everything package to my primary machine as well as the Portable versions to each of my external drives. However, whenever I'd execute one of the portable copies, it would pick up the index used by my main drive. When I'd modify it, this would modify it across instances.

I poked around the ini file and certain things looked interesting, but I was afraid of making things explode. Has anyone made this setup work? What settings should I use? And can they run simultaneously? (If all of my drives are plugged into my primary machine, already running Everything, will things clash?... I saw some option under Customization that allowed you to differentiate visually between instances, I'd of course would use this!)

And also, when I have it plugged in at work, I don't want the work machine's drives to be indexed, just my external drive where Everything would be running on.

Thanks!

David
Site Admin
Posts: 430
Joined: Tue Mar 17, 2009 1:42 am

Re: Multiple Instances + Removable Drives + Local?

Post by David » Fri Jun 05, 2009 3:44 am

I would recommend using named instances (http://www.voidtools.com/Everything/wik ... #-instance)

Make 3 copies of the "Everything" installation.
Copy C:\Program Files\Everything to each of the following:

Code: Select all

C:\Program Files\Everything (Drive1)
C:\Program Files\Everything (Drive2)
C:\Program Files\Everything (Drive3)
For each copy of "Everything" create a shortcut to the Everything.exe.
For example:
Create a shortcut to C:\Program Files\Everything (Drive1)\Everything.exe on the desktop.

Add the parameter -instance name to each shortcut target.
For example:

Code: Select all

"C:\Program Files\Everything (Drive1)\Everything.exe" -instance Drive1
"C:\Program Files\Everything (Drive2)\Everything.exe" -instance Drive2
"C:\Program Files\Everything (Drive3)\Everything.exe" -instance Drive3
For each copy of "Everything" Edit the Everything.ini file to exclude all drives except the one of interest.
For example, to index only the D drive add the following to the end of your Everything.ini file:

Code: Select all

check_media_A=0
check_media_B=0
check_media_C=0
check_media_D=1
check_media_E=0
check_media_F=0
check_media_G=0
check_media_H=0
check_media_I=0
check_media_J=0
check_media_K=0
check_media_L=0
check_media_M=0
check_media_N=0
check_media_O=0
check_media_P=0
check_media_Q=0
check_media_R=0
check_media_S=0
check_media_T=0
check_media_U=0
check_media_V=0
check_media_W=0
check_media_X=0
check_media_Y=0
check_media_Z=0
Your main "Everything" will still index all drives.
Everything (Drive1) will only index and maintain the database for drive1.
Everything (Drive2) will only index and maintain the database for drive2.
Everything (Drive2) will only index and maintain the database for drive2.

Please note that this will only work with the drive(s) that are plugged in and visible in Explorer.
Offline searching will be available in a future release.


For your work machine edit the Everything.ini to exclude the work machine's volumes:
Add the following lines to the end of your Everything.ini
For example, assuming Drive D is the external drive:

Code: Select all

check_media_A=0
check_media_B=0
check_media_C=0
check_media_D=1
check_media_E=0
check_media_F=0
check_media_G=0
check_media_H=0
check_media_I=0
check_media_J=0
check_media_K=0
check_media_L=0
check_media_M=0
check_media_N=0
check_media_O=0
check_media_P=0
check_media_Q=0
check_media_R=0
check_media_S=0
check_media_T=0
check_media_U=0
check_media_V=0
check_media_W=0
check_media_X=0
check_media_Y=0
check_media_Z=0

Guillaume
Posts: 4
Joined: Wed Oct 19, 2011 1:08 pm

Re: Multiple Instances + Removable Drives + Local?

Post by Guillaume » Wed Oct 19, 2011 1:21 pm

That's all pretty fantastic 'n all, but how does "Everything" react to drive letter being swapped? I have a removable device I want "Everything" to run on, indexing only all contents of that removable device, although I want to be able to use it on any random system, which would give the device a different drive letter pretty much every time. It shouldn't be too difficult, as everything.exe is on that same particular drive, but is it possible already?

Guillaume
Posts: 4
Joined: Wed Oct 19, 2011 1:08 pm

Re: Multiple Instances + Removable Drives + Local?

Post by Guillaume » Wed Oct 19, 2011 1:46 pm

Hmz, quickly made this in AutoIt, should work:

Code: Select all

$CurrentDrive = StringLeft(@ScriptDir,2)
$Settings = @ScriptDir&'\Programs\Everything\Everything.ini'
If NOT FileExists(@ScriptDir&'\Programs\Everything\Everything.ini') Then
	FileWrite(FileOpen($Settings,2),'[Everything]'&@CRLF _
	&'allow_multiple_instances=1'&@CRLF _
	&'alternate_row_color=1'&@CRLF _
	&'double_click_path=1'&@CRLF _
	&'empty_search_matches_nothing=1'&@CRLF _
	&'filter_toolbar_visible=1'&@CRLF _
	&'last_access_time_column_visible=0'&@CRLF _
	&'recent_change_column_visible=0'&@CRLF _
	&'run_frequency_column_visible=0'&@CRLF _
	&'run_in_background=0'&@CRLF _
	&'show_highlighted_search_terms=1'&@CRLF _
	&'instance_name=Guillaume Media')
	FileClose($Settings)
EndIf

For $i = 65 to 90
	If $CurrentDrive = Chr($i)&":" Then
		IniWrite($Settings,"Everything","exclude_drive_"&Chr($i),"0")
	Else
		IniWrite($Settings,"Everything","exclude_drive_"&Chr($i),"1")
	EndIf
Next
Run(@ScriptDir&'\Programs\Everything\Everything.exe',@ScriptDir&'\Programs\Everything')

Guillaume
Posts: 4
Joined: Wed Oct 19, 2011 1:08 pm

Re: Multiple Instances + Removable Drives + Local?

Post by Guillaume » Thu Oct 20, 2011 9:35 am

Ouch! Semi-intelligent spambot!

Guillaume
Posts: 4
Joined: Wed Oct 19, 2011 1:08 pm

Re: Multiple Instances + Removable Drives + Local?

Post by Guillaume » Thu Dec 08, 2011 2:49 pm

This works better with 1.2.1.451a:

Code: Select all

$CurrentDrive = StringLeft(@ScriptDir,2)
$Settings = @ScriptDir&'\Programs\Everything\Everything.ini'
If NOT FileExists(@ScriptDir&'\Programs\Everything\Everything.ini') Then
	FileWrite(FileOpen($Settings,2),'[Everything]'&@CRLF _
	&'allow_multiple_instances=1'&@CRLF _
	&'alternate_row_color=1'&@CRLF _
	&'double_click_path=1'&@CRLF _
	&'empty_search_matches_nothing=1'&@CRLF _
	&'filter_toolbar_visible=1'&@CRLF _
	&'last_access_time_column_visible=0'&@CRLF _
	&'recent_change_column_visible=0'&@CRLF _
	&'run_frequency_column_visible=0'&@CRLF _
	&'run_in_background=0'&@CRLF _
	&'show_highlighted_search_terms=1'&@CRLF _
	&'instance_name=Guillaume Media')
	FileClose($Settings)
EndIf

Dim $Exclude

For $i = 65 to 90
	If $CurrentDrive = Chr($i)&":" Then
		IniWrite($Settings,"Everything","include_volume_list",Chr($i)&":")
	Else
		$Exclude &= Chr($i)&":;"
	EndIf
Next

IniWrite($Settings,"Everything","exclude_volume_list",$Exclude)
Run(@ScriptDir&'\Programs\Everything\Everything.exe',@ScriptDir&'\Programs\Everything')

Post Reply