Tiny Core Base > Release Candidate Testing
tinycore_v3.8rc3
quanpin:
It can mount tcz in ISO, but mydata.tgz in iso, it will not restore .
roberts:
Oh please. The backup file mydata.tgz is for doing backups. Which won't work very well when you try to write to a CD! If you must then make it into a tcz.
quanpin:
--- Quote from: roberts on August 02, 2011, 03:25:06 AM ---Oh please. The backup file mydata.tgz is for doing backups. Which won't work very well when you try to write to a CD! If you must then make it into a tcz.
--- End quote ---
but tce in a CD , if it can load mydata.tgz , it will be a liveCD system . of couse I don't need to backup mydata. I just use this in vm or test a system.
and mydata.tgz can use win-7zip to change data directly in Windows. but .tcz need to unmksqush and than mksqush.
roberts:
It may not be what you want, but it is the expected and defined behavior that upon shutdown personal files to saved (written) to mydata,tgz.
quanpin:
@ roberts
I have a suggestion
first: disable $MOUNTPOINTFS" == iso9660 check of tc-setup like tc3.6 and before
--- Code: ---MOUNTPOINTFS="$(grep ${MOUNTPOINT} /etc/fstab | awk '{print $3}')"
if [ "$MOUNTPOINTFS" == iso9660 ]; then
TCEDIR="$MOUNTPOINT"/"$TCE_DIR"
LOADFROM="$TCEDIR"/optional
[ -s "$TCEDIR"/"$TARGETLIST" ] && for FILE in `cat "$TCEDIR"/"$TARGETLIST"`; do FILE="$LOADFROM/$FILE" && process; done
#### TCEDIR=/tmp/tce
else
TCEDIR="$MOUNTPOINT"/"$TCE_DIR"
echo "$MOUNTPOINT" > /etc/sysconfig/tce.mount
sync
fi
echo "$TCEDIR" > /opt/.tce_dir
chown -R "$USER".staff "$TCEINSTALLED"
--- End code ---
than add tc-setup2iso like this
--- Code: ---#!/bin/sh
#(c) Robert Shingledecker 2009-2011
. /etc/init.d/tc-functions
#########
[ -z "$TCE" ] && TCE="$(autoscan 'tce' 'd')"/tce
if [ "$TCE" != "/tce" ]; then
TCE_DEVICE="${TCE%%/*}"
TCE_DIR="${TCE#*/}"
if [ "$TCE_DEVICE" = "$TCE_DIR" ]; then TCE_DIR="tce"; fi
find_mountpoint "$TCE_DEVICE"
if [ -n "$MOUNTPOINT" ]; then
if [ "$MOUNTED" == "yes" ]; then
if [ ! -d "$MOUNTPOINT"/"$TCE_DIR"/optional ]; then
mkdir -p "$MOUNTPOINT"/"$TCE_DIR"/optional
fi
else
mount "$MOUNTPOINT"
if [ $? == 0 ]; then
UMOUNT="yes"
if [ ! -d "$MOUNTPOINT"/"$TCE_DIR"/optional ]; then
mkdir -p "$MOUNTPOINT"/"$TCE_DIR"/optional
fi
fi
fi
fi
else
MOUNTPOINT="/tmp"; TCE_DIR="tce"
fi
MOUNTPOINTFS="$(grep ${MOUNTPOINT} /etc/fstab | awk '{print $3}')"
if [ "$MOUNTPOINTFS" == iso9660 ]; then
# TCEDIR="$MOUNTPOINT"/"$TCE_DIR"
# LOADFROM="$TCEDIR"/optional
# [ -s "$TCEDIR"/"$TARGETLIST" ] && for FILE in `cat "$TCEDIR"/"$TARGETLIST"`; do FILE="$LOADFROM/$FILE" && process; done
TCEDIR=/tmp/tce
#else
# TCEDIR="$MOUNTPOINT"/"$TCE_DIR"
# echo "$MOUNTPOINT" > /etc/sysconfig/tce.mount
# sync
#fi
echo "$TCEDIR" > /opt/.tce_dir
fi
--- End code ---
at last : add tc-setup2iso in /opt/bootlocal.sh
I tryed it can mount tce in CD and load mydata.tgz like a LIVECD.
and /opt/.tce_dir set to /tmp/tce like the tinycore_3.8rc3.iso
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version