Can't search through the OneDrive folder

English support forum

Moderators: sheep, Hacker, Stefan2, white

italianoleone
Junior Member
Junior Member
Posts: 11
Joined: 2015-07-06, 11:37 UTC

Can't search through the OneDrive folder

Post by *italianoleone »

Hello,

If I run ALT+F7 (Find Files) in the "c:\Users\italianoleone\" folder with the "search in subdirectories" option turned on, I don't get any results from the "c:\Users\italianoleone\OneDrive\" subfolder.

I noticed that the OneDrive folder icon is displayed as a shortcut in TC although its folder properties say that it's a File Folder Type just like any other folder on my laptop.

How can I make TC search through the OneDrive subfolder? Workaround at the moment is to run two searches; first in the "c:\Users\italianoleone\" folder and the second search in the "c:\Users\italianoleone\Onedrive" folder.

Many thanks

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39593
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Can't search through the OneDrive folder

Post by *ghisler(Author) »

You will have to wait for TC 9.50. Microsoft changed the behaviour of the OneDrive folder with almost every release of Windows 10, it's a real mess.
Author of Total Commander
http://www.ghisler.com

italianoleone
Junior Member
Junior Member
Posts: 11
Joined: 2015-07-06, 11:37 UTC

Re: Can't search through the OneDrive folder

Post by *italianoleone »

Thanks, that's good news.

User avatar
lgb-this
Junior Member
Junior Member
Posts: 8
Joined: 2019-10-22, 10:16 UTC
Contact:

Re: Can't search through the OneDrive folder

Post by *lgb-this »

I run Win10 1903 with the current beta 9.50b2 of TotalCmd. I can't search files in my Onedrive root and deeper.

Any idea ?

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39593
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Can't search through the OneDrive folder

Post by *ghisler(Author) »

Strange, it works here. Do you use the "Files on demand" option in the OneDrive settings?
Author of Total Commander
http://www.ghisler.com

User avatar
lgb-this
Junior Member
Junior Member
Posts: 8
Joined: 2019-10-22, 10:16 UTC
Contact:

Re: Can't search through the OneDrive folder

Post by *lgb-this »

Correct. The option "files on demand" is enabled. TotalCommander does not go into the OneDrive directories during a search. The directories of each sync shows the symbol like a link. The settings of this link shows as type "directory".

User avatar
lgb-this
Junior Member
Junior Member
Posts: 8
Joined: 2019-10-22, 10:16 UTC
Contact:

Re: Can't search through the OneDrive folder

Post by *lgb-this »

No change with Beta3. The file-search does not work in my OneDrive root. If i go one step into a sync directory of OneDrive, the file-search works fine.

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39593
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Can't search through the OneDrive folder

Post by *ghisler(Author) »

Unfortunately none of my PCs has these strange OneDrive links any more. Therefore I have added logging functions so I can analyze your problems.
Please go to menu Configuration - Options - Logging and enable a log file. Then try to search. Finally, please post the lines concerning OneDrive here:

They will look like this:
03.11.2019 12:43:06: Copy(Error: failed): IsOneDriveReparsePointW: other reparse tag = -1610612733 -> c:\checked_path
Author of Total Commander
http://www.ghisler.com

User avatar
lgb-this
Junior Member
Junior Member
Posts: 8
Joined: 2019-10-22, 10:16 UTC
Contact:

Re: Can't search through the OneDrive folder

Post by *lgb-this »

I get a file TmdDE60.tmp. This file seems to be binary. How can i convert this file into text ?

User avatar
lgb-this
Junior Member
Junior Member
Posts: 8
Joined: 2019-10-22, 10:16 UTC
Contact:

Re: Can't search through the OneDrive folder

Post by *lgb-this »

Hier der Log-Auszug:

Code: Select all

05.11.2019 08:30:54: Kopieren(Fehler: Fehlgeschlagen): IsOneDriveReparsePointW: onedrivepath -> C:\Users\MAMA\OneDrive\
05.11.2019 08:30:54: Kopieren(Fehler: Fehlgeschlagen): IsOneDriveReparsePointW: not in onedrive path -> d:\OneDrive\OneDrive - RSRG
05.11.2019 08:30:55: Kopieren(Fehler: Fehlgeschlagen): IsOneDriveReparsePointW: not in onedrive path -> d:\OneDrive\RSRG\Alice - Dokumente

User avatar
lgb-this
Junior Member
Junior Member
Posts: 8
Joined: 2019-10-22, 10:16 UTC
Contact:

Re: Can't search through the OneDrive folder

Post by *lgb-this »

Test with new Beta 4 - search in OneDrive still not possible.

Code: Select all

09.11.2019 08:16:27: Kopieren(Fehler: Fehlgeschlagen): IsOneDriveReparsePointW: not in onedrive path -> d:\OneDrive\OneDrive - RSRG
09.11.2019 08:16:27: Kopieren(Fehler: Fehlgeschlagen): IsOneDriveReparsePointW: not in onedrive path -> d:\OneDrive\RSRG\Alice - Dokumente

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39593
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Can't search through the OneDrive folder

Post by *ghisler(Author) »

You seem to have multiple onedrive folders. TC looks in the registry where OneDrive is, and ignores links there if they cannot be opened.
So do links in c:\Users\MAMA\OneDrive\ work?
And how do you have additional folder d:\OneDrive\? Is it linked from c:\Users\MAMA\OneDrive?
Author of Total Commander
http://www.ghisler.com

User avatar
lgb-this
Junior Member
Junior Member
Posts: 8
Joined: 2019-10-22, 10:16 UTC
Contact:

Re: Can't search through the OneDrive folder

Post by *lgb-this »

We have a private OneDrive (called OneDrive RSRG in the pic below) and a business OneDrive (called RSRG).

Image: http://www.beathis.ch/r/sharepoint_expl.jpg (only link, pic not directly visible here)

Every sync in our SharePoint creates an individual entry point in the OneDrive for Business section.

I changed the main path of OneDrive to drive D. It seems, that there is still an old path with the original drive C in my registry.

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39593
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Can't search through the OneDrive folder

Post by *ghisler(Author) »

The problem is how to recognize these fake file system links made by OneDrive from real reparse points:
1. On older Windows 10 versions, I could open them with CreateFile and flags FILE_FLAG_BACKUP_SEMANTICS or FILE_FLAG_OPEN_REPARSE_POINT and then read their content with DeviceIoControl(...,FSCTL_GET_REPARSE_POINT,...). I could then check the ReparseTag field to know whether they are real reparse points, or fake OneDrive.

2. On newer Windows 10 versions, DeviceIoControl(...,FSCTL_GET_REPARSE_POINT,...) fails with error 4390, which means error_not_a_reparse_point. If I get this error, I check whether the fake file system link is within the OneDrive folder, and if yes, I wollow it. I could always follow it if I get error 4390, but I fear that some other reparse points could also cause such an error.
Author of Total Commander
http://www.ghisler.com

User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 39593
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Can't search through the OneDrive folder

Post by *ghisler(Author) »

This should be fixed since beta 10, can someone test this please?
17.12.19 Fixed: Show fake OneDrive reparse points as <DIR> instead of <LNK>, by checking with FindFirstFile whether the value of dwReserved0 equals one of the cloud values 0x9000101A..0x9000F01A (32/64)
This should make the OneDrive folder appear as a directory instead of a link, making search work inside.
Author of Total Commander
http://www.ghisler.com

Post Reply