明远智睿技术论坛

 找回密码
 立即注册
搜索
查看: 9574|回复: 1
打印 上一主题 下一主题

nfs挂载新的文件系统

[复制链接]

89

主题

226

帖子

1099

积分

超级版主

Rank: 8Rank: 8

积分
1099
跳转到指定楼层
楼主
发表于 2020-5-19 16:04:38 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
主机平台: UBUNTU16.04
硬件平台:明远智睿MY-IMX6-EK200-6Q-1G
内核版本 :Linux-3.0.35
文件系统:rootfs-linux-minimal.tar.bz2

首先,需要在设置虚拟机的网络,桥接以太网,使虚拟机与开发板在同一网关下且虚拟机与开发板能够相互ping通



设置ubuntu的ip为:192.168.18.88
查看虚拟机与开发板是否能相互ping通
虚拟机上执行
$ ping 192.168.18.99
开发板上执行:
#ifconfig eth0 192.168.18.99
#ping 192.168.18.88

能够相互ping通后,虚拟机上执行

$sudo vim /etc/exports
在最下面添加==>/home/jj/share *(rw,sync,no_root_squash)
虚拟机重启nfs服务
$ sudo /etc/init.d/nfs-kernel-server restart


重新开启开发板,进入uboot命令行
设置
>setenv ipaddr=192.168.18.99
>setenv serverip=192.168.18.88
>setenv nfsroot=/home/jj/share
>setenv netmask=255.255.255.0
>setenv netdev=eth0
>setenv ethaddr=00:01:02:03:04:05

再次
>ping 192.168.18.88
确定ping通

FEC: Link is Up ffff
Using FEC0 device
host 192.168.18.88 is alive

然后执行

>setenv bootcmd_mmc 'run bootargs_base bootargs_nfs; mmc dev 2; mmc read ${loadaddr} 0x800 0x2000; bootm'

>boot

接下来进入到文件系统开机中打印的字符:
mmc2(part 0) is current device

MMC read: dev # 2, block # 2048, count 8192 ... 8192 blocks read: OK
## Booting kernel from Legacy Image at 10800000 ...
   Image Name:   Linux-3.0.35
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4007704 Bytes =  3.8 MB
   Load Address: 10008000
   Entry Point:  10008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

Linux version 3.0.35 (myzr@u12045) (gcc version 4.6.2 20110630 (prerelease) (Freescale MAD -- Linaro 2011.07 -- Built at 2011/08/10 09:20) ) #1 SMP PREEMPT Mon Dec 7 09:28:30 CST 2015
CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c53c7d
CPU: VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: MYZR i.MX6 Evaluation Kit ( DIMM 200 )
Ignoring unrecognised tag 0x54410008
Memory policy: ECC disabled, Data cache writealloc
CPU identified as i.MX6Q, silicon rev 1.2
PERCPU: Embedded 7 pages/cpu @8c80e000 s5440 r8192 d15040 u32768
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 454656
Kernel command line: console=ttymxc0,115200 video=mxcfb0:dev=ldb,LDB-1024X600,if=RGB666 root=/dev/nfs ip=192.168.18.99 nfsroot=192.168.18.88:/home/jj/share,v3,tcp
PID hash table entries: 4096 (order: 2, 16384 bytes)
Dentry cache hash table entries: 262144 (order: 8, 1048576 bytes)
Inode-cache hash table entries: 131072 (order: 7, 524288 bytes)
Memory: 512MB 1280MB = 1792MB total
Memory: 1805148k/1805148k available, 292004k reserved, 360448K highmem
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
    DMA     : 0xf4600000 - 0xffe00000   ( 184 MB)
    vmalloc : 0xea800000 - 0xf2000000   ( 120 MB)
    lowmem  : 0x80000000 - 0xea000000   (1696 MB)
    pkmap   : 0x7fe00000 - 0x80000000   (   2 MB)
    modules : 0x7f000000 - 0x7fe00000   (  14 MB)
      .init : 0x80008000 - 0x8003f000   ( 220 kB)
      .text : 0x8003f000 - 0x80add204   (10873 kB)
      .data : 0x80ade000 - 0x80b46bc0   ( 419 kB)
       .bss : 0x80b46be4 - 0x80b753cc   ( 186 kB)
SLUB: Genslabs=13, HWalign=32, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
Preemptible hierarchical RCU implementation.
NR_IRQS:624
MXC GPIO hardware
sched_clock: 32 bits at 3000kHz, resolution 333ns, wraps every 1431655ms
arm_max_freq=1GHz
MXC_Early serial console at MMIO 0x2020000 (options '115200')
bootconsole [ttymxc0] enabled
Console: colour dummy device 80x30
Calibrating delay loop... 1581.05 BogoMIPS (lpj=7905280)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
hw perfevents: enabled with ARMv7 Cortex-A9 PMU driver, 7 counters available
CPU1: Booted secondary processor
CPU2: Booted secondary processor
CPU3: Booted secondary processor
Brought up 4 CPUs
SMP: Total of 4 processors activated (6324.22 BogoMIPS).
print_constraints: dummy:
NET: Registered protocol family 16
print_constraints: vddpu: 725 <--> 1300 mV at 700 mV fast normal
print_constraints: vddcore: 725 <--> 1300 mV at 1150 mV fast normal
print_constraints: vddsoc: 725 <--> 1300 mV at 1200 mV fast normal
print_constraints: vdd2p5: 2000 <--> 2775 mV at 2400 mV fast normal
print_constraints: vdd1p1: 800 <--> 1400 mV at 1100 mV fast normal
print_constraints: vdd3p0: 2625 <--> 3400 mV at 3000 mV fast normal
vmap allocation for size 134221824 failed: use vmalloc=<size> to increase size.
hw-breakpoint: found 6 breakpoint and 1 watchpoint registers.
hw-breakpoint: 1 breakpoint(s) reserved for watchpoint single-step.
hw-breakpoint: maximum watchpoint size is 4 bytes.
L310 cache controller enabled
l2x0: 16 ways, CACHE_ID 0x410000c7, AUX_CTRL 0x32070000, Cache size: 1048576 B
bio: create slab <bio-0> at 0
mxs-dma mxs-dma-apbh: initialized
print_constraints: SPKVDD: 4200 mV
print_constraints: 1_8V: 1800 mV
print_constraints: MICVDD: 3300 mV
print_constraints: vmmc: 3300 mV
vgaarb: loaded
SCSI subsystem initialized
spi_imx imx6q-ecspi.0: probed
spi_imx imx6q-ecspi.1: probed
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
Freescale USB OTG Driver loaded, $Revision: 1.55 $
imx-ipuv3 imx-ipuv3.0: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
imx-ipuv3 imx-ipuv3.1: IPU DMFC NORMAL mode: 1(0~1), 5B(4,5), 5F(6,7)
mxc_mipi_csi2 mxc_mipi_csi2: i.MX MIPI CSI2 driver probed
mxc_mipi_csi2 mxc_mipi_csi2: i.MX MIPI CSI2 dphy version is 0x3130302a
MIPI CSI2 driver module loaded
Advanced Linux Sound Architecture Driver Version 1.0.24.
Bluetooth: Core ver 2.16
NET: Registered protocol family 31
Bluetooth: HCI device and connection manager initialized
Bluetooth: HCI socket layer initialized
Bluetooth: L2CAP socket layer initialized
Bluetooth: SCO socket layer initialized
cfg80211: Calling CRDA to update world regulatory domain
max17135 2-0048: PMIC MAX17135 for eInk display
i2c-core: driver [max17135] using legacy suspend method
i2c-core: driver [max17135] using legacy resume method
Switching to clocksource mxc_timer1
NET: Registered protocol family 2
IP route cache hash table entries: 65536 (order: 6, 262144 bytes)
TCP established hash table entries: 262144 (order: 9, 2097152 bytes)
TCP bind hash table entries: 65536 (order: 7, 786432 bytes)
TCP: Hash tables configured (established 262144 bind 65536)
TCP reno registered
UDP hash table entries: 1024 (order: 3, 32768 bytes)
UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes)
NET: Registered protocol family 1
RPC: Registered named UNIX socket transport module.
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
PMU: registered new PMU device of type 0
Static Power Management for Freescale i.MX6
wait mode is enabled for i.MX6
cpaddr = 0 suspend_iram_base=f2900000
PM driver module loaded
iMX6 PCIe PCIe RC mode imx_pcie_pltfm_probe entering.
PCIE: imx_pcie_pltfm_probe start link up.
link up failed, DB_R0:0x00b73f00, DB_R1:0x08200000!
IMX PCIe port: link down!
IMX usb wakeup probe
add wake up source irq 75
IMX usb wakeup probe
cpu regulator mode:ldo_enable
i.MXC CPU frequency driver
highmem bounce pool size: 64 pages
JFFS2 version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
msgmni has been set to 2821
alg: No test for stdrng (krng)
io scheduler noop registered
io scheduler deadline registered
io scheduler cfq registered (default)
mxc_mipi_dsi mxc_mipi_dsi: i.MX MIPI DSI driver probed
MIPI DSI driver module loaded
mxc_sdc_fb mxc_sdc_fb.0: register mxc display driver ldb
_regulator_get: get() with no identifier
imx-ipuv3 imx-ipuv3.1: IPU DMFC DP HIGH RESOLUTION: 1(0,1), 5B(2~5), 5F(6,7)
Console: switching to colour frame buffer device 128x37
mxc_sdc_fb mxc_sdc_fb.1: register mxc display driver ldb
mxc_sdc_fb mxc_sdc_fb.2: register mxc display driver lcd
mxc_sdc_fb mxc_sdc_fb.3: register mxc display driver ldb
mxc_sdc_fb mxc_sdc_fb.3: ipu1-di0 already in use
mxc_sdc_fb: probe of mxc_sdc_fb.3 failed with error -16
imx-sdma imx-sdma: loaded firmware 1.1
imx-sdma imx-sdma: initialized
Serial: IMX driver
imx-uart.0: ttymxc0 at MMIO 0x2020000 (irq = 58) is a IMX
console [ttymxc0] enabled, bootconsole disabled
console [ttymxc0] enabled, bootconsole disabled
imx-uart.1: ttymxc1 at MMIO 0x21e8000 (irq = 59) is a IMX
imx-uart.2: ttymxc2 at MMIO 0x21ec000 (irq = 60) is a IMX
imx-uart.3: ttymxc3 at MMIO 0x21f0000 (irq = 61) is a IMX
imx-uart.4: ttymxc4 at MMIO 0x21f4000 (irq = 62) is a IMX
loop: module loaded
Wait for CR ACK error!
sata phy rx_pll is stable!
No sata disk.
m25p80 spi0.0: sst25vf016b (2048 Kbytes)
Creating 2 MTD partitions on "m25p80":
0x000000000000-0x000000100000 : "bootloader"
0x000000100000-0x000000200000 : "kernel"
GPMI NAND driver registered. (IMX)
vcan: Virtual CAN interface driver
CAN device driver interface
flexcan netdevice driver
flexcan imx6q-flexcan.0: device registered (reg_base=ea9e8000, irq=142)
flexcan imx6q-flexcan.1: device registered (reg_base=ea9f0000, irq=143)
FEC Ethernet Driver
fec_enet_mii_bus: probed
PPP generic driver version 2.4.2
PPP MPPE Compression module registered
usbcore: registered new interface driver smsc95xx
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
fsl-ehci fsl-ehci.0: Freescale On-Chip EHCI Host Controller
fsl-ehci fsl-ehci.0: new USB bus registered, assigned bus number 1
fsl-ehci fsl-ehci.0: irq 75, io base 0x02184000
fsl-ehci fsl-ehci.0: USB 2.0 started, EHCI 1.00
hub 1-0:1.0: USB hub found
hub 1-0:1.0: 1 port detected
add wake up source irq 72
fsl-ehci fsl-ehci.1: Freescale On-Chip EHCI Host Controller
fsl-ehci fsl-ehci.1: new USB bus registered, assigned bus number 2
fsl-ehci fsl-ehci.1: irq 72, io base 0x02184200
fsl-ehci fsl-ehci.1: USB 2.0 started, EHCI 1.00
hub 2-0:1.0: USB hub found
hub 2-0:1.0: 1 port detected
Initializing USB Mass Storage driver...
usbcore: registered new interface driver usb-storage
USB Mass Storage support registered.
usbcore: registered new interface driver usbserial
usbserial: USB Serial Driver core
USB Serial support registered for GSM modem (1-port)
usbcore: registered new interface driver option
option: v0.7.2:USB Driver for GSM modems
ARC USBOTG Device Controller driver (1 August 2005)
mousedev: PS/2 mouse device common for all mice
input: gpio-keys as /devices/platform/gpio-keys/input/input0
usb 2-1: new high speed USB device number 2 using fsl-ehci
elan - Read Hello Packet Failed
elan-touch: probe of 2-0010 failed with error -22
====ft5x0x_ts_probe
msg ft5x0x_read_reg i2c read error: -5
ft5x0x_ts: probe of 2-0038 failed with error -5
i2c-core: driver [isl29023] using legacy suspend method
i2c-core: driver [isl29023] using legacy resume method
rtc-isl1208 0-006f: chip found, driver version 0.3
rtc-isl1208 0-006f: rtc core: registered rtc-isl1208 as rtc0
rtc-isl1208 0-006f: rtc power failure detected, please set clock.
snvs_rtc snvs_rtc.0: rtc core: registered snvs_rtc as rtc1
i2c /dev entries driver
Linux video capture interface: v2.00
mxc_v4l2_output mxc_v4l2_output.0: V4L2 device registered as video16
mxc_v4l2_output mxc_v4l2_output.0: V4L2 device registered as video17
mxc_v4l2_output mxc_v4l2_output.0: V4L2 device registered as video18
mxc_v4l2_output mxc_v4l2_output.0: V4L2 device registered as video19
mxc_v4l2_output mxc_v4l2_output.0: V4L2 device registered as video20
mag3110 2-000e: check mag3110 chip ID
mag3110 2-000e: read chip ID 0xfffffffb is not equal to 0xc4!
mag3110: probe of 2-000e failed with error -22
hub 2-1:1.0: USB hub found
hub 2-1:1.0: 5 ports detected
i2c-core: driver [mag3110] using legacy suspend method
i2c-core: driver [mag3110] using legacy resume method
mma8451 0-001c: read chip ID 0x1 is not equal to 0x1a or 0x2a!
mma8451: probe of 0-001c failed with error -22
imx2-wdt imx2-wdt.0: IMX2+ Watchdog Timer enabled. timeout=60s (nowayout=1)
Bluetooth: Virtual HCI driver ver 1.3
Bluetooth: HCI UART driver ver 2.2
Bluetooth: HCIATH3K protocol initialized
Bluetooth: Generic Bluetooth USB driver ver 0.6
usbcore: registered new interface driver btusb
sdhci: Secure Digital Host Controller Interface driver
sdhci: Copyright(c) Pierre Ossman
mmc0: SDHCI controller on platform [sdhci-esdhc-imx.3] using DMA
mmc1: SDHCI controller on platform [sdhci-esdhc-imx.1] using DMA
mmc2: SDHCI controller on platform [sdhci-esdhc-imx.2] using DMA
mxc_vdoa mxc_vdoa: i.MX Video Data Order Adapter(VDOA) driver probed
VPU initialized
mxc_asrc registered
Galcore version 4.6.9.6622
Thermal calibration data is 0x5614cc69
Thermal sensor with ratio = 177
Anatop Thermal registered as thermal_zone0
anatop_thermal_probe: default cooling device is cpufreq!
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
usbcore: registered new interface driver snd-usb-audio
mxc_hdmi_soc mxc_hdmi_soc.0: MXC HDMI Audio
Cirrus Logic CS42888 ALSA SoC Codec Driver
i2c-core: driver [cs42888] using legacy suspend method
mmc0: new high speed DDR MMC card at address 0001
mmcblk0: mmc0:0001 SEM16G 14.6 GiB
mmcblk0boot0: mmc0:0001 SEM16G partition 1 4.00 MiB
mmcblk0boot1: mmc0:0001 SEM16G partition 2 4.00 MiB
mmcblk0: p1
i2c-core: driver [cs42888] using legacy resume method
mmcblk0boot1: unknown partition table
imx-hdmi-soc-dai imx-hdmi-soc-dai.0: Failed: Load HDMI-video first.
mmcblk0boot0: unknown partition table
wm8962 0-001a: customer id 0 revision D
input: WM8962 Beep Generator as /devices/platform/imx-i2c.0/i2c-0/0-001a/input/input1
usb 2-1.1: new high speed USB device number 3 using fsl-ehci
asoc: wm8962 <-> imx-ssi.1 mapping ok
input: wm8962-audio DMIC as /devices/platform/soc-audio.5/sound/card0/input2
input: wm8962-audio Ext Spk as /devices/platform/soc-audio.5/sound/card0/input3
imx_3stack asoc driver
Initialize HDMI-audio failed. Load HDMI-video first!
ALSA device list:
  #0: wm8962-audio
NET: Registered protocol family 26
TCP cubic registered
NET: Registered protocol family 17
can: controller area network core (rev 20090105 abi 8)
NET: Registered protocol family 29
can: raw protocol (rev 20090105)
can: broadcast manager protocol (rev 20090105 t)
Bluetooth: RFCOMM TTY layer initialized
Bluetooth: RFCOMM socket layer initialized
Bluetooth: RFCOMM ver 1.11
Bluetooth: BNEP (Ethernet Emulation) ver 1.3
Bluetooth: BNEP filters: protocol multicast
Bluetooth: HIDP (Human Interface Emulation) ver 1.2
lib80211: common routines for IEEE802.11 drivers
VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
DDR type is DDR3
Bus freq driver module loaded
Bus freq driver Enabled
mxc_dvfs_core_probe
DVFS driver module loaded
rtc-isl1208 0-006f: hctosys: invalid date/time
eth0: Freescale FEC PHY driver [Generic PHY] (mii_bus:phy_addr=1:00, irq=-1)
smsc95xx v1.0.4
PHY: 1:00 - Link is Up - 100/Full
smsc95xx 2-1.1:1.0: eth1: register 'smsc95xx' at usb-fsl-ehci.1-1.1, smsc95xx USB 2.0 Ethernet, 8a:a1:fb:80:b8:5c
IP-Config: Guessing netmask 255.255.255.0
IP-Config: Complete:
     device=eth0, addr=192.168.18.99, mask=255.255.255.0, gw=255.255.255.255,
     host=192.168.18.99, domain=, nis-domain=(none),
     bootserver=255.255.255.255, rootserver=192.168.18.88, rootpath=
VFS: Mounted root (nfs filesystem) on device 0:13.
Freeing init memory: 220K
starting pid 1453, tty '': '/etc/rc.d/rcS'
Mounting /proc and /sys
Starting the hotplug events dispatcher udevd
udevd (1462): /proc/1462/oom_adj is deprecated, please use /proc/1462/oom_score_adj instead.
Synthesizing initial hotplug events
Setting the hostname to freescale
Mounting filesystems
Booted NFS, not relocating: /tmp /var
starting pid 2629, tty '': '/etc/rc.d/rc_gpu.S'
starting pid 2635, tty '': '/etc/rc.d/rc_mxc.S'

arm-none-linux-gnueabi-gcc (Freescale MAD -- Linaro 2011.07 -- Built at 2011/08/10 09:20) 4.6.2 20110630 (prerelease)
root filesystem built on Fri, 31 Aug 2012 11:01:55 -0500
Freescale Semiconductor, Inc.

freescale login: root
login[2637]: root login on 'ttymxc0'
root@freescale ~$

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?立即注册

x
回复

使用道具 举报

0

主题

11

帖子

45

积分

新手上路

Rank: 1

积分
45
沙发
发表于 2020-7-13 11:39:40 | 只看该作者
小手一抖,经验到手,手提酱油,低头猛走。
https://www.youxuan68.com
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

Archiver|手机版|小黑屋|明远智睿  

GMT+8, 2024-11-23 07:48 , Processed in 0.062693 second(s), 23 queries .

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表