Why do I see a MATLAB error about "No space left on device" while using "xlsread" on a Linux OS?
10 views (last 30 days)
Show older comments
MathWorks Support Team
on 6 Aug 2019
Edited: MathWorks Support Team
on 25 Nov 2025
I am using the "xlsread" function on a Linux OS and encounter the following error:
Error using xlsread (line 260)
No space left on device
Why is this error occurring, and how do I resolve this?
Accepted Answer
MathWorks Support Team
on 7 Oct 2025
Edited: MathWorks Support Team
on 25 Nov 2025
If you do have free space on your device, it is likely that your Linux system runs out of "inodes", resulting in this error.
To debug this further and fix the issue, see the following troubleshooting and solution steps:
(1) Check available disk space to ensure that you still have some left. This can be done using the "df" command on the Linux terminal.
(2) Next, check information about available "inodes" using the command "df -i" on the Linux terminal.
If the "IUse%" value in the results is at or around 100, then a huge number of small files is the reason for the “No space left on device” errors.
(3) Find the small files using the below command on the Linux terminal or as a Shell script:
for i in /*; do echo $i; find $i |wc -l; done
This command will list directories and number of files in them. Once you see a directory with unusually high number of files (or where the command hangs over the calculation for a long time), repeat the command for that directory to see where exactly the small files are.
(4) Once you have found the suspect files, delete the files using the below command on the Linux terminal or as a Shell script:
sudo rm -rf /home/your_user/directory_with_lots_of_empty_files
(5) Check the results with the "df -i" command again on the Linux terminal to see lower usage percentages.
If the issue persists, contact MathWorks Technical Support.
0 Comments
More Answers (0)
See Also
Categories
Find more on Startup and Shutdown in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!