beautypg.com

Backing up the user file system, Backing up the user file system -5 – Moxa Technologies UC-7420/7410 User Manual

Page 45

background image

UC-7420/7410 User’s Manual

Managing Embedded Linux

3-5

Backing Up the User File System

1. Create a backup file. The specific commands used to back up the user file system depend on

whether the firmware version is earlier or later than version V1.5.

Firmware versions earlier than V1.5 (not including V1.5)

#upramdisk
#backupfs /mnt/ramdisk/usrdisk


Firmware version V1.5 (and later versions)

First type the following command to enable the RAM disk:

#upramdisk


Next, use the file system backup utility provided by Moxa:

#backupuf /mnt/ramdisk/usrfs-backup


Alternatively, you may type the following command to back up the file system to the CF card:

#backupuf /mnt/hda/usrfs-backup

2. Once the file system is backed up, use FTP to transfer the file usrfs-backup to your PC.

192.168.3.127 – PuTTY

root@Moxa:~# upramdisk
root@Moxa:~# cd /mnt/ramdisk
root@Moxa:/mnt/ramdisk# df –h
Filesystem Size Used Available Use% Mounted on
/dev/mtdblock3 26.0M 9.0M 17.0M 35% /
/dev/mtdblock3 26.0M 9.0M 17.0M 35% /
/dev/ram2 2.0M 42.0k 1.8M 2% /var
tmpfs 62.1M 0 62.1M 0% /dev/shm
/dev/ram1 29.0M 13.0k 27.5M 0% /mnt/ramdisk
root@Moxa:/mnt/ramdisk# backupuf /mnt/ramdisk/usrfs-backup
Sync the file system…
Now backup the user root file system. Please wait. . .
. . . . . . . . . . . . . . . . . . . . . . . . . . .
Backup user root file system OK.
root@Moxa:/mnt/ramdisk#

Deploying the User File System to Additional UC-7420/7410 Units

For some applications, you may need to ghost one UC-7420/7410 user file system to other
UC-7420/7410 units. The specific commands used to carry out this procedure depend on whether
the firmware version is earlier or later than version V1.5.

Firmware versions earlier than V1.5 (not including V1.5)

Type the following commands to force the system to jump to the Mini File System:

#mv /etc/inittab /etc/inittab.bak
#reboot –r now
#upramdisk

Use ftp to download the backup file of the user file system from the PC to the /mnt/ramdisk
directory:

#bf /mnt/ramdisk/usrdisk
#reboot –r now

Firmware version V1.5 (and later versions)