一个文件夹如果存放有5万张图片 打开速度的影响大吗?解决办法
一个文件夹如果存放有5万张图片 打开速度的影响大吗?
本来想搞个分类存放 但就是搞不成 如果都集中到一个文件夹 这么多图片对显示速度影响大吗?
------解决方案--------------------
如果是用程序调用图片显示到网页上,影响显示速度的关键因素是磁盘的IO
建议分类放一下比较好
我习惯按年月来自动创建文件夹,一般每个文件夹下面的图片数量最好不要超过1k
------解决方案--------------------
如果你的每张图片(size)基本上都是的很大的话,首先io开销就更大了;要显示到网页上的话,图片太大的显示的会比较慢,甚至有可能还会加载不出来!建议你的话还是分类存放吧!若是网站中运用的话,如果图片以后还要增加,可以用一个单独的服务器存放!
------解决方案--------------------
5万张 有影响 的
------解决方案--------------------
如果是用程序打开指定名字的文件,或者通过 apache 访问指定的文件,应该还好吧。
要是用 WinSCP 这类文件管理工具浏览到这个文件夹,那就死定了。
总之,直接访问文件问题不大,涉及到文件列表就糟糕了。
------解决方案--------------------
200张与500张就能感觉到差异,何况5万张
------解决方案--------------------
5w张?
你弄个10k的图复制5000份 打开测试测试。
------解决方案--------------------
你的打开是什么意思?如果是浏览,肯定慢。建议分文件夹。如果是web读取显示,访问不是很频繁,还可以吧。有钱就上服务器
------解决方案--------------------
慢到感觉要死机

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics











To set up a CGI directory in Apache, you need to perform the following steps: Create a CGI directory such as "cgi-bin", and grant Apache write permissions. Add the "ScriptAlias" directive block in the Apache configuration file to map the CGI directory to the "/cgi-bin" URL. Restart Apache.

There are 3 ways to view the version on the Apache server: via the command line (apachectl -v or apache2ctl -v), check the server status page (http://<server IP or domain name>/server-status), or view the Apache configuration file (ServerVersion: Apache/<version number>).

Apache connects to a database requires the following steps: Install the database driver. Configure the web.xml file to create a connection pool. Create a JDBC data source and specify the connection settings. Use the JDBC API to access the database from Java code, including getting connections, creating statements, binding parameters, executing queries or updates, and processing results.

When the Apache 80 port is occupied, the solution is as follows: find out the process that occupies the port and close it. Check the firewall settings to make sure Apache is not blocked. If the above method does not work, please reconfigure Apache to use a different port. Restart the Apache service.

How to view the Apache version? Start the Apache server: Use sudo service apache2 start to start the server. View version number: Use one of the following methods to view version: Command line: Run the apache2 -v command. Server Status Page: Access the default port of the Apache server (usually 80) in a web browser, and the version information is displayed at the bottom of the page.

How to configure Zend in Apache? The steps to configure Zend Framework in an Apache Web Server are as follows: Install Zend Framework and extract it into the Web Server directory. Create a .htaccess file. Create the Zend application directory and add the index.php file. Configure the Zend application (application.ini). Restart the Apache Web server.

Apache cannot start because the following reasons may be: Configuration file syntax error. Conflict with other application ports. Permissions issue. Out of memory. Process deadlock. Daemon failure. SELinux permissions issues. Firewall problem. Software conflict.

To delete an extra ServerName directive from Apache, you can take the following steps: Identify and delete the extra ServerName directive. Restart Apache to make the changes take effect. Check the configuration file to verify changes. Test the server to make sure the problem is resolved.
