What's new

Can't run "df" command inside chrooted debian

  • 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!

TeHashX

Very Senior Member
Hi, I setup Debian Stretch on RT-AC86U router https://www.hqt.ro/how-to-install-debian-stretch-arm/ and it's working great but now I want to run "df" command inside debian and I get error: "df: no file systems processed", I have coreutils installed, tried different versions.
In "old" Debian Jessie I created a symlink "ln -s /proc/mounts /etc/mtab" and worked but in Stretch has no effect
I searched on internet and didn't find nothing useful, I tried to symlink "df" to busybox but no go.
Some ideas?
 
Any hint?

Erm - not a clue...

Have you considered an RPi? They're cheap enough these days..

Much more useful (more RAM and Storage), and it runs a version of Debian with real tools - Busybox is cool, but...
 
Already have one Odroid C2 which is great but this router is very capable too and would be nice to figure out how to solve "df" issue, I'm trying to setup Pi-hole and can't get further with installer script.
 
Thanks, I get this
root@RT-AC86U:/# strace df ..
execve("/bin/df", ["df", ".."], [/* 16 vars */]) = 0
brk(NULL) = 0xab54a000
uname({sysname="Linux", nodename="RT-AC86U", ...}) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap2(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xf77c2000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=6840, ...}) = 0
mmap2(NULL, 6840, PROT_READ, MAP_PRIVATE, 3, 0) = 0xf77c0000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/arm-linux-gnueabihf/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\1\1\1\3\0\0\0\0\0\0\0\0\3\0(\0\1\0\0\0\331e\1\0004\0\0\0"..., 512) = 512
lseek(3, 900076, SEEK_SET) = 900076
read(3, "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"..., 2920) = 2920
lseek(3, 896524, SEEK_SET) = 896524
read(3, "A4\0\0\0aeabi\0\1*\0\0\0\0057-A\0\6\n\7A\10\1\t\2\n\3\f"..., 53) = 53
fstat64(3, {st_mode=S_IFREG|0755, st_size=902996, ...}) = 0
mmap2(NULL, 972128, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xf76b0000
mprotect(0xf7789000, 61440, PROT_NONE) = 0
mmap2(0xf7798000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xd8000) = 0xf7798000
mmap2(0xf779b000, 9568, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xf779b000
close(3) = 0
set_tls(0xf77c47e0, 0xf77c4eb8, 0xf77c6050, 0xf77c47e0, 0xf77c6050) = 0
mprotect(0xf7798000, 8192, PROT_READ) = 0
mprotect(0xaae97000, 4096, PROT_READ) = 0
mprotect(0xf77c5000, 4096, PROT_READ) = 0
munmap(0xf77c0000, 6840) = 0
brk(NULL) = 0xab54a000
brk(0xab56b000) = 0xab56b000
open("..", O_RDONLY|O_NOCTTY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
close(3) = 0
open("/proc/self/mountinfo", O_RDONLY|O_LARGEFILE) = 3
fstat64(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(3, "25 23 0:6 / /dev rw,relatime - d"..., 1024) = 216
read(3, "", 1024) = 0
_llseek(3, 0, [216], SEEK_CUR) = 0
close(3) = 0
getcwd("/", 4096) = 2
open(".", O_RDONLY|O_LARGEFILE) = 3
fcntl64(3, F_GETFD) = 0
fcntl64(3, F_SETFD, FD_CLOEXEC) = 0
chdir("..") = 0
stat64("..", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
getcwd("/", 4096) = 2
fchdir(3) = 0
close(3) = 0
uname({sysname="Linux", nodename="RT-AC86U", ...}) = 0
statfs64("/", 88, 0xff87de30) = 0
fstat64(1, {st_mode=S_IFCHR|0622, st_rdev=makedev(136, 0), ...}) = 0
write(1, "Filesystem 1K-blocks Us"..., 61Filesystem 1K-blocks Used Available Use% Mounted on
) = 61
write(1, "- 961271120 4397083"..., 52- 961271120 439708376 472709960 49% /
) = 52
close(1) = 0
close(2) = 0
exit_group(0) = ?
+++ exited with 0 +++
root@RT-AC86U:/# cat /proc/self/mountinfo
25 23 0:6 / /dev rw,relatime - devtmpfs devtmpfs rw,mode=0755
26 25 0:11 / /dev/pts rw,relatime - devpts devpts rw,mode=600
27 23 0:4 / /proc rw,relatime - proc proc rw
28 23 0:14 / /sys rw,relatime - sysfs sysfs rw
root@RT-AC86U:/#
 
Last edited:

Similar threads

Latest threads

Sign Up For SNBForums Daily Digest

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