Score:0

Shebang = how to verify source/target file mounted via --bind

ca flag

On a router (busybox) I'm limited to shebang. On devices like these relaying on squashfs and flash storage it's common practice to mount --bind files from USB/CIFS/JFFS onto a file provided by the squashfs (and expanded in RAM).

e.g.

mount --bind /mnt/sda1/dnsmasq.conf /etc/dnsmasq.conf

I'm trying to automate some login in a script of mine but I can't find a way to display precisely what file was mounted --bind where?

the output of the mount command is incomplete in regard as it doesn't provide the full path of the source:

/dev/sda1 on /etc/sda1/dnsmasq.conf type fuseblk (rw,nodev,noatime,user_id=0,group_id=0,allow_other,blksize=1024)

As you can see the first column doesn't provide the full path of the source. df doesn't help either as the source is always /dev/sda1. So in a nutshell my question summarizes like this:

How do I go verifying what source file is "mount --bind" to what destination file?

Thanks!

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.