What's new

ext4 formatted USB disk shown as full

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

NetVicious

Occasional Visitor
Hi!
I connected one USB disk formatted with ext4 filesystem and it's shown as full in the website and ssh:

Code:
ASUSWRT-Merlin RT-AC68U 380.68-4 Wed Oct  4 19:01:14 UTC 2017

X@RT-AC68U-0C70:/tmp/home/root# df -h

Filesystem                Size      Used Available Use% Mounted on
.....
/dev/sda1               916.9G    898.4G         0 100% /tmp/mnt/sda1

Code:
X@RT-AC68U-0C70:/tmp/home/root# mount

.....
/dev/sda1 on /tmp/mnt/sda1 type ext4 (rw,nodev,relatime,barrier=1,data=ordered)

Obviously the hard disk it's not full (look Size and Used in df), but I cannot add files within Samba.

The permissions on "USB Application / Network place (samba) Share" are ok, the user has RW on that disk.

I can add files within SCP with WinSCP without any problem. A bit strange :-(

I checked the permissions on the folders and set all to 777.

The system it's plenty on free inodes:
Code:
X@RT-AC68U-0C70:/tmp/mnt/sda1# tune2fs -l /dev/sda1 | grep node
Filesystem features:      has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
Inode count:              61054976
Free inodes:              61047477
 
Last edited:
I don't think the used/available space discrepancy is anything to do with the router. You'll see the same sort of numbers with any ext4 filesystem on any server. I'd guess that most of the difference will be down to the reserved blocks which are typically 5%.
 
May be, but a bit strange it allows me to add new files within SCP on the same usb disk

I will try make some free space on the device.

Regards,
 
It could be files you have deleted but are still opened by some processes, space will be freed after those processes close these files. You can use lsof to check what files are opened by what process.
 
I restarted the router before sending this post because I thought it can be a hanged samba process.

Which filesystem uses the router when we format one USB hard disk withint the same router?
 
If we format one USB hard disk with the Router administration webpage which filesystem format it creates (FAT32, NTFS, ext4, ...).
 
If we format one USB hard disk with the Router administration webpage which filesystem format it creates (FAT32, NTFS, ext4, ...).
I'd like to see a screenshot of that page where one can format USB devices in the UI.
 
I don't have that option in my firmware. But someone else recently referred to it so perhaps it's a new addition?
Huh? I meant this as a joke. Now I really need to see a screenshot, the firmware used and the model this runs on.
 
I see now, this is the elusive RT-AC86U with stock firmware. Really wish I could get my coder hands on one of these.
 
I'm sorry, it seems Merlin doesn't has one option to format the USB drive. I don't know if the original Asus firmware had that option...
I will try making some free space to see if this limitation it's related to some limitation.
 
After lot of time I tried to fix this problem another time, and as ColinTaylor said, the problem was the reserved blocks.

I fixed it login to the ssh of the router and running this command:

tune2fs -m 0 /dev/sda1

That command sets 0% reserved space on that partition.

Thx.
 
After lot of time I tried to fix this problem another time, and as ColinTaylor said, the problem was the reserved blocks.

I fixed it login to the ssh of the router and running this command:

tune2fs -m 0 /dev/sda1

That command sets 0% reserved space on that partition.

Thx.

Thank you for the solution.
 

Similar threads

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top