标签:home 连接 which vmware name default 开发 apt-get --
前边 已经提到过吧vmare的IP改成了静态IP,对于上网来说,这个是个麻烦的事。现在重新配置Vmware的IP
VMware-Edit-Virtual network editor
选择PC机的无线网卡(可以上网),name:VMnet0
2、VMware-VM-Setting-Network adapter
选择custom-VMnet0
3、在ubuntu系统中编辑网络:
选择编辑连接,添加网络命名无线连接:
如图配置,然后就可以重现上网了。
配置虚拟机与ARM(am335x开发板)的NFS网络文件共享方法:
安装NFS服务器:sudo apt-get install nfs-kernel-server
配置NFS服务器:sudo gedit /etc/exports
# /etc/exports: the access control list for filesystems which may be exported # to NFS clients. See exports(5). # # Example for NFSv2 and NFSv3: # /srv/homes hostname1(rw,sync,no_subtree_check) hostname2(ro,sync,no_subtree_check) # # Example for NFSv4: # /srv/nfs4 gss/krb5i(rw,sync,fsid=0,crossmnt,no_subtree_check) # /srv/nfs4/homes gss/krb5i(rw,sync,no_subtree_check) # /home/zyr/Source_code/text/nfs 192.168.200.*(rw,sync,no_root_squash)
在最后加上自己共享目录的路径。
重启服务器:
配置ARM(am335x开发板)板的IP,可以在/etc/init.d/rcS中直接配置:
# --------------------------------------------- # Mount the default file systems # --------------------------------------------- echo -n " Mounting other filesystems : " mount -a status $? 0 #######配置网络################################ echo "config_network : " /sbin/ifconfig lo 127.0.0.1 netmask 255.0.0.0 /sbin/ifconfig eth0 192.168.200.70 /sbin/ifconfig eth0 netmask 255.255.255.0 /sbin/route add default gw 192.168.200.255 eth0 /sbin/ifconfig eth1 192.168.200.71 netmask 255.255.255.0 /sbin/route add default gw 192.168.200.255 eth1
重新配置VMare的网络为有线连接1,如图:
目的是主机IP静态:192.168.200.123
最后将主机(虚拟机)目录的/hmoe/zyr/Source_code/text/nfs 挂在开发板上还需要:
[root@zyr-am335x ]#mount -t nfs -o nolock 192.168.200.123:/home/zyr/Source_code/text/nfs /mnt [root@zyr-am335x ]#cd /mnt [root@zyr-am335x mnt]#ls led_test zyr-hello.ko [root@zyr-am335x mnt]#insmod zyr-hello.ko [ 5299.759382] misc-register led_core [root@zyr-am335x mnt]#./led_test Start led test. [ 5309.324907] GPIO LED set low. [ 5310.338522] GPIO LED set high. [ 5311.342169] GPIO LED set low. [ 5312.345413] GPIO LED set high.
NFS挂载结束,以后在内核中编写驱动时再也不用SD卡插拔插拔插拔了,所有的所有只要敲敲命令就OK了。
参考:博客
http://jingyan.eeboard.com/article/75498
标签:home 连接 which vmware name default 开发 apt-get --
原文地址:http://www.cnblogs.com/BigOBlue/p/7071353.html