Hardware Reference
In-Depth Information
Solution
If you are running Linux on a host computer attached to BeagleBone Black, it's not hard to
mount the Bone's files on the host or the host's files on the Bone by using sshfs . Suppose
that you want to access files on the host from the Bone. First, install sshfs :
bone# apt-get install sshfs
Now, mount the files to an empty directory (substitute your username on the host computer
for username and the IP address of the host for 192.168.7.1 ):
bone# mkdir host
bone# sshfs username@$192.168.7.1:. host
bone# cd host
bone# ls
The ls command will now list the files in your home directory on your host computer. You
can edit them as if they were local to the Bone. You can access all the files by substituting
:/ for the :. following the IP address.
You can go the other way, too. Suppose that you are on your Linux host computer and want
to access files on your Bone. Install sshfs :
host$ sudo apt-get install sshfs
and then access:
host$ mkdir /mnt/bone
host$ sshfs root@$192.168.7.2:/ /mnt/bone
host$ cd /mnt/bone
host$ ls
Here, we are accessing the files on the Bone as root . We've mounted the entire file sys-
tem, starting with / , so you can access any file. Of course, with great power comes great
responsibility, so be careful.
Search WWH ::




Custom Search