The community help forum (help.nextcloud.com) is for home and non-enterprise users. Support is provided by other community members on a best effort / “as available” basis. All of those responding are volunteering their time to help you.
If you’re using Nextcloud in a business/critical setting, paid and SLA-based support services can be accessed via portal.nextcloud.com where Nextcloud engineers can help ensure your business keeps running smoothly.
Getting help
In order to help you as efficiently (and quickly!) as possible, please fill in as much of the below requested information as you can.
Before clicking submit: Please check if your query is already addressed via the following resources:
(Utilizing these existing resources is typically faster. It also helps reduce the load on our generous volunteers while elevating the signal to noise ratio of the forums otherwise arising from the same queries being posted repeatedly).
Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can.
The Basics
Nextcloud Server version (e.g., 29.x.x):
30.0.4
Operating system and version (e.g., Ubuntu 24.04):
Docker image (apache) on Debian 12 (bookworm)
Web server and version (e.g, Apache 2.4.25):
2.4.62
PHP version (e.g, 8.3):
8.2.27
Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
Docker for Nextcloud server
Summary of the issue you are facing:
I would just like some clarification regarding the “files_external” OCC command, specifically about the “scan” operation. I’m alreadying using “files:scan” scoped to a --path=“/files/” for scanning my content on locally mounted ext4 partitions (external drive).
Does “files_external:scan” do anything different from the standard “files:scan” for locally mounted volumes? Is it more efficient?
I did see the documentation but all I see that’s different is
files_external:scan provides the ability to provide a username and/or password for cases where login credentials are used.
Is there any functional difference in the way that it does the scanning for external storage using this command outside of configuring username/password?
I also see this for files_external:scan
Scan an external storage for changed files
However, when I run both commands in verbose mode, I see that both operations are iterating through every file.
You must start with the first paragraph of the documentation-section I liked for you.
The first paragraph in the documentation says:
These commands are used for managing Nextcloud’s External Storage feature. In addition to replicating the configuration capabilities in the Web UI, additional capabilities include exporting / importing configurations, scanning External Storage mounts that require login credentials, and configuring update notifications (if supported by the storage type).
Note
These commands are only available when the “External storage support” app (files_external) is enabled.
It is dedicated to scan files on external storage.
Appreciate that. I’m not trying to be obtuse here and I see that the files_external package as a whole provides a bunch of capabilities for managing and accessing external storage. But I’m specifically interested in the “scan” aspect of it and understanding if there is any material difference between that and the standard “files:scan” operation in terms of just scanning in files?
As I stated, I’m currently using the latter for scanning files but would like to understand if the two are effectively equivalent in how they scan files? Should I use one vs the other for any reason when it comes to external storage files?
It’s the same scanner code path. There’s some additional handling for scanning only specific External Storage mounts and for specifying the credentials to use in the frontend. Behind the scenes, same Scanner class.
outside of cron you could use the time command in front of the occ and test if any is faster then the other. but I doubt there be any difference on small scale changes.