Tiny Core Linux
Tiny Core Base => TCB Talk => Topic started by: manit123 on October 23, 2015, 10:02:38 AM
-
I like tiny core because of its small memory footprint and customisable modules.
Is there any kernel option or something which enables me to load OS , utilities , application etc. completely in RAM so that I can safely remove usb stick from which it booted while leaving the OS running.
Please suggest .
Here is my grub entry currently
title tinycore 6.3
root (hd0,1)
kernel /boot/vmlinuz63 waitusb=10 loop.max_loop=256 tce=UUID="611772c2-af11-4e27 -93a0-245172ae2dea" lst=onboot63.lst mydata=tc-with-wifi
initrd /boot/core63.gz
My system has 2GB RAM .
Running stats .
tc@box:~$ free -m
total used free shared buffers
Mem: 2015 1891 123 0 338
-/+ buffers: 1553 462
Swap: 496 187 308
Thanks.
-
Touch /etc/sysconfig/tcedir/copy2fs.flg
reboot
Try to umount /etc/sysconfig/tcedir
If successful, you can remove the media.
-
tc@box:~$ touch /etc/sysconfig/tcedir/copy2fs.flg
tc@box:~$ df
Filesystem Size Used Available Use% Mounted on
rootfs 1.8G 340.8M 1.4G 19% /
tmpfs 1007.6M 0 1007.6M 0% /dev/shm
/dev/sdb2 4.8G 4.4G 176.4M 96% /mnt/sdb2
/dev/sda2 97.8G 43.3G 54.5G 44% /mnt/sda2
/dev/sdb1 10.0G 8.7G 1.3G 87% /mnt/sdb1
tc@box:~$ mount
rootfs on / type rootfs (rw,size=1857204k,nr_inodes=681933)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
devpts on /dev/pts type devpts (rw,relatime,mode=600,ptmxmode=000)
tmpfs on /dev/shm type tmpfs (rw,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,relatime)
/dev/sdb2 on /mnt/sdb2 type ext2 (rw,relatime)
/dev/sda2 on /mnt/sda2 type fuseblk (rw,relatime,user_id=0,group_id=0,allow_othe r,blksize=4096)
/dev/sdb1 on /mnt/sdb1 type vfat (rw,noexec,relatime,fmask=0000,dmask=0000,allow _utime=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
tc@box:~$ ls -al /etc/sysconfig/
total 40
drwxrwxr-x 2 root staff 280 Oct 26 18:07 ./
drwxr-xr-x 10 root root 720 Oct 26 18:12 ../
-rw-r--r-- 1 root root 6 Oct 26 18:07 Xserver
-rw-r--r-- 1 root root 2 Oct 26 18:07 backup
-rw-rw-r-- 1 root staff 9 Oct 26 18:07 backup_device
-rw-r--r-- 1 root root 13 Oct 26 18:07 desktop
-rw-r--r-- 1 root root 5 Oct 26 18:07 icons
-rw-r--r-- 1 root root 10 Oct 26 18:07 keymap
-rw-r--r-- 1 root root 7 Oct 26 18:07 language
-rw-r--r-- 1 root root 13 Oct 26 18:07 mydata
-rw-r--r-- 1 root root 0 Oct 26 18:07 newmodules
-rw-r--r-- 1 root root 13 May 30 15:24 ntpserver
lrwxrwxrwx 1 root root 8 Oct 26 18:07 tcedir -> /tmp/tce/
-rw-r--r-- 1 root root 3 Oct 26 18:07 tcuser
I did not understand the purpose of unmount tcedir . it is not a mount point .
-
root@box:/home/tc# umount /etc/sysconfig/tcedir
umount: can't umount /etc/sysconfig/tcedir: Invalid argument
tc@box:~$ umount /etc/sysconfig/tcedir
umount: can't umount /etc/sysconfig/tcedir: Operation not permitted
-
See where /etc/sysconfig/tcedir points.
Umount that directory.
-
I just double-checked - using the apps gui to toggle copy2fs as the default and rebooting allowed to me to un-mount and remove the usb stick I booted from.
("sudo umount /mnt/sdb1" in my case)
-
i am able to unmount usb stick as juanito had said without unmounting /tmp/tce .
Question 1)Still , I can't understand how can somebody unmount a directory which does not appear in 'mount' command output .
Can you explain ?
Question 2) BTW ,I boot using an ext2 partition of my USB . What steps can I do to have good USB life ?
-
1) I guess gerald_clark just didn't use the best wording. un-mounting the media which contains /etc/sysconfig/tcedir is probably what he meant.
2) Core doesn't write to the boot media except when downloading extensions or repacking the backup file, where the latter happens at every shutdown by default.
You can edit ~/.profile and change
export BACKUP=1
to
export BACKUP=0
and then, after a reboot, only run Backup if necessary.